@Override public void commit() { if (!isValidInternal()) throw new IllegalStateException("commit: Session " + getId() + " already invalidated"); // (STRING_MANAGER.getString("deltaSession.commit.ise", getId())); synchronized (this.changeLock) { // Jens - there used to be a check to only perform this if the queue is // empty, but we want this to always run so that the lastAccessedTime // will be updated even when no attributes have been changed. DeltaSessionManager mgr = (DeltaSessionManager) this.manager; if (this.enableGatewayDeltaReplication && mgr.isPeerToPeer()) { setCurrentGatewayDeltaEvent( new DeltaSessionAttributeEventBatch(this.sessionRegionName, this.id, this.eventQueue)); } this.hasDelta = true; this.applyRemotely = true; putInRegion(getOperatingRegion(), true, null); this.eventQueue.clear(); } }
public void commit() { if (!isValidInternal()) throw new IllegalStateException("commit: Session " + getId() + " already invalidated"); // (STRING_MANAGER.getString("deltaSession.commit.ise", getId())); synchronized (this.changeLock) { // Jens - there used to be a check to only perform this if the queue is // empty, but we want this to always run so that the lastAccessedTime // will be updated even when no attributes have been changed. DeltaSessionManager mgr = (DeltaSessionManager) this.manager; if (this.enableGatewayDeltaReplication && mgr.isPeerToPeer()) { setCurrentGatewayDeltaEvent( new DeltaSessionAttributeEventBatch(this.sessionRegionName, this.id, this.eventQueue)); } this.hasDelta = true; this.applyRemotely = true; putInRegion(getOperatingRegion(), true, null); this.eventQueue.clear(); } }