Sign inSign up

lega911/ijson

By lega911

•Updated about 6 years ago

inverted json (Inverted JsonRPC Proxy)

Image
0

7.6K

lega911/ijson repository overview

Source code github/lega911/ijson⁠

⁠Tags
⁠Start Inverted Json
docker run -i -p 8001:8001 lega911/ijson
⁠Options
$ ijson
  --host 0.0.0.0:8001  # bind host:port
  --filter 192.168.0.0/24 --filter 70.0.0.0/8  # ip filters for clients
  --log 3  # mask for logs
  --jsonrpc2
⁠Example with curl (client + worker)
# 1. a worker publishes rpc command
curl -d '{"name": "/test/command"}' http://localhost:8001/rpc/add

# 2. a client invokes the command
curl -d '{"id": 123, "params": "test data"}' http://localhost:8001/test/command

# the worker receives {"id": 123, "params": "test data"}
# 3. and sends response with the same id
curl -d '{"id": 123, "result": "data received"}' http://localhost:8001/rpc/result

# client receives {"id": 123, "result": "data received"}

Tag summary

Content type

Image

Digest

Size

26 MB

Last updated

about 6 years ago

docker pull lega911/ijson