quarkus-github-app icon indicating copy to clipboard operation
quarkus-github-app copied to clipboard

DynamicGraphQLClient never gets closed

Open yrodiere opened this issue 3 years ago • 0 comments

This code creates a client:

https://github.com/quarkiverse/quarkus-github-app/blob/7faa8a1b1d392d8a3a8d86278dae6999b534374c/deployment/src/main/java/io/quarkiverse/githubapp/deployment/GitHubAppProcessor.java#L457-L468

By calling this:

https://github.com/quarkiverse/quarkus-github-app/blob/978708a3828b8468d0d911186a3b14fecb7da295/runtime/src/main/java/io/quarkiverse/githubapp/runtime/github/GitHubService.java#L119-L140

https://github.com/quarkiverse/quarkus-github-app/blob/978708a3828b8468d0d911186a3b14fecb7da295/runtime/src/main/java/io/quarkiverse/githubapp/runtime/github/GitHubService.java#L157-L177

But as far as I can tell, there is absolutely no code to call the close() method on the created client.

Maybe we should just close it after all events have been processed? (careful though, it's reactive code so it's non-trivial to say when processing ends exactly...)

Maybe it should be cached like the non-graphQL client, and renewed every 10 minutes, and closed after 20 minutes?

yrodiere avatar Sep 15 '22 09:09 yrodiere