Open akheron opened 13 years ago
It would be cool to identify other Github repos that have Jansson as a dependency and use those for "case study" style tutorials. I learned about Jansson and some good uses from Webdis, for example.
@mrb True. Do you happen to know any others than webdis?
for ^, we were using it for configuration files too for some time but jansson doesn't work very well in this role.
The interesting stuff (RPC) is here: craftd/plugins/httpd/src/HTTPd.c
Another one is https://github.com/derdewey/mongrel2_c_handler/
I know I'm a bit late, but I use Jansson to parse RPCs to a Bitcoin server: libbitcoinrpc. Jansson is also mentioned at Bitcoin Wiki as the best way to make RPC processing in C.
And here is my case study: https://github.com/bitcoinrpc/libbitcoinrpc/blob/master/doc/examples.md
The only tutorial was written for v1.1 and has not been updated since. There are new (and old) features to cover.
There's a starting point for a tutorial using pack/unpack functionality here: http://pastebin.com/YnTMNKv2 (by Jonathan Landis)