You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I use the rd_kafka_queue_poll function, I get back a pointer to a rd_kafka_event_t , which I can pass to rd_kafka_event_error to get a rd_kafka_resp_err_t, which I can (finally) pass to rd_kafka_error_is_retriable to determine if the error is the result of some operation that can be retried.
By comparison, when I use rd_kafka_consumer_poll, I get back a rd_kafka_message_t, which may contain an rd_kafka_resp_err_t. I don't see any functionality in librdkafka that will allow me to determine if that error is the result of performing some operation which may be retried. Instead, my code contains a huge case/switch statement that handles all of the various error codes, and conditionally retries an operation if the returned code is in some set of codes which I have determined to be retriable.
So, my question is: Does there exist a function like rd_kafka_error_is_retriable that I can or should be using with the rd_consumer_poll function?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
When I use the
rd_kafka_queue_poll
function, I get back a pointer to ard_kafka_event_t
, which I can pass tord_kafka_event_error
to get ard_kafka_resp_err_t
, which I can (finally) pass tord_kafka_error_is_retriable
to determine if the error is the result of some operation that can be retried.By comparison, when I use
rd_kafka_consumer_poll
, I get back ard_kafka_message_t
, which may contain anrd_kafka_resp_err_t.
I don't see any functionality in librdkafka that will allow me to determine if that error is the result of performing some operation which may be retried. Instead, my code contains a huge case/switch statement that handles all of the various error codes, and conditionally retries an operation if the returned code is in some set of codes which I have determined to be retriable.So, my question is: Does there exist a function like
rd_kafka_error_is_retriable
that I can or should be using with therd_consumer_poll
function?Beta Was this translation helpful? Give feedback.
All reactions