Class RPCPlugin

java.lang.Object
org.apache.avro.ipc.RPCPlugin
Direct Known Subclasses:
StatsPlugin

public class RPCPlugin extends Object
An instrumentation API for RPC metadata. Each of these methods is invoked at key points during the RPC exchange. Additionally, path-based metadata that is passed along with the RPC call and can be set or queried by subsequent instrumentation points.
  • Constructor Details

    • RPCPlugin

      public RPCPlugin()
  • Method Details

    • clientStartConnect

      public void clientStartConnect(RPCContext context)
      Called on the client before the initial RPC handshake to setup any handshake metadata for this plugin
      Parameters:
      context - the handshake rpc context
    • serverConnecting

      public void serverConnecting(RPCContext context)
      Called on the server during the RPC handshake
      Parameters:
      context - the handshake rpc context
    • clientFinishConnect

      public void clientFinishConnect(RPCContext context)
      Called on the client after the initial RPC handshake
      Parameters:
      context - the handshake rpc context
    • clientSendRequest

      public void clientSendRequest(RPCContext context)
      This method is invoked at the client before it issues the RPC call.
      Parameters:
      context - the per-call rpc context (in/out parameter)
    • serverReceiveRequest

      public void serverReceiveRequest(RPCContext context)
      This method is invoked at the RPC server when the request is received, but before the call itself is executed
      Parameters:
      context - the per-call rpc context (in/out parameter)
    • serverSendResponse

      public void serverSendResponse(RPCContext context)
      This method is invoked at the server before the response is executed, but before the response has been formulated
      Parameters:
      context - the per-call rpc context (in/out parameter)
    • clientReceiveResponse

      public void clientReceiveResponse(RPCContext context)
      This method is invoked at the client after the call is executed, and after the client receives the response
      Parameters:
      context - the per-call rpc context