private Optional<Duration> getTimeSinceLastRun(
            final Instant now,
            @Nullable final DataRetentionTracker dataRetentionTracker) {

        final Optional<Duration> optTimeSinceLastRun = Optional.ofNullable(dataRetentionTracker)
                .map(tracker -> Duration.between(dataRetentionTracker.getLastRunTime(), now));

        LOGGER.debug(() -> LogUtil.message("Treating timeSinceLastRun as: {}, ruleAge: {}",
                optTimeSinceLastRun,
                (dataRetentionTracker != null
                        ? dataRetentionTracker.getRuleAge()
                        : "NO TRACKER")));

        return optTimeSinceLastRun;
    }
Pkg private so we can test with a known now time
stroom-data/stroom-data-retention-impl/src/main/java/stroom/data/retention/impl/DataRetentionPolicyExecutor.java