Home
Registering with the broker
Publisher applications can register their intention to publish with a broker.
There are two ways for a publisher to register with a broker:
- The publisher can send a Register Publisher command message to the broker's control queue...
SYSTEM.BROKER.CONTROL.QUEUE...to indicate that a publisher will be, or is capable of, publishing data on one or more specified topics. This message can also be sent by another application on a publisher's behalf.
- The publisher can register with the broker implicitly when it sends its first Publish command message to a stream queue at the broker, such as...
SYSTEM.BROKER.DEFAULT.STREAM...or...
SAMPLE.BROKER.RESULTS.STREAMIf the broker is not currently aware of the stream specified, a Register Publisher command message is necessary for the broker to recognize the stream queue.
A publishing application might not know if a stream is supported by a particular broker. In this case it is recommended that the publisher issues the Register Publisher command message and waits for a response that indicates that the stream is known to the broker, before sending the first Publish command message.
An application can register with the same broker more than once, and can also register with many different brokers. An application that is already registered as a subscriber can also register as a publisher. This is the case in the sample application (see Sample application). The results service registers as a subscriber to the events published by the match simulators, and as a publisher of the latest scores.
Home