Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TCP/WebSocket: Fix memory leak of canceled state and canceled futures #270

Closed
lexnv opened this issue Oct 22, 2024 · 1 comment · Fixed by #272
Closed

TCP/WebSocket: Fix memory leak of canceled state and canceled futures #270

lexnv opened this issue Oct 22, 2024 · 1 comment · Fixed by #272
Labels
bug Something isn't working

Comments

@lexnv
Copy link
Collaborator

lexnv commented Oct 22, 2024

Similar to #269, the state tracking around canceling dials is monotonically increasing:

  • cancel dials leak a connection ID possibly every connection
  • cancel dials leak an AbortableHandler possibly every connection

The AbortableHandler logic was introduced on top of the cancellation by connection ID, therefore I expect the fix to be similar for both cases.

TCP

Screenshot 2024-10-22 at 12 43 50
Screenshot 2024-10-22 at 12 41 49

WebSocket

Screenshot 2024-10-22 at 14 03 38
Screenshot 2024-10-22 at 14 02 45

cc @paritytech/networking

@lexnv
Copy link
Collaborator Author

lexnv commented Oct 22, 2024

The cancel by abort handler is not yet merged, therefore the leak might come entirely from the "cancel by connection ID"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant