Skip to content

Conversation

@lukebakken
Copy link
Collaborator

@lukebakken lukebakken commented Dec 22, 2025

When management_agent.disable_metrics_collector and management.disable_stats are both set to true, the HTTP API returns minimal queue information that excludes policy-related fields and delivery_limit. This causes policy, operator_policy, effective_policy_definition, and delivery_limit to be null in API responses, even though these are configuration metadata rather than statistics.

This change adds these four fields to the format/2 function in both rabbit_classic_queue and rabbit_quorum_queue modules. The fields now appear in the type-specific formatting that runs regardless of metrics collection status. The three policy fields use existing i/2 function implementations that call rabbit_policy module functions. For delivery_limit, this change adds an i(delivery_limit, Q) function to rabbit_quorum_queue that extracts the delivery limit from the queue's x-delivery-limit argument, returning unlimited when not set.

Fixes #15182

@lukebakken lukebakken self-assigned this Dec 22, 2025
@lukebakken lukebakken force-pushed the rabbitmq-server-15182 branch from 0268c96 to 939fc4e Compare December 22, 2025 20:55
@lukebakken lukebakken marked this pull request as ready for review December 22, 2025 20:58
@lukebakken lukebakken changed the title Return policy fields when stats are disabled Return policy fields et. al when stats are disabled Dec 22, 2025
@lukebakken lukebakken force-pushed the rabbitmq-server-15182 branch from 939fc4e to 90c3700 Compare December 22, 2025 21:03
@lukebakken lukebakken marked this pull request as draft December 22, 2025 21:39
@lukebakken lukebakken force-pushed the rabbitmq-server-15182 branch from 90c3700 to bce2d3d Compare December 22, 2025 21:57
@lukebakken lukebakken changed the title Return policy fields et. al when stats are disabled Return policy fields and delivery_limit when stats are disabled Dec 22, 2025
@lukebakken lukebakken marked this pull request as ready for review December 22, 2025 22:49
When `management_agent.disable_metrics_collector` and
`management.disable_stats` are both set to `true`, the HTTP API returns
minimal queue information that excludes policy-related fields and
`delivery_limit`. This causes `policy`, `operator_policy`,
`effective_policy_definition`, and `delivery_limit` to be `null` in API
responses, even though these are configuration metadata rather than
statistics.

This change adds these four fields to the `format/2` function in both
`rabbit_classic_queue` and `rabbit_quorum_queue` modules. The fields now
appear in the type-specific formatting that runs regardless of metrics
collection status. The three policy fields use existing `i/2` function
implementations that call `rabbit_policy` module functions. For
`delivery_limit`, this change adds an `i(delivery_limit, Q)` function to
`rabbit_quorum_queue` that extracts the delivery limit from the queue's
`x-delivery-limit` argument, returning `unlimited` when not set.

Fixes rabbitmq#15182
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Disabling management statistics removes non-stats data from HTTP API

3 participants