Skip to content
This repository has been archived by the owner on Feb 15, 2019. It is now read-only.

Fix goroutine leak in websocket #53

Merged
merged 1 commit into from
Feb 7, 2018

Conversation

juliens
Copy link
Member

@juliens juliens commented Feb 7, 2018

Fix a leak in websocket

To explain:

We have two goroutines, one for the connection with the backend, and one for the connection with the client.

If an error occurs on one of the goroutines, we close both connection. By buffering the err channel, we can ignore the error on the goroutine which occurs because we close the connection intentionally.

Copy link
Member

@emilevauge emilevauge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link

@ldez ldez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link

@m3co-code m3co-code left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, I had the same fix in mind. I can verify tomorrow morning whether it fixes the problem in our setup, maybe a good idea before pushing to a bug fix release. WDYT? Is it planned that we do a 1.5.2 for this one?

@emilevauge
Copy link
Member

@marco-jantke good idea, we will push 1.5.2 next week so that's all good :)

@traefiker traefiker merged commit af37774 into containous:containous-fork Feb 7, 2018
@ldez ldez deleted the fix-leak branch February 7, 2018 17:35
@ldez ldez restored the fix-leak branch February 7, 2018 17:35
@ldez ldez deleted the fix-leak branch February 7, 2018 17:36
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants