private void submitNext() {
      long currentTime = clock.currentTimeMillis();
      Instant currentInstant = new Date(currentTime).toInstant();
      ZoneId localTimeZone = ZoneId.systemDefault();
      LocalDateTime now = currentInstant.atZone(localTimeZone).toLocalDateTime();
      LocalDateTime next = generator.next(now);
      long nextSchedule = 1000 * next.toEpochSecond(localTimeZone.getRules().getOffset(next));
      long delay = nextSchedule - currentTime;

      if (logger.isDebugEnabled()) {
        logger.debug("Now={}, next audit time={}, delay={} ms", new Date(currentTime), nextSchedule,
            delay);
      }

      trigger.schedule(() -> {
        try {
          auditor.execute();
        } catch (CacheClosedException e) {
          logger.warn("Cache closed while attempting to rebalance the cluster. Abort future jobs",
              e);
          return;
        } catch (Exception e) {
          logger.warn("Error while executing out-of-balance audit.", e);
        }
        submitNext();
      }, delay, TimeUnit.MILLISECONDS);
    }
Invokes audit triggers based on a cron schedule.
<OL>
<LI>computes delay = next slot - current time
<LI>schedules a out-of-balance audit task to be started after delay computed earlier
<LI>once the audit task completes, it repeats delay computation and task submission
geode-rebalancer/src/main/java/org/apache/geode/cache/util/AutoBalancer.java