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 Leaks with Ninject and Rebus #39

Open
colin-higgins opened this issue Jun 27, 2017 · 0 comments
Open

Memory Leaks with Ninject and Rebus #39

colin-higgins opened this issue Jun 27, 2017 · 0 comments
Labels

Comments

@colin-higgins
Copy link
Owner

Rebus is async (task) based.
Relying on threads in task based code is bad, very bad.
Any task continuation can continue on a new thread. This can lead to nasty crazy side effects.
You can configure Ninject to manage your dependencies on a per thread basis. That means instance per thread.
If a thread is never let go in the expected sense, those dependencies might stick around.

Relevant links:
https://blogs.msdn.microsoft.com/davidklinems/2005/11/16/three-common-causes-of-memory-leaks-in-managed-applications/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant