rabbitmq / rabbitmq-server

Open source RabbitMQ: core server and tier 1 (built-in) plugins
https://www.rabbitmq.com/
Other
11.84k stars 3.9k forks source link

Management UI: Fix internal_server_error args for put vhost failures (backport #11585) #11590

Closed mergify[bot] closed 2 days ago

mergify[bot] commented 2 days ago

rabbit_mgmt_util:internal_server_error/4 expects an atom or binary and a string formattable term (~ts) as arguments but rabbit_mgmt_wm_vhost passes charlists and any term. This can cause a log formatter crash and an unexpected message in the management UI when attempting to add a vhost while a cluster is in a minority with Khepri enabled for example.

We can pass atoms for the Error parameter and binaries or strings for the Reason parameter to fix both issues.


This is an automatic backport of pull request #11585 done by Mergify.

michaelklishin commented 2 days ago

rabbitmq_management failures are unrelated to this PR. I'm working on them.