@Override
  public void callMethod(MethodDescriptor method, RpcController controller, Message request,
    Message responsePrototype, RpcCallback<Message> done) {
    addListener(
      callerBuilder.action((c, s) -> rpcCall(method, request, responsePrototype, c, s)).call(),
      (r, e) -> {
        if (e != null) {
          ((ClientCoprocessorRpcController) controller).setFailed(e);
        }
        done.run(r);
      });
  }
The implementation of a region server based coprocessor rpc channel.
hbase-client/src/main/java/org/apache/hadoop/hbase/client/RegionServerCoprocessorRpcChannelImpl.java