MCPcopy Create free account
hub / github.com/e2wugui/zeze / scheduleCron

Method scheduleCron

ZezeJava/ZezeJava/src/main/java/Zeze/Component/Timer.java:1027–1036  ·  view source on GitHub ↗
(long timerSerialId, int serverId, @NotNull String timerId, @NotNull BCronTimer cron,
							  long concurrentSerialNo, boolean putIfAbsent, @Nullable String oneByOneKey)

Source from the content-addressed store, hash-verified

1025 }
1026
1027 private void scheduleCron(long timerSerialId, int serverId, @NotNull String timerId, @NotNull BCronTimer cron,
1028 long concurrentSerialNo, boolean putIfAbsent, @Nullable String oneByOneKey) {
1029 try {
1030 long delay = cron.getNextExpectedTime() - System.currentTimeMillis();
1031 scheduleCronNext(timerSerialId, serverId, timerId, delay, concurrentSerialNo, putIfAbsent, oneByOneKey);
1032 } catch (Exception ex) {
1033 // 这个错误是在不好处理。先只记录日志吧。
1034 logger.error("", ex);
1035 }
1036 }
1037
1038 private void scheduleCronNext(long timerSerialId, int serverId, @NotNull String timerId, long delay,
1039 long concurrentSerialNo, boolean putIfAbsent, @Nullable String oneByOneKey) {

Callers 2

scheduleMethod · 0.95
loadTimerMethod · 0.95

Calls 2

scheduleCronNextMethod · 0.95
getNextExpectedTimeMethod · 0.65

Tested by

no test coverage detected