redpanda-data / redpanda-data/connect
MQTT input seemed not stable with high input load.
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 8.8k
- Forks
- 969
- Avg merge
- 1d 13h
- Merged PRs (30d)
- 64
Description
Dear Support,
I'm caught by a connection interruption issue during testing on mqtt input to the benthos.
To start with the test, I was using a small pieces of code as a MQTT client and publish messages to MQTT server (running in docker) every 5 second, then I can see the message though to the benthos output, where it connected to a Kafka instance. No error from Benthos side, and all messages seemed to landed to the output side.
Then I tried to increase the pushing interval of the MQTT client to one message per 20 ms, then I can see from the output side that seemed messages flow was interrupted, and then checking the log from Benthos container, I can see two lines of error messages also indicated that the connection was interrupted:
level=error msg="Connection lost for unknown reasons." @service=benthos label="" path=root.input.broker.inputs.1
level=error msg="Connection lost due to: pingresp not received, disconnecting" @service=benthos label="" path=root.input.broker.inputs.1
The connection seemed auto reestablished right after.
I know this error was popped from the underline lib used by Benthos, just wondering if there are some thing we could do from Benthos configuration side pls?
thanks!
Environment: Docker image with latest tag pull on 11th Oct, 2023.
MQTT server: EMQT
MQTT Client: with two senarios:
- send a test message every 5 second, with 10 instances
- send test message every 200 ms with one instance.
Both case will trigger the error.
Benthos: Config file:
input:
broker:
inputs:
- mqtt:
urls:
- mqtt://xxxxx:1883
client_id: bentho_client1
user: xxxx
password: xxxxx
topics:
- testtopic
connect_timeout: 30s
keepalive: 60
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the supplied MQTT input configuration and the two connection-loss log messages, then reproduce the interruption under the reported message rates. Compare the slow and high-load cases and determine whether Benthos configuration affects the disconnect; done means a validated configuration remedy or a documented limitation.
Written by the indexing model from the issue text.
Assessment
- Domain
- stream-processing
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100