jstp / jstp-rfc

JSON Transfer Protocol RFC
0 stars 0 forks source link

JSTP URL Schema #8

Closed xaviervia closed 11 years ago

xaviervia commented 11 years ago

In order to simplify the description of JSTP dispatches, it would be nice to have a JSTP uri scheme.

JSTP is similar enough to HTTP to be described with similar structure in an uri, the main exceptions being the multiple hosts header and the complex nature of the Dispatch Body.

xaviervia commented 11 years ago

Samples

Local PUT Dispatch to User resource: PUT jstp:///User

Remote (one host) POST Dispatch to Article: POST jstp://db:8000:tcp/Article

Binding to double remote DELETE of Library/* : BIND DELETE jstp://hub:80:ws,building:80:ws/Library/*

xaviervia commented 11 years ago

In many cases, the jstp://prefix is verbose and avoidable, such as application logs. A simplified form will be:

POST db:8000:tcp/Article

Should any other type of data be listed in the URL? This looks ok, but maybe the Dispatch Body could be added using some kind of encoding, such as base64 or URL encoding, after a ?.

Also: Resources should be URL encoded when using URLs. Mainly because of the / char that can legally be used within a Resource Item.

xaviervia commented 11 years ago

Superseeded by JSTP URI Scheme RFC