Buffered producer thread safe (#72)

* Thread safe buffered producer

* Using single mutex version

* Changed based on feedback

* Changes based on latest review

* Added flush counter
This commit is contained in:
Alex Damian
2018-05-28 21:33:36 -04:00
committed by Matias Fontanini
parent f543810515
commit 429ec92369
8 changed files with 387 additions and 88 deletions

View File

@@ -82,6 +82,7 @@ public:
* The policy to use for the payload. The default policy is COPY_PAYLOAD
*/
enum class PayloadPolicy {
PASSTHROUGH_PAYLOAD = 0, ///< Rdkafka will not copy nor free the payload.
COPY_PAYLOAD = RD_KAFKA_MSG_F_COPY, ///< Means RD_KAFKA_MSG_F_COPY
FREE_PAYLOAD = RD_KAFKA_MSG_F_FREE ///< Means RD_KAFKA_MSG_F_FREE
};