There are several messaging standards that are push based (e.g., MQTT, STORM). Are there any messaging protocols that are pull based?
Use-case:
Company A currently offers a MQTT endpoint that supports several topics. When an event is published to a topic, the MQTT server pushes the event to all the subscribers.
However, there are some shortcomings that company A would like to address:
- When an new subscriber registers to receive events published to a topic, she would like to receive all the messages ever published to that topic.
- Whenever there is a "hot" topic, i.e., lot of events are published in a short period of time to that topic, dispatching those events to the registered subscribers might overwhelm the subscribers. And so, subscribers would like to pull events from the topic at their own pace.
Current Solution:
Company A exposed a HTTP endpoint, that has the get-event
operation which retrieves the events (e.g., numbered 1034567
to 1034578
published to the the topic named some-hot-topic
in the curl invocation below):
curl http://pull.company-a.com/get-events?topic=some-hot-topic&start-at=1034567&stop-at=1034578
The Question:
Instead a building this one off solution, where Company A has a to define the format of the URL, and the format of the response payload, can Company A use any standards that already define these to solve the problem (the standard does not have to be HTTP based).
Couple of things come to mind (e.g., Kafka Consumer REST API, RSS) that address a similar problem in a different context but nothing seems to be defined with the intent of serving the purpose of a standard for a pull based event notification protocol.