-
-
Notifications
You must be signed in to change notification settings - Fork 35
Description
Hi, I've been trying to use emitter for 4 months now, but am constantly plagued with reconnection issues. Basically, whenever there is a network interruption, the Go client seems to notice the problem, but it fails to reconnect and doesn't panic, which leaves the client in a disconnected state.
This is happening in both the v1 and v2 code, and with both standalone emitter servers as well as clustered servers. The problem is much more common when running the emitter behind an AWS Application Load Balancer with a client TTL above 30 seconds (I suspect the AWS ALB is killing the connection more frequently in this case).
I previously found some issues in the dependency, paho.mqtt.golang, that related to autoreconnection, and so I implemented a OnConnectionLost() handler that tries to reconnect, but it also doesn't seem to help. It seems the only way to reliably reconnect is to panic the whole thing and let my process supervisor restart my application.
Is anyone else experiencing this problem, and/or is there something I can do to gather conclusive information about the problem?
I've tried the stable version, and also the latest master via my application's Gopkg.toml:
[[constraint]]
branch = "master"
# version = "2.0.4"
name = "github.com/emitter-io/go"
[[override]]
branch = "master"
# version = "c606a4c5dacdea0598aed291be3120479c509e43"
name = "github.com/eclipse/paho.mqtt.golang"
Thanks!