if ( refreshNPersist ) // refreshAndPersist mode
{
contextCsn = sendContentFromLog( session, req, replicaLog );
cookie = Strings.getBytesUtf8(replicaLog.getId() + REPLICA_ID_DELIM + contextCsn);
IntermediateResponse intermResp = new IntermediateResponseImpl( req.getMessageId() );
intermResp.setResponseName( SyncInfoValue.OID );
SyncInfoValueDecorator syncInfo = new SyncInfoValueDecorator(
ldapServer.getDirectoryService().getLdapCodecService(), SynchronizationInfoEnum.NEW_COOKIE );
syncInfo.setCookie( cookie );
intermResp.setResponseValue( syncInfo.getValue() );
session.getIoSession().write( intermResp );
// switch the handler mode to realtime push
handler.setPushInRealTime( refreshNPersist );