mirror of
https://github.com/tiennm99/zfoo.git
synced 2026-10-16 02:15:51 +00:00
perf[protocol]:update config
This commit is contained in:
1 parent
cf1d38940a
commit
f1ae593739
18 files changed
+475
-220
No files matched your search
@@ -36,7 +36,6 @@
|
||||
<netty.version>4.1.84.Final</netty.version>
|
||||
<jprotobuf.version>2.4.17</jprotobuf.version>
|
||||
<kryo.version>5.3.0</kryo.version>
|
||||
<reflections.version>0.10.2</reflections.version>
|
||||
|
||||
<!-- zookeeper -->
|
||||
<curator.version>5.3.0</curator.version>
|
||||
|
||||
@@ -166,24 +166,18 @@ public abstract class SchedulerBus {
|
||||
/**
|
||||
* 不断执行的周期循环任务
|
||||
*/
|
||||
public static void scheduleAtFixedRate(Runnable runnable, long period, TimeUnit unit) {
|
||||
if (SchedulerContext.isStop()) {
|
||||
return;
|
||||
}
|
||||
public static ScheduledFuture<?> scheduleAtFixedRate(Runnable runnable, long period, TimeUnit unit) {
|
||||
|
||||
executor.scheduleAtFixedRate(SafeRunnable.valueOf(runnable), 0, period, unit);
|
||||
return executor.scheduleAtFixedRate(SafeRunnable.valueOf(runnable), 0, period, unit);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 固定延迟执行的任务
|
||||
*/
|
||||
public static void schedule(Runnable runnable, long delay, TimeUnit unit) {
|
||||
if (SchedulerContext.isStop()) {
|
||||
return;
|
||||
}
|
||||
public static ScheduledFuture<?> schedule(Runnable runnable, long delay, TimeUnit unit) {
|
||||
|
||||
executor.schedule(SafeRunnable.valueOf(runnable), delay, unit);
|
||||
return executor.schedule(SafeRunnable.valueOf(runnable), delay, unit);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in new issue
Block a user