Skip to content

Conversation

davissp14
Copy link
Contributor

@davissp14 davissp14 commented Jan 19, 2023

Deferrals are executed when the parent function returns. In our case, the parent function never returns and results in a connection leak. To mitigate this issue we can just wrap our ticker logic into a named function so the deferrals execute after each tick.

Screenshot 2023-01-19 at 10 54 19 AM

@davissp14 davissp14 requested a review from DAlperin January 19, 2023 16:02
Copy link
Contributor

@DAlperin DAlperin left a comment

Choose a reason for hiding this comment

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

Ah good catch

@davissp14 davissp14 merged commit 3d43c9b into master Jan 19, 2023
@davissp14 davissp14 deleted the fix-connection-leak-2 branch February 25, 2023 01:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants