Update README

This commit is contained in:
Tony Garnock-Jones 2016-11-21 11:24:54 +13:00
parent 763d218927
commit 5590c754c4
2 changed files with 49 additions and 3 deletions

View File

@ -1,5 +1,5 @@
RacketMQ
Copyright © 2015, 2016 Tony Garnock-Jones <tonyg@leastfixedpoint.com>
Copyright © 2016 Tony Garnock-Jones <tonyg@leastfixedpoint.com>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as

View File

@ -12,7 +12,9 @@ WebSub.
See the specification of the W3C WebSub protocol at
<https://www.w3.org/TR/pubsub/> (and track its development at
<https://github.com/w3c/pubsub>).
**N.B.: Those URLs will eventually have `websub` in place of `pubsub`.**
**N.B.: These URLs will eventually have `websub` in place of `pubsub`.**
[w3cspec]: https://www.w3.org/TR/pubsub/
## Features
@ -42,9 +44,53 @@ implementation criteria at <https://github.com/w3c/pubsub/issues/56>.
Please report issues using this project's Github issues page,
<https://github.com/tonyg/racketmq/issues>.
## Hub URL layout
- `/hub` — Local subscription management; main Hub URL.
This is the main URL for creating and deleting subscriptions to
(local or remote) topics.
- method `POST`: create or delete a subscription, following
[the specification][w3cspec]. Supply `hub.mode`, `hub.topic`,
`hub.callback` and other relevant parameters to manage
subscriptions.
- `/topic/`*topic* — Local topic endpoint.
A *local topic* is a topic managed by this hub. Publishers `POST`
their content to the local topic endpoint, and subscribers are
notified of the change. Local topics may be managed explicitly or
implicitly; any subscription to a local topic will automatically
cause it to be created, even if it has not been previously
explicitly `PUT` into existence.
- method `PUT`: create a local topic explicitly
- method `DELETE`: delete an explicitly-created local topic
- method `HEAD`: get headers associated with the most recent topic value
- method `GET`: get the most recent topic value
- method `POST`: update the topic value with the post body
- `/sub/`*sub-id* — Upstream subscription endpoint.
When a subscription to a remote topic is created, if the remote
topic has an advertised hub, this hub subscribes to the remote hub,
and content distribution requests are `POST`ed to a fresh upstream
subscription endpoint URL.
- method `GET`: for verification-of-intent requests from upstream.
- method `POST`: for content distribution requests from upstream.
- `/`*path/to/file/in/htdocs* — Static resource.
The `racketmq/htdocs` subdirectory contains static resources to be
served by the hub.
- method `GET`: retrieve a static resource.
## License
Copyright © 2015, 2016 Tony Garnock-Jones <tonyg@leastfixedpoint.com>
Copyright © 2016 Tony Garnock-Jones <tonyg@leastfixedpoint.com>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as