code: protected void replicateState() {
  		final DialogState dialogState = getState();
  		final ReplicationStrategy replicationStrategy = ((ClusteredSipStack)getStack()).getReplicationStrategy();
  		boolean replicationStateVsDialogStateOK= false;		
  		if (logger.isLoggingEnabled(StackLogger.TRACE_DEBUG)) {
  			logger.logDebug("dialogState = " + dialogState + ", replicationStrategy = " + replicationStrategy);
  		}
  		if(dialogState == DialogState.CONFIRMED && (replicationStrategy == ReplicationStrategy.ConfirmedDialog|| replicationStrategy == ReplicationStrategy.ConfirmedDialogNoApplicationData)) {
  			replicationStateVsDialogStateOK = true;
  		}
  		if((dialogState == DialogState.EARLY || dialogState == DialogState.CONFIRMED || 
  			// Added as part of https://github.com/Mobicents/jain-sip.ha/pull/1
  			dialogState == DialogState.TERMINATED) 
  			&& replicationStrategy == ReplicationStrategy.EarlyDialog) {
  			replicationStateVsDialogStateOK = true;
  		}
  		if (replicationStateVsDialogStateOK && isCreated && super.dialogId != null && isRemoteTagSet() && isLocalTagSet() && getStack().getDialog(getDialogIdToReplicate()) != null) {
  			try {
  				((ClusteredSipStack)getStack()).getSipCache().putDialog(this);
  			} catch (SipCacheException e) {
  				logger.logError("problem storing dialog " + getDialogId() + " into the distributed cache", e);
  			}
  		}
  	}
docs: /*