Pubsub
Pubsub (from 'publish-subscribe') is an XMPP extension (XEP-0060 that allows pieces of data to be published to 'nodes', and then automatically broadcast to any subscribers to those nodes. This is similar to technologies like RSS, except that instead of subscribers continuously checking for new data it is pushed to them in realtime.
Prosody comes with an internal pubsub service (mod_pubsub) that can be set up very simply:
"pubsub.example.com" "pubsub" Component
For a full list of options that can be used here, see mod_pubsub.
Features
XEP-0060 is a very large document, and pubsub can grow to be a complex task. Different applications require very different feature sets. Prosody currently implements the following features (as of 0.11.0):
- Create node
- Delete node
- Subscribe
- Unsubscribe
- Get subscriptions
- Publish
- Retract
- Get items
- Purge
- Service discovery
- Discover Node Metadata
- Configure a Node
- Create and Configure a Node
- Subscribe and Configure
- Retrieve Subscriptions
- Manage Subscriptions
- Manage Affiliations
- Configure Subscription Options
- Persistence of node configuration and data
- Including a Message Body via internal API
- Node Access Models
open
,whitelist
andpresence
- Publishing Options
Unreleased features as of July 2021 include:
- Using “max” as limit in certain fields.