Class DebugSendChannelEndpoint

All Implemented Interfaces:
AutoCloseable

public class DebugSendChannelEndpoint extends SendChannelEndpoint
Debug implementation which can introduce loss.
  • Constructor Details

  • Method Details

    • send

      public int send(ByteBuffer buffer)
      Send contents of a ByteBuffer to connected address. This is used on the sender side for performance over send(ByteBuffer, SocketAddress).
      Overrides:
      send in class SendChannelEndpoint
      Parameters:
      buffer - to send
      Returns:
      number of bytes sent
    • onStatusMessage

      public void onStatusMessage(StatusMessageFlyweight msg, UnsafeBuffer buffer, int length, InetSocketAddress srcAddress, DriverConductorProxy conductorProxy)
      Callback back handler for received status messages.
      Overrides:
      onStatusMessage in class SendChannelEndpoint
      Parameters:
      msg - flyweight over the status message.
      buffer - containing the message.
      length - of the message.
      srcAddress - of the message.
      conductorProxy - to send messages back to the conductor.
    • onNakMessage

      public void onNakMessage(NakFlyweight msg, UnsafeBuffer buffer, int length, InetSocketAddress srcAddress)
      Callback back handler for received NAK messages.
      Overrides:
      onNakMessage in class SendChannelEndpoint
      Parameters:
      msg - flyweight over the NAK message.
      buffer - containing the message.
      length - of the message.
      srcAddress - of the message.
    • onRttMeasurement

      public void onRttMeasurement(RttMeasurementFlyweight msg, UnsafeBuffer buffer, int length, InetSocketAddress srcAddress)
      Callback back handler for received RTT Measurement messages.
      Overrides:
      onRttMeasurement in class SendChannelEndpoint
      Parameters:
      msg - flyweight over the RTT message.
      buffer - containing the message.
      length - of the message.
      srcAddress - of the message.