(data-message? mp msg)(error-message? mp msg)(new-data-message mc session)(new-error-message mc session)(read-data-message mc msg)(read-error-message mc msg)(write-data-message mc msg data)(write-error-message mc msg err)(publish! {:as publisher :keys [session concurrent? message-protocol producer]}
data)Broadcasts a message to the Topic of the publisher
Broadcasts a message to the Topic of the publisher
(publisher connection
{:keys [concurrent? topic delivery-mode time-to-live
message-protocol]
:or {concurrent? true
delivery-mode :non-persistent
time-to-live *default-message-expiration*}})Builds a publisher object for unidirectional async messaging to multiple consumers
Builds a publisher object for unidirectional async messaging to multiple consumers
(rebuild-requestor c r)Closes Requestor r and then creates a new Requestor on Connection c that uses the same settings as the original Requestor r.
Closes Requestor r and then creates a new Requestor on Connection c that uses the same settings as the original Requestor r.
(rebuild-responder c r)Closes Responder r and then creates a new Responder on Connection c that uses the same settings as the original responder r.
Closes Responder r and then creates a new Responder on Connection c that uses the same settings as the original responder r.
(rebuild-subscriber c s)Closes Subscriber s and then creates a new Subscriber with the same settings on Connection c
Closes Subscriber s and then creates a new Subscriber with the same settings on Connection c
(requestor connection
{:keys [concurrent? request-queue request-delivery-mode
request-expiration message-protocol]
:or {concurrent? true
request-delivery-mode :non-persistent
request-expiration *default-message-expiration*}})Constructs a new Requestor on the JMS connection. The following options are accepted:
:request-queue :: required. The name of the queue where requests will be sent.
:message-protocol :: required. Implementation of MessageProtocol used to encode request messages and decode response messages.
:concurrent? :: optional, default=true. When true, the requestor is thread-safe under concurrency. When false the requestor is NOT thread-safe.
:request-delivery-mode :: optional, default=:non-persistent. The delivery-mode used for request messages.
:request-expiration :: optional, default=default-message-expiration. The time-to-live for request messages.
Constructs a new Requestor on the JMS connection.
The following options are accepted:
- :request-queue :: required. The name of the queue where requests will be sent.
- :message-protocol :: required. Implementation of MessageProtocol used to encode request messages
and decode response messages.
- :concurrent? :: optional, default=true. When true, the requestor is thread-safe under concurrency.
When false the requestor is NOT thread-safe.
- :request-delivery-mode :: optional, default=:non-persistent. The delivery-mode used for request messages.
- :request-expiration :: optional, default=*default-message-expiration*. The time-to-live for request messages.(responder connection
{:keys [request-queue message-protocol request-handler
reply-delivery-mode reply-expiration]})Creates a new Responder on connection using the settings specified in the option map:
:request-queue :: required, the name of the queue to listen on for requests.
:message-protocol :: required, implementation of MessageProtocol that defines how request messages are decoded/read and how response messages are created/encoded.
:request-handler :: required, a function that accepts the decoded request data and returns the data that should be sent in response.
:reply-delivery-mode :: optional, the delivery-mode to use for reply/response messages.
:reply-expiration :: optional, the time-to-live for reply/response messages.
Creates a new Responder on connection using the settings specified
in the option map:
- :request-queue :: required, the name of the queue to listen on for requests.
- :message-protocol :: required, implementation of MessageProtocol that defines
how request messages are decoded/read and how response messages
are created/encoded.
- :request-handler :: required, a function that accepts the decoded request data and returns
the data that should be sent in response.
- :reply-delivery-mode :: optional, the delivery-mode to use for reply/response messages.
- :reply-expiration :: optional, the time-to-live for reply/response messages.(send-request! r data)Uses Requestor r to send data to a remote Responder service.
Uses Requestor r to send data to a remote Responder service.
(subscriber connection {:keys [topic message-protocol handler]})Creates a new Subscriber on the connection that will listen for messages broadcast to the topic.
The following options are required:
Creates a new Subscriber on the connection that will
listen for messages broadcast to the topic.
The following options are required:
- :topic :: required, the name of the topic to subscribe to.
- :message-protocol :: required, an instance of MessageProtocol used to decode messages.
- :handler :: a function of 2 arguments s (the Subscriber) and d (the data contained the message),
called whenever a message is received.cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |