optional
| 73 | |
| 74 | // optional |
| 75 | static void CallAfterRpc(brpc::Controller* cntl, |
| 76 | const google::protobuf::Message* req, |
| 77 | const google::protobuf::Message* res) { |
| 78 | // at this time res is already sent to client, but cntl/req/res is not destructed |
| 79 | std::string req_str; |
| 80 | std::string res_str; |
| 81 | json2pb::ProtoMessageToJson(*req, &req_str, NULL); |
| 82 | json2pb::ProtoMessageToJson(*res, &res_str, NULL); |
| 83 | LOG(INFO) << "req:" << req_str |
| 84 | << " res:" << res_str; |
| 85 | } |
| 86 | }; |
| 87 | |
| 88 | int main(int argc, char* argv[]) { |
nothing calls this directly
no test coverage detected