knalli / homebridge-pilight

Accessory plugin for Homebridge allowing to manage and control pilight devices
MIT License
16 stars 3 forks source link

Adds a MessageQueue on SharedWebSocketConnections #42

Closed palmtrae closed 6 years ago

palmtrae commented 6 years ago

This fixes a problem that occurs if you try to switch many outlets too fast. The problem is really on Pilight, but it was easier and faster just to add a small delay between each send request.

knalli commented 6 years ago

Ok, thank you for adding this. Unfortunately, the tests are not running any more. I guess simply because of the unexpected delays.

palmtrae commented 6 years ago

Ah right, completely forgot about the tests sorry :) I'll look in to it. I'll also fix so that the timer doesn't run when it is not needed (e.g. empty queue).

knalli commented 6 years ago

Thank you also. Picked as fb7795a