fhmq / hmq

High performance mqtt broker
Apache License 2.0
1.32k stars 273 forks source link

v1.5.0 read packet error,i/o timeout #174

Open wecane opened 2 years ago

wecane commented 2 years ago

With the previous version, the test was fine. When testing with v1.5.0, when the number of devices increases, there will be a lot of i/o timeouts.

` {"level":"error","timestamp":"2022-08-29T07:27:29.695+0800","logger":"broker","caller":"broker/client.go:174","msg":"read packet error: ","error":"read tcp 10.0.8.11:1883->124.229.23.224:10292: i/o timeout","ClientID":"mqttx_fbdd0f3f76"} {"level":"error","timestamp":"2022-08-29T07:27:29.778+0800","logger":"broker","caller":"broker/client.go:174","msg":"read packet error: ","error":"EOF","ClientID":"mqttx_fbdd0f3f675"} {"level":"error","timestamp":"2022-08-29T07:27:31.456+0800","logger":"broker","caller":"broker/client.go:174","msg":"read packet error: ","error":"EOF","ClientID":"mqttx_fbdd0f3f66"} {"level":"error","timestamp":"2022-08-29T07:27:32.790+0800","logger":"broker","caller":"broker/client.go:174","msg":"read packet error: ","error":"read tcp 10.0.8.11:1883->224.178.126.96:30969: i/o timeout","ClientID":"mqttx_fbdd0f3f66"} {"level":"error","timestamp":"2022-08-29T07:27:38.398+0800","logger":"broker","caller":"broker/client.go:174","msg":"read packet error: ","error":"EOF","ClientID":"mqttx_fbdd0f3f66"} {"level":"error","timestamp":"2022-08-29T07:27:39.033+0800","logger":"broker","caller":"broker/client.go:174","msg":"read packet error: ","error":"read tcp 10.0.8.11:1883->214.97.32.56:12003: i/o timeout","ClientID":"mqttx_fbdd0f3f74"} {"level":"error","timestamp":"2022-08-29T07:27:39.484+0800","logger":"broker","caller":"broker/client.go:174","msg":"read packet error: ","error":"EOF","ClientID":"mqttx_fbdd0f3f73"} {"level":"error","timestamp":"2022-08-29T07:27:43.033+0800","logger":"broker","caller":"broker/client.go:174","msg":"read packet error: ","error":"EOF","ClientID":"mqttx_fbdd0f3f66"}

`

wecane commented 2 years ago

After connecting to the server, cannot subscribe, publish

wind-c commented 2 years ago

https://github.com/wind-c/comqtt  support the distributed cluster and mqtt v5.0,you can look at it.