InvocationEventHandler is a bag of callbacks for handling events that occur in the course of invoking an RPC. The handler also provides request data that is sent. The callbacks are generally called in the order they are listed below.
| 25 | // of invoking an RPC. The handler also provides request data that is sent. The callbacks are |
| 26 | // generally called in the order they are listed below. |
| 27 | type InvocationEventHandler interface { |
| 28 | // OnResolveMethod is called with a descriptor of the method that is being invoked. |
| 29 | OnResolveMethod(*desc.MethodDescriptor) |
| 30 | // OnSendHeaders is called with the request metadata that is being sent. |
| 31 | OnSendHeaders(metadata.MD) |
| 32 | // OnReceiveHeaders is called when response headers have been received. |
| 33 | OnReceiveHeaders(metadata.MD) |
| 34 | // OnReceiveResponse is called for each response message received. |
| 35 | OnReceiveResponse(proto.Message) |
| 36 | // OnReceiveTrailers is called when response trailers and final RPC status have been received. |
| 37 | OnReceiveTrailers(*status.Status, metadata.MD) |
| 38 | } |
| 39 | |
| 40 | // RequestMessageSupplier is a function that is called to retrieve request |
| 41 | // messages for a GRPC operation. This type is deprecated and will be removed in |
no outgoing calls
no test coverage detected
searching dependent graphs…