Closed huineng closed 2 years ago
@huineng The SQL30081N error after some time of inactivity tells that the existing connection is closed by server and these connections are no longer valid. Yes, the shared code will clean all connections from pool and on next request for pool.open() will go for new connection. Only thing is after getting SQL30081N error, application should retry the same operation which returned SQL30081N and next action would complete without error. Basically, SQL30081N error tells that connection is invalid and need to retry the operation. Retry should work and error should disappear. Hope it explains. Thanks.
yes, this is what i thought , and i will look for an implementation for this
thanks
we have an openshift app having 3 replicas , we are using the latest ibm_db package we are using pool and initializing it with
The application works as designed, but occasionally, after some time of inactivity (no user running reports) we do get (ibm db2 warehouse on cloud)
question, are the above the best settings for a pool. I assume active connections are being kept in the pool but then when used , are no longer active. (stale ?)
what kind of code should i apply , should i ignore these errors ?
i see the following in the code
does this mean the library will try another connection ? and in fact no real error is returned to the user ?
some guidance would be appreciated
thanks