Subject: | id in json-rpc |
Hi!
Could you describe the purpose of JSONRPC::request_id?
I had to comment out the call to it in
JSONRPC::Transport::HTTP::Server::handle to get the RPC server to
work :-)
JSONRPC::Transport::HTTP::Server::handle is being called via
Apache::JSONRPC in my setup.
I attached the diff I used to get it running.
Thanks!
Todd W.
Subject: | remove_id_check.diff |
--- src/JSON-1.07/lib/JSONRPC/Transport/HTTP.pm Sun Nov 20 21:28:19 2005
+++ lib/JSONRPC/Transport/HTTP.pm Mon Jul 10 09:20:11 2006
@@ -69,14 +69,14 @@
= eval q| $jp->parse($req->content) |
or return $self->send_response( $self->invalid_request() );
- if( defined $self->request_id($self->{json_data}->{id}) ){
+# if( defined $self->request_id($self->{json_data}->{id}) ){
my $res = $self->handle_method($req) or return $self->invalid_request();
return $self->send_response( $self->response($res) );
- }
- else{
- $self->notification();
- $self->send_response( $self->no_response() );
- }
+# }
+# else{
+# $self->notification();
+# $self->send_response( $self->no_response() );
+# }
}
else{
$self->send_response( $self->invalid_request() );