简体   繁体   中英

Go JSON RPC v2 over HTTP

In the Go world is there any project implements the JSON RPC 2.0 (HTTP), especially the feature of batched query?

Some background that is, I know there's a Go built-in one but it's not over HTTP, and Gorilla looks to supports V2 (in the v2 folder, however I can't find documentation with it), but as I tested it response empty result for a combined request like "[{valid_request...},{valid_request...}]". Maybe it hasn't implemented the batched one. (Have I missed anything to get it right?)

Since I can't find a ready Go server support for JsonRpc 2.0 for now, I modified the gorilla JsonRPC 2.0 to support the batched query. The forked repo is at https://github.com/jason-xxl/rpc . Just need to change the import path from "gorilla/rpc/v2" to "jason-xxl/rpc/v2_batch" to get a testable batched query enabled server. (Please let me know if I missed any one that already support 2.0 batch.)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM