|
libbmq b6028b29b733bc7541593d2905a5f79a9f0192fc
|
Provide a builder for batching confirmation messages. More...
#include <bmqa_message.h>#include <bmqt_resultcode.h>#include <bdlbb_blob.h>#include <bsls_alignedbuffer.h>Go to the source code of this file.
Classes | |
| class | BloombergLP::bmqa::ConfirmEventBuilder |
| Mechanism to build a batch of CONFIRM messages. More... | |
Namespaces | |
| namespace | BloombergLP |
| namespace | BloombergLP::bmqa |
This component implements a mechanism, bmqa::ConfirmEventBuilder, that can be used for batching CONFIRM messages. The resulting batch can be sent to the BlazingMQ broker using the bmqa::Session (refer to bmqa_session.h for details). Wherever possible, a BlazingMQ consumer should try to send a batch of CONFIRM messages, which is more efficient than confirming messages individually.
The builder holds a batch of CONFIRM messages under construction, and provides two flavors of addMessageConfirmation method to add a CONFIRM message to the batch. It also provides a routine to retrieve number of CONFIRM messages added to the batch. Once application is done creating the batch, it can retrieve the blob (wire-representation) of the batch and send it via bmqa::Session. See the usage section for more details.
This component is NOT thread safe. If it is desired to create a batch of CONFIRM messages from multiple threads, an instance of the builder must be created and maintained per thread.