Skip to main content

RabbitMQ Queue Filling Up When Plugin Is Inactive

Problem

If a routing plugin is inactive for an extended period, its associated RabbitMQ queue may continue to receive messages but has no active consumer to process them.

This leads to:

  • Rapid queue growth
  • Increased disk usage
  • Potential disk exhaustion and service impact

Root Cause

  • Each plugin has an associated queue
  • When the plugin is inactive, no consumer is attached
  • Messages are still routed to the queue
  • The queue fills up indefinitely

How to Identify

Check for queues with:

  • 0 consumers
  • Increasing message count

Resolution

Option 1: Delete the Queue (RabbitMQ UI)

  1. Open the RabbitMQ Management UI:

    http://<1gateway-server>:15672
  2. Navigate to Queues

  3. Select the affected queue

  4. Click Delete > Delete queue

This ensures the queue stops receiving messages and the disk usage is immediately reduced.


Option 2: Empty the Queue (1Gateway UI)

  1. Open the 1Gateway UI
  2. Navigate to the affected plugin
  3. Click Empty Queue

This will remove all pending messages while keeping the queue structure intact.

info

If the queue keeps consuming messages, it will fill up again. Make sure to use this option only if the queue doesn't receive any more messages.

Important Behavior

  • When the plugin is activated again, the queue will be automatically recreated

  • No manual setup is required after deletion

Best Practices

  • Regularly monitor queues with no consumers

  • Clean up queues for inactive plugins

  • Use alerts for:

    • High queue size
    • Queues with zero consumers

If a plugin is inactive:

Its queue continues to receive messages but nothing consumes them.

Always empty or delete unused queues to prevent disk issues.