nanomq
nanomq copied to clipboard
Cuncurrent subscribe request are lost
Describe the bug A clear and concise description of what the bug is. I use a script in JS based on mqttJS client already validated with other brokers. I noticed that if I send multiple parallel request of subscription from same client (using mqtt over websocket, I didn't tested mqtt raw), without waiting before the response, some of subscription request are lost. With other brokers that is managed correctly.
Expected behavior A clear and concise description of what you expected to happen. Broker able to manage multiple subscriptions requests in parallel.
Actual Behavior Describe what occurred. If I send multiple request in parallel, some are lost
To Reproduce If possible include actual reproduction test code here. Minimal C test cases are perferred.
- In js, with mqttjs, open a connection
- From client send multiple request in parallel without waiting response before, i.e.: client.subscribe(subscribetopic1, options) client.subscribe(subscribetopic2, options) client.subscribe(subscribetopic3, options) client.subscribe(subscribetopic3, options)
Environment Details
- NanoMQ version: docker: emqx/nanomq:0.21-full
- Operating system and version: win
- Compiler and language used: nodejs 20
- testing scenario: js client on host, broker in Docker
Client SDK If possible include the mqtt sdk you used to connect to nanomq Minimal C test cases are perferred. sdk: mqttjs code: see previous response
Additional context Add any other context about the problem here.