Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 4.0
Goal

The benefits of exposing DistributeMe service using JSON is that it be more easily to do tunneling then RMI.

The flow of exposing service can be as following:

Communication flow:

A) Client look up Registry for target service;

B) Registry return target service descriptor;

C) Client uses service descriptor details to connect HTTP endpoint and send JSON request;

D) Service generate JSON response and send to client;

E) Client connect HTTP service endpoint using existing reference;

F) Serivce generate JSON response and send it back to client;

In this case standalone service should act as HTTP endpoint to handle JSON calls.

Protocol

As basis for communication JSON-RPC standard could be used.

More details at:

http://groups.google.com/group/json-rpc/web/simple-method-description-for-json-rpc-example
http://en.wikipedia.org/wiki/JSON-RPC

Libraries:

Following HTTP server implementations can be used as embedded HTTP server:

  1. JDK 1.6 Embedded HTTP server
    Used in JaxWS endpoint implementation.
  2. Jetty
    Can be used as Servlet container

Following JSON-RPC 2.0 implementation could be used.

1. http://java-json-rpc.sourceforge.net/

2. http://oss.metaparadigm.com/jsonrpc/

JSON-RPC prototype described here