Massive amount of queued messages

Hi there,

we are using the Cloud starter edition of HiveMQ. We have around 30 clients connected and according to my own measurement, we are posting somewhat 100 messages per minute. However the dashboard shows hundreds of millions of queued messages which does not make any sense. How is this possible?

Best, Manuel

Hello @Manuel

Welcome to the HiveMQ Community Forum! We are delighted to see your interest in MQTT and HiveMQ Cloud.

To assist you with the behavior you’ve observed, we kindly ask for the following information:

  • Cluster URL: Please share the URL of your cluster.
  • Client Details: Are your clients using MQTT 3 or 5? Which client library are you using?
  • Subscriber Information: Can you confirm the number of subscribers you have?
  • Subscriber Status: Are these subscribers online or offline? You can find this information in the Control Center under Client List/Client Details Overview.
  • Integrations: Do you use any integrations, such as Kafka or Confluent?
  • Screenshots: Could you please share a screenshot from Control center Dashboard

Providing this information will help us investigate further and help you with a more accurate solution. Thank you for your cooperation!

Sheetal from HiveMQ Team

Sure, thank you.

  • Clients using MQTT3, we’re using the eclipse paho client for Java components and the node MQTT lib for node services
  • There are around 30-40 online subscribers and close to 10k offline subscriber’s who’s connection was dropped
  • No integrations
  • Please let me know where to send the screenshots and the cluser URL, we don’t want to share this information publicly on this forum

Hello Manuel,

Thank you for your response and for sharing the details. As you mentioned, you have around 10,000 offline subscribers. If these subscribers are initially connected with persistent sessions, the HiveMQ broker will queue messages while these clients are offline or disconnected. This could explain why you see a large number of queued messages, which is the expected behavior of HiveMQ broker.

To learn more about persistent sessions and queued messages, we suggest reading our blog post: MQTT Essentials Part 7 - Persistent Session and Queuing Messages.

Additionally, if you have further questions, please feel free to reach out to us using the support widget on the HiveMQ Cloud console. You can also upload files there for more detailed assistance.

Kind regards,
Sheetal from HiveMQ Team

That was a great hint, thank you. It was indeed related to persistant connections, changed it in code and all good now.