Closed matsev closed 5 days ago
This makes sense. The tricky part would be to maintain compatibility by keeping the nacked and rejected existing metrics without the requeue information, and new metrics with the requeue information.
PR welcome.
Fixed PR: #1469
@matsev There is a new requeued message count metric, can you try out the snapshot and let us know if it is what you expected? Thanks to @ohksj77 for this contribution.
I did a quick test and I can verify that the new requeued
metrics is emitted by the MicrometerMetricsCollector
.
Thanks!
Is your feature request related to a problem? Please describe.
To my understanding there are currently no metrics emitted that distinguish whether or not a message was requeued when it was NACK:ed by the consumer
Describe the solution you'd like
One suggestion is to enhance the MetricsCollector with a new methods:
These methods would then be called with the
requeue
parameter provided whenever a messages is NACK:ed. Moreover, existing implementation such as the MicrometerMetricsCollector should implement the methods so that the metrics emitted also has knowledge about therequeue
stateDescribe alternatives you've considered
Application developers can implement their own custom metrics
Additional context
Related question at Stack Overflow: https://stackoverflow.com/questions/79069702/reactive-rabbitmq-metrics-for-ack-nack-requeue-false-and-nack-requeue-t