[cl-json-devel] Question about JSON-RPC

Robert Goldman rpgoldman at sift.info
Wed Dec 30 15:37:30 UTC 2009


I am setting up a JSON-RPC server over sockets, rather than HTTP, and
have a couple of questions about json-rpc.lisp:

1.  Am I correct in thinking that INVOKE-JSON does not handle
notifications?  It looks like it will always try to return a result.
Question:  would it be reasonable to modify INVOKE-JSON to handle
notifications by just executing the function and /not/ returning a result?

2.  My socket server must parse JSON messages and decide what type they
are before it can call invoke-json.  This suggests refactoring
invoke-json into two stages:

  a.  the part that calls the decoder and pulls out the three slots

  b.  an inside function that accepts method, params, id, and does the
actual invoking.

I was thinking of submitting a patch along those lines.  Please let me
know if that seems wrong.

thanks,
r




More information about the cl-json-devel mailing list