Skip to content

Commit

Permalink
Fix string substitution in check_rabbitmq_cluster
Browse files Browse the repository at this point in the history
The string substitution in the check_rabbitmq_cluster script was improperly configured outside of the print statement. As a result, users did not receive alerts when a RabbitMQ cluster went down and encountered TypeError: unsupported operand when executing the script.

Closes-bug: #2080883

Change-Id: I049146cbd029e809bfc500a98fd62fff24ebda95
  • Loading branch information
bryanfraschetti committed Sep 16, 2024
1 parent 53bdfe8 commit 0914109
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion files/check_rabbitmq_cluster.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,8 @@
if (partitions > 0 or cluster < 0):
print(
"CRITICAL: %d partitions detected, %d nodes online."
) % (partitions, cluster)
% (partitions, cluster)
)
sys.exit(2)
else:
print("OK: No partitions detected")
Expand Down

0 comments on commit 0914109

Please sign in to comment.