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

Implement timeout variants #22

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

parsonsmatt
Copy link

Based on #21

Fixes #10

@goosedb
Copy link

goosedb commented Jan 12, 2023

@parsonsmatt
I think implementing timeouts this way is not very good idea. There are many libraries use pool, so there are many cases you create pool used by external library. But a library author don't (and, maybe, shouldn't?) think whether to use with timeout version or basic one. So I think you should be able to inject timeout inside of pool.

Update: Because of reasons I've written above my issue #10 is not solved by this PR (because I don't have access to code which takes resource.) And also your PR can be implemented in beyond of the library. It's just a sugar for existing interface. So in my PR #11 I added new feature allows to inject timeout, which can't be implemented beyond.

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.

Can we add timeout for resource acquiring?
2 participants