Logged invoked RPC method name.

pull/1/head
Tatsuhiro Tsujikawa 2011-06-07 23:33:04 +09:00
parent e958f5dab3
commit 51dc544f2b
1 changed files with 2 additions and 0 deletions

View File

@ -187,6 +187,7 @@ HttpServerBodyCommand::processJsonRpcRequest(const Dict* jsondict)
return createJsonRpcErrorResponse(-32601, "Method not found.", id); return createJsonRpcErrorResponse(-32601, "Method not found.", id);
} }
method->setJsonRpc(true); method->setJsonRpc(true);
A2_LOG_INFO(fmt("Executing RPC method %s", req.methodName.c_str()));
rpc::RpcResponse res = method->execute(req, e_); rpc::RpcResponse res = method->execute(req, e_);
return res; return res;
} }
@ -216,6 +217,7 @@ bool HttpServerBodyCommand::execute()
rpc::XmlRpcRequestProcessor().parseMemory(httpServer_->getBody()); rpc::XmlRpcRequestProcessor().parseMemory(httpServer_->getBody());
SharedHandle<rpc::RpcMethod> method = SharedHandle<rpc::RpcMethod> method =
rpc::RpcMethodFactory::create(req.methodName); rpc::RpcMethodFactory::create(req.methodName);
A2_LOG_INFO(fmt("Executing RPC method %s", req.methodName.c_str()));
rpc::RpcResponse res = method->execute(req, e_); rpc::RpcResponse res = method->execute(req, e_);
bool gzip = httpServer_->supportsGZip(); bool gzip = httpServer_->supportsGZip();
std::string responseData = res.toXml(gzip); std::string responseData = res.toXml(gzip);