Repository navigation
rgw/notification: Kafka persistent notifications not retried and removed even when the broker is down - #54215
Conversation
40264ba to
f3a5dfa
Compare
|
This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved |
f3a5dfa to
9de3855
Compare
9de3855 to
c055ae1
Compare
|
@kchheda3 thanks for the fix. conn_it->second->status = STATUS_CONNECTION_IDLE;before line 466. to make sure that if dtor is invoked with some other reason we don't override it (though, currently there is no difference between the fixes). on a different note (and probably in a different PR), the librdkafka library should have its own retry mechanism. which is controlled by both global and topic level parameters: |
|
another small fix (unrelated to this one): the queue length logged in line 424 is off by 1. since the length is taken before emplace the new callback in the queue. could you please log |
conn_it->second->status = STATUS_CONNECTION_IDLE;before line 466. to make sure that if dtor is invoked with some other reason we don't override it (though, currently there is no difference between the fixes). on a different note (and probably in a different PR), the librdkafka library should have its own retry mechanism. which is controlled by both global and topic level parameters: Yep that would definitely make sense.. instead of waiting for the callback to reflect the actual status we should have the retries param of kafka configured. |
… not retried. Signed-off-by: kchheda3 <[email protected]>
c055ae1 to
b2fadb6
Compare
done |
|
teuthology is failing due to a crash: http://pulpito.front.sepia.ceph.com/yuvalif-2023-10-31_07:50:02-rgw:notifications-wip-yuval-kafka-break-distro-default-smithi/ could not find an actual crash, but seen this in the test log: this is similar to the crash tracked here: https://tracker.ceph.com/issues/63314 |
hmm.. so this crash is unrelated to the fix then |
yes. but the test are not running due to the crash |
not able to open the pulpito/sepia link, for which test case is the crash happening while running the bn_test.py ? |
|
|
@yuvalif can we merge this pull request ? |
i will rerun teuthology (the cras hthat prevented the run is now fixed) |
|
teuthology run: https://pulpito.ceph.com/yuvalif-2023-12-06_05:25:59-rgw:notifications-wip-yuval-test-63335-distro-default-smithi/ |
Currently the way, Kafka processing works is when the ACK level is set to broker, the notification is sent to kafka using the rd_kafka_produce(), which currently DOES not return -1 if the BROKER is down.
But when the broker is down, the CALLBACK from kafka acknowledgement is NEVER returned and hence this ack is propagated back to notification system which then does a retry and does not delete the persistent notification from queue.
But after the #51864, the connection was destroyed after idle_timeout and callbacks were invoked with SUCCESS coz default status was SUCCESS, so even tho the notification were not delivered, they were removed from the queue because the callback was invoked with success.
Fixes https://tracker.ceph.com/issues/63335
Contribution Guidelines
To sign and title your commits, please refer to Submitting Patches to Ceph.
If you are submitting a fix for a stable branch (e.g. "pacific"), please refer to Submitting Patches to Ceph - Backports for the proper workflow.
Checklist
Show available Jenkins commands
jenkins retest this pleasejenkins test classic perfjenkins test crimson perfjenkins test signedjenkins test make checkjenkins test make check arm64jenkins test submodulesjenkins test dashboardjenkins test dashboard cephadmjenkins test apijenkins test docsjenkins render docsjenkins test ceph-volume alljenkins test ceph-volume toxjenkins test windows