-
Notifications
You must be signed in to change notification settings - Fork 5
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
[Question] Full and Correct Support for Connection Pooling? #2
Comments
Hi @mdgozza thanks for your query. As we are learning(this project is inspired by r2d2 pooling itself) and implementing, we are still in process of implementing certain things like the above connection pooling thing. We will try to create full support for connection pooling. Hope it clarifies. |
Awesome @AWADHAMBIKA thanks so much for the explanation! I am going to try to build an http server that processes db2 queries in rust and pools connections using this connection manager, but I am worried that without an is_valid implementation pool connections will be created and left open even if they are no longer valid. ( likewise for has_broken ) I will do some research into how it may be possible to detect if a connection is valid or has broken and maybe provide those implementations so that I can use connection pooling and feel confident that a connection I get from the pool will be both valid and not broken. |
A quick glance at the postgres implementation shows maybe it's not so bad! 🎉 https://github.com/sfackler/r2d2-postgres/blob/master/src/lib.rs#L70-L76 |
Hi @mdgozza not sure if you were able to implement the is_valid.
|
Hey @AWADHAMBIKA, I'm not positive about this, but it should be confirmed. I feel like prepare might leave some stuff hanging around where a full query might be more clean on both sides. |
Hi!
Thanks so much for supporting rust.
When reviewing the r2d2 pooling implementation I noticed that this library doesn't yet seem to properly take care of broken and invalid connections in the r2d2 pool. Is there any timeline for when this might become officially complete?
rust-ibm_db/src/lib.rs
Lines 138 to 146 in 1fd871d
Also: I noticed the work on this library is quite new. What kind of levels of support is IBM currently looking at providing for this module?
Again, thanks so much for supporting rust!!
The text was updated successfully, but these errors were encountered: