"id
The same id as in the Request it is responding to. If there was an
error before detecting the id in the Request (e.g. Parse error/Invalid
Request), it MUST be Null."
Would it be possible to add some explanation for this? It's hard to
guess what the client should do with such an error message, in the
general case.
As for what the client would do... not a whole lot I'm guessing. It
could be a response to one of many requests that have been sent out...
assuming this is caused by bad json being sent or being mangled on the
wire, it might throw a general error. If it can match one for one, I
would say it could be handled by elimination and passed up to the app
to handle. The server is basically doing all it can, which isn't much.
--
Matt (MPCM)
If the error is an error either in the transmission of the message
(data corruption) or an improperly formed message then the protocol is
not being called. This helps differentiate cases where the query is
valid or invalid.