Subscriber provides the capability to subscribe to protobuf ZMQ topics and being notified through callbacks to a (shared for all topics) handler.
More...
Subscriber provides the capability to subscribe to protobuf ZMQ topics and being notified through callbacks to a (shared for all topics) handler.
def rad.services.pubsub.ZmqSubscriber.__init__ |
( |
|
self, |
|
|
|
zmq_ctx |
|
) |
| |
def rad.services.pubsub.ZmqSubscriber.__init__ |
( |
|
self, |
|
|
|
zmq_ctx |
|
) |
| |
def rad.services.pubsub.ZmqSubscriber.connect |
( |
|
self, |
|
|
|
endpoint |
|
) |
| |
def rad.services.pubsub.ZmqSubscriber.connect |
( |
|
self, |
|
|
|
endpoint |
|
) |
| |
def rad.services.pubsub.ZmqSubscriber.disconnect |
( |
|
self, |
|
|
|
endpoint |
|
) |
| |
Disconnect from endpoint.
def rad.services.pubsub.ZmqSubscriber.disconnect |
( |
|
self, |
|
|
|
endpoint |
|
) |
| |
Disconnect from endpoint.
def rad.services.pubsub.ZmqSubscriber.is_closed |
( |
|
self, |
|
|
|
bool |
|
) |
| |
Returns true if subscriber is not running, false otherwise.
def rad.services.pubsub.ZmqSubscriber.is_closed |
( |
|
self, |
|
|
|
bool |
|
) |
| |
Returns true if subscriber is not running, false otherwise.
def rad.services.pubsub.ZmqSubscriber.start |
( |
|
self | ) |
|
Start reading from socket.
- Todo:
- : Return future instead?
- Returns
- Coroutine. The ZMQ socket reader coro that needs to be awaited on.
def rad.services.pubsub.ZmqSubscriber.start |
( |
|
self | ) |
|
Start reading from socket.
- Todo:
- : Return future instead?
- Returns
- Coroutine. The ZMQ socket reader coro that needs to be awaited on.
def rad.services.pubsub.ZmqSubscriber.stop |
( |
|
self | ) |
|
Unbinds socket and shuts down all related tasks to this Replier.
The ZmqMsgReplier is essentially dead after this.
- Returns
- Future that resolves once server has been closed.
def rad.services.pubsub.ZmqSubscriber.stop |
( |
|
self | ) |
|
Unbinds socket and shuts down all related tasks to this Replier.
The ZmqMsgReplier is essentially dead after this.
- Returns
- Future that resolves once server has been closed.
def rad.services.pubsub.ZmqSubscriber.subscribe |
( |
|
self, |
|
|
|
topic_name |
|
) |
| |
Subscribe on the topic topic_name
.
- Note
- ZMQ topic filtering is done simply on the start of the string, subscribing to 'foo' will match the published topic 'foobar'.
- Params
- topic_name Topic name (str or bytes).
def rad.services.pubsub.ZmqSubscriber.subscribe |
( |
|
self, |
|
|
|
topic_name |
|
) |
| |
Subscribe on the topic topic_name
.
- Note
- ZMQ topic filtering is done simply on the start of the string, subscribing to 'foo' will match the published topic 'foobar'.
- Params
- topic_name Topic name (str or bytes).
def rad.services.pubsub.ZmqSubscriber.unsubscribe |
( |
|
self, |
|
|
|
topic_name |
|
) |
| |
Unsubscribe to topic identified by topic_name
.
def rad.services.pubsub.ZmqSubscriber.unsubscribe |
( |
|
self, |
|
|
|
topic_name |
|
) |
| |
Unsubscribe to topic identified by topic_name
.
The documentation for this class was generated from the following files:
- INTROOT/lib/python3.7/site-packages/rad/services/pubsub.py
- rad/py/rad/src/rad/services/pubsub.py