[
https://issues.apache.org/jira/browse/TINKERPOP-2288?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17084991#comment-17084991
]
ASF GitHub Bot commented on TINKERPOP-2288:
-------------------------------------------
FlorianHockmann commented on pull request #1279: TINKERPOP-2288 Replace closed
connections directly
URL: https://github.com/apache/tinkerpop/pull/1279
https://issues.apache.org/jira/browse/TINKERPOP-2288
This is still WIP but I think that a PR makes sense to be able to discuss
the concrete implementation. There were already some comments on the earlier
commit which are now unfortunately lost as I force pushed on that branch after
rebasing on `3.4-dev` again.
Closed connections are now replaced automatically in the background.
If no open connection is available to answer a request, then the pool
tries it again after some time. It uses a retry policy with exponential
backoff for that, implemented with Polly.
This change also ensures that only one task performs a pool resizing
operation at a time.
These changes should ensure that:
- A connection is still returned quickly if one is available.
- Closed connections are replaced immediately, without needing to wait
for the next incoming request.
- If the server is only unavailable temporarily (or it just closed
open connections for some reason), then the user should should not get
an exception.
He only has to wait until the connections are replaced.
TODO:
- [ ] Make the retry policy configurable
- [ ] Document changes
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
> Get ConnectionPoolBusyException and then ServerUnavailableExceptions
> --------------------------------------------------------------------
>
> Key: TINKERPOP-2288
> URL: https://issues.apache.org/jira/browse/TINKERPOP-2288
> Project: TinkerPop
> Issue Type: Bug
> Components: dotnet
> Affects Versions: 3.4.1
> Environment: Gremlin.Net 3.4.1
> Microsoft.NetCore.App 2.2
> Azure Cosmos DB
> Reporter: patrice huot
> Priority: Critical
> Attachments: Gremlin.Net.3.4.7-SNAPSHOT.nupkg
>
>
> I am using .Net core Gremlin API query Cosmos DB.
> From time to time we are getting an error saying that no connection is
> available and then the server become unavailable. When this is occurring we
> need to restart the server. It looks like the connections are not released
> properly and become unavailable forever.
> We have configured the pool size to 50 and the MaxInProcessPerConnection to
> 32 (Which I guess should be sufficient).
> To diagnose the issue, Is there a way to access diagnostic information on the
> connection pool in order to know how many connections are open and how many
> processes are running in each connection?
> I would like to be able to monitor the connections usage to see if they are
> about to be exhausted and to see if the number of used connections is always
> increasing or of the connection lease is release when the queries completes?
> As a work around, Is there a way we can access this information from the code
> so that I can catch those scenario and create logic that re-initiate the
> connection pool?
>
>
--
This message was sent by Atlassian Jira
(v8.3.4#803005)