17#ifndef INCLUDED_RMQP_PRODUCER
18#define INCLUDED_RMQP_PRODUCER
20#include <rmqt_queue.h>
22#include <rmqp_messagetransformer.h>
23#include <rmqp_topologyupdate.h>
24#include <rmqt_confirmresponse.h>
25#include <rmqt_exchange.h>
26#include <rmqt_message.h>
27#include <rmqt_result.h>
28#include <rmqt_topology.h>
30#include <bsls_timeinterval.h>
32#include <bsl_functional.h>
33#include <bsl_memory.h>
34#include <bsl_string.h>
35#include <rmqt_future.h>
37namespace BloombergLP {
69 const bsl::string& routingKey,
82 const bsl::shared_ptr<rmqp::MessageTransformer>& transformer) = 0;
120 const bsl::string& routingKey,
122 const bsls::TimeInterval& timeout) = 0;
168 const bsl::string& routingKey,
169 rmqt::Mandatory::Value mandatoryFlag,
171 const bsls::TimeInterval& timeout) = 0;
208 const bsl::string& routingKey,
RabbitMQ Producer API for publishing to a specific Exchange.
Definition: rmqp_producer.h:46
virtual SendStatus send(const rmqt::Message &message, const bsl::string &routingKey, const rmqp::Producer::ConfirmationCallback &confirmCallback, const bsls::TimeInterval &timeout)=0
Send a message with the given routingKey to the exchange targeted by the producer.
virtual rmqt::Result waitForConfirms(const bsls::TimeInterval &timeout)=0
Wait for all outstanding publisher confirms to arrive.
virtual void addTransformer(const bsl::shared_ptr< rmqp::MessageTransformer > &transformer)=0
Adds a transformation function to be run on all messages.
bsl::function< void(const rmqt::Message &, const bsl::string &routingKey, const rmqt::ConfirmResponse &)> ConfirmationCallback
Invoked on receipt of message confirmation.
Definition: rmqp_producer.h:71
virtual SendStatus send(const rmqt::Message &message, const bsl::string &routingKey, rmqt::Mandatory::Value mandatoryFlag, const rmqp::Producer::ConfirmationCallback &confirmCallback, const bsls::TimeInterval &timeout)=0
Send a message with the given routingKey to the exchange targeted by the producer.
virtual SendStatus trySend(const rmqt::Message &message, const bsl::string &routingKey, const rmqp::Producer::ConfirmationCallback &confirmCallback)=0
Send a message with the given routingKey to the exchange targeted by the producer.
Definition: rmqa_producer.cpp:55
SendStatus
Possible results of rmqp::Producer::send.
Definition: rmqp_producer.h:50
virtual rmqt::Future updateTopologyAsync(const rmqt::TopologyUpdate &topologyUpdate)=0
Updates topology.
An AMQP publisher confirm response.
Definition: rmqt_confirmresponse.h:33
An async-style Future/Promise object.
Definition: rmqt_future.h:108
An AMQP content message.
Definition: rmqt_message.h:43
A result of an operation.
Definition: rmqt_result.h:37
Definition: rmqt_topologyupdate.h:33