Skip to content
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

Find and close all SpannerClientLibraryConnectionFactory on Spring Data context shutdown #380

Open
elefeint opened this issue May 27, 2021 · 0 comments
Labels
enhancement New feature or request P2 V2

Comments

@elefeint
Copy link
Contributor

elefeint commented May 27, 2021

  1. Pending outcome of R2DBC ConnectionFactory bean .close() method should be called/subscribed when available spring-projects/spring-framework#26991, add a listener for ContextClosedEvent to find SpannerClientLibraryConnectionFactory beans and call Closeable.close().subscribe(). Might have to even block to avoid race conditions ("app shut down before sessions are released")

  2. Add stronger documentation warnings about having to close custom created Spanner connection factories on context shutdown (to avoid server-side session leaks, as the client library pre-allocates ~200 sessions).

@elefeint elefeint added the V2 label May 27, 2021
@elefeint elefeint added the P2 label May 12, 2022
@elefeint elefeint added this to the h2-2022-candidates milestone May 12, 2022
@elefeint elefeint added the enhancement New feature or request label Aug 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request P2 V2
Projects
None yet
Development

No branches or pull requests

1 participant