/** * Returns the current "cache time" in milliseconds since the epoch. * The "cache time" takes into account skew among the local clocks * on the various machines involved in the cache. */ public long cacheTimeMillis() { return this.system.getClock().cacheTimeMillis(); }
@Override public long cacheTimeMillis() { return this.system.getClock().cacheTimeMillis(); } public InternalDistributedMember getDistributionManagerId() {
/** * All entry and region operations should be using this time rather than * System.currentTimeMillis(). Specially all version stamps/tags must be * populated with this timestamp. * * @return distributed cache time. */ public long cacheTimeMillis() { if (this.system != null) { return this.system.getClock().cacheTimeMillis(); } else { return System.currentTimeMillis(); } }
public final long cacheTimeMillis() { return this.cache.getDistributedSystem().getClock().cacheTimeMillis(); }
private static long calculateNow() { GemFireCacheImpl cache = GemFireCacheImpl.getInstance(); if (cache != null) { // Use cache.cacheTimeMillis here. See bug 52267. InternalDistributedSystem ids = cache.getDistributedSystem(); if (ids != null) { return ids.getClock().cacheTimeMillis(); } } return 0L; }
/** * Sets cache time offset in {@link DistributionManager}. * * @param coord * @param timeOffset * @see InternalDistributedSystem#getClock() * @see DSClock#setCacheTimeOffset(DistributedMember, long, boolean) */ public void setCacheTimeOffset(InternalDistributedMember coord, long timeOffset, boolean isJoin) { if (this.listener != null) { DistributionManager dm = this.listener.getDM(); dm.getSystem().getClock().setCacheTimeOffset(coord, timeOffset, isJoin); } }