private static void RoundTripMessages(IMutableDirectBuffer buffer, FragmentHandler fragmentHandler, Publication publication, Subscription subscription, int count) { for (var i = 0; i < count; i++) { do { buffer.PutLong(0, Stopwatch.GetTimestamp()); } while (publication.Offer(buffer, 0, MessageLength) < 0L); PollingIdleStrategy.Reset(); while (subscription.Poll(fragmentHandler, FragmentCountLimit) <= 0) { PollingIdleStrategy.Idle(); } } }
/// <summary> /// set client id field /// </summary> /// <param name="clientId"> field value </param> /// <returns> for fluent API </returns> public CorrelatedMessageFlyweight ClientId(long clientId) { buffer.PutLong(offset + CLIENT_ID_FIELD_OFFSET, clientId); return(this); }
public NewLeadershipTermEventEncoder LeadershipTermId(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
/// <summary> /// Set the correlation id field /// </summary> /// <param name="correlationId"> field value </param> /// <returns> flyweight </returns> public PublicationBuffersReadyFlyweight CorrelationId(long correlationId) { _buffer.PutLong(_offset + CORRELATION_ID_OFFSET, correlationId); return(this); }
public SessionKeepAliveEncoder LeadershipTermId(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
public SnapshotRecordingQueryEncoder CorrelationId(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
public RecordingDescriptorEncoder ControlSessionId(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
public SessionEventEncoder ClusterSessionId(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
public ServiceAckEncoder LogPosition(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
public VoteEncoder CandidateTermId(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
public RemoveClusterMemberEncoder CorrelationId(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
public ChallengeEncoder ControlSessionId(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
public ElectionStartEventEncoder LogPosition(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
public StepsEncoder RecordingStartPosition(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
public RecoveryPlanEncoder LastLeadershipTermId(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
public RecoveryPlanEncoder CorrelationId(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
public MarkFileHeaderEncoder ActivityTimestamp(long value) { _buffer.PutLong(_offset + 8, value, ByteOrder.LittleEndian); return(this); }
public TerminationPositionEncoder LogPosition(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
/// <summary> /// set correlation id field /// </summary> /// <param name="correlationId"> field value </param> /// <returns> for fluent API </returns> public OperationSucceededFlyweight CorrelationId(long correlationId) { buffer.PutLong(offset + CORRELATION_ID_FIELD_OFFSET, correlationId); return(this); }
public EntriesEncoder RecordingId(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
public RequestVoteEncoder LogLeadershipTermId(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
public DetachSegmentsRequestEncoder ControlSessionId(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
/// <summary> /// Set correlation ID of the offending command. /// </summary> /// <param name="correlationId"> of the offending command </param> /// <returns> flyweight </returns> public ErrorResponseFlyweight OffendingCommandCorrelationId(long correlationId) { _buffer.PutLong(_offset + OFFENDING_COMMAND_CORRELATION_ID_OFFSET, correlationId); return(this); }
public RecordingPositionRequestEncoder ControlSessionId(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
public AuthConnectRequestEncoder CorrelationId(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
/// <summary> /// Set the correlation id field /// </summary> /// <param name="correlationId"> field value </param> /// <returns> flyweight </returns> public CounterUpdateFlyweight CorrelationId(long correlationId) { buffer.PutLong(offset + CORRELATION_ID_OFFSET, correlationId); return(this); }
/// <summary> /// Set the correlation id field /// </summary> /// <param name="correlationId"> field value </param> /// <returns> flyweight </returns> public SubscriptionReadyFlyweight CorrelationId(long correlationId) { buffer.PutLong(offset + CORRELATION_ID_OFFSET, correlationId); return(this); }
public StopAllReplaysRequestEncoder ControlSessionId(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
public ChallengeResponseEncoder CorrelationId(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
public ClusterActionRequestEncoder LogPosition(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }
public AddPassiveMemberEncoder CorrelationId(long value) { _buffer.PutLong(_offset + 0, value, ByteOrder.LittleEndian); return(this); }