Skip to content

Commit

Permalink
4.x: Replace deprecated method Scheduling.fixedRateBuilder() on Sched…
Browse files Browse the repository at this point in the history
…uling.fixedRate() (helidon-io#9098)
  • Loading branch information
Captain1653 authored and tjquinno committed Aug 29, 2024
1 parent b2f0fae commit 3c7ab2f
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2021, 2023 Oracle and/or its affiliates.
* Copyright (c) 2021, 2024 Oracle and/or its affiliates.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -97,15 +97,15 @@ public class CoordinatorService implements HttpService {

private void init() {
lraPersistentRegistry.load(this);
recoveryTask = Scheduling.fixedRateBuilder()
recoveryTask = Scheduling.fixedRate()
.delay(config.get("recovery-interval").asLong().orElse(200L))
.initialDelay(200)
.timeUnit(TimeUnit.MILLISECONDS)
.task(this::tick)
.build();

if (config.get("periodical-persist").asBoolean().orElse(false)) {
persistTask = Scheduling.fixedRateBuilder()
persistTask = Scheduling.fixedRate()
.delay(config.get("persist-interval").asLong().orElse(5000L))
.initialDelay(200)
.timeUnit(TimeUnit.MILLISECONDS)
Expand Down

0 comments on commit 3c7ab2f

Please sign in to comment.