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

Please clarify and quantify statements regarding DbContext pooling #3369

Closed
joecjdi opened this issue Aug 5, 2021 · 2 comments · Fixed by #3460
Closed

Please clarify and quantify statements regarding DbContext pooling #3369

joecjdi opened this issue Aug 5, 2021 · 2 comments · Fixed by #3460
Assignees
Milestone

Comments

@joecjdi
Copy link

joecjdi commented Aug 5, 2021

[Enter feedback here]
Please further describe and quantify this statement:
"DbContext pooling can increase performance in high-throughput scenarios by re-using context instances. However, for most application this performance gain is very small."

What is meant by "most applications"? Are you referring to user-interactive applications? How small is "very small"? Clearly some research/benchmarking has been done to come to that conclusion. Can you share the results, even if it is a broad range?

I have a NON-user-interactive application that does a lot of background processing and, because of the vague documentation, I have no way of knowing if connection pooling would benefit me. I cannot easily benchmark my app because it has a constructor that takes more than 1 arg.


Document Details

Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

@ajcvickers
Copy link
Contributor

@joecjdi The only real way to know is to test your specific scenarios. That being said, we're putting this on the backlog to try to make the documentation a bit more helpful.

@ajcvickers ajcvickers added this to the Backlog milestone Aug 10, 2021
@roji roji changed the title Please clarify and quantify statements regarding pooling Please clarify and quantify statements regarding DbContext pooling Oct 3, 2021
@roji roji self-assigned this Oct 3, 2021
@roji roji modified the milestones: Backlog, 6.0.0 Oct 3, 2021
roji added a commit to roji/EntityFramework.Docs that referenced this issue Oct 3, 2021
@roji
Copy link
Member

roji commented Oct 3, 2021

Added some explanations and a simple benchmark in #3460.

@roji roji closed this as completed in #3460 Oct 4, 2021
roji added a commit that referenced this issue Oct 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants