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

Memory leak on the context classes #308

Closed
lijunle opened this issue Sep 19, 2019 · 2 comments
Closed

Memory leak on the context classes #308

lijunle opened this issue Sep 19, 2019 · 2 comments
Assignees
Labels
bug Something's wrong.

Comments

@lijunle
Copy link

lijunle commented Sep 19, 2019

Describe the bug

After a long run on my service, the memory grows a lot. After analyze the memory dump, there are lots of context classes not released.

image

Desktop (please complete the following information):

  • OS: Windows
  • .Net Target; .Net Core 2.2
  • Version: v3.10.1

Additional context

This is a follow up on #306

I checked the code. It shows the BoardContext is never released. I took a quick look at the code. This line of code is strange. The Synchronized handler is never released.

https://github.com/gregsdennis/Manatee.Trello/blob/1b40470dfb1c9b6abe79b740a2a601cec37d885f/Manatee.Trello/Board.cs#L379

This seems a general issue on all context classes.

https://github.com/gregsdennis/Manatee.Trello/blob/ad33fa0a6bac4ad9fc629634ca39fdd3175bf3c7/Manatee.Trello/Card.cs#L429

@gregsdennis
Copy link
Collaborator

From #306 (comment)

It sounds should be a weak reference callback on the constructor.

I'll look into this idea.

@mrsalmon1976
Copy link

I'm experiencing this too. I have a Windows service running that updates board information, and after a day or so it starts suffering OutOfMemoryExceptions when calling Refresh on a board retrieved from the factory.

@gregsdennis gregsdennis self-assigned this Oct 30, 2019
@gregsdennis gregsdennis added the bug Something's wrong. label Oct 30, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something's wrong.
Projects
None yet
Development

No branches or pull requests

3 participants