"Reached the maximum number of concurrent connections" issue with OPartitionedDatabasePool and its working behavior #10471
Unanswered
arpitdd123
asked this question in
General
Replies: 2 comments 1 reply
-
|
hi @arpitdd123 Could you please add the version of the OrientDB your are using for these tests. Check #10453 |
Beta Was this translation helpful? Give feedback.
1 reply
-
|
Hi, This case I think it is related to the use of the legacy |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
While performing some operations on the OrientDB, I faced issue for OrientDB connection.
In my code, I am getting ODatabaseDocument using OPartitionedDatabasePool and then at the end trying to close
ODatabaseDocument and OPartitionedDatabasePool. But it seems that connection are not getting closed.
So I tried same with below POC code.
Case 1: Connections are not getting closed
After executing the code, I observed that when calling
oDatabaseDocument.close();followed bypool.close();, no binary listeners were closed. I have verified this, through the OrientDB Studio Server Management UI. These connections are released only after code execution thread is terminated.As a result after creating many connections, OrientDB console logs the following message: "Reached the maximum number of concurrent connections (max=1000, current=1000), rejecting incoming connection from /127.0.0.1:54782 [OServerNetworkListener]".
Case 2: Connections are getting closed by reversing the API order
After reversing the order, first calling
pool.close(); and thenoDatabaseDocument.close(); the binary listener associated with oDatabaseDocument instance getting successfully closed.This behavior is observed on all the OrientDB versions.
Is closing the pool before closing the oDatabaseDocument instance the correct approach?
Beta Was this translation helpful? Give feedback.
All reactions