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

feat!: add closeAsync() method to Connection #984

Merged
merged 2 commits into from Mar 18, 2021
Merged

Conversation

olavloite
Copy link
Contributor

@olavloite olavloite commented Mar 17, 2021

Adds a non-blocking close method to Connection to support APIs that should offer only non-blocking methods to consumers (e.g. R2DBC).

The Connection interface is marked with InternalApi and documented with Internal connection API for Google Cloud Spanner. This interface may introduce breaking changes without prior notice.

cc @elefeint

@olavloite olavloite requested a review from thiagotnunes Mar 17, 2021
@olavloite olavloite requested review from as code owners Mar 17, 2021
@product-auto-label product-auto-label bot added the api: spanner label Mar 17, 2021
@google-cla google-cla bot added the cla: yes label Mar 17, 2021
@codecov
Copy link

@codecov codecov bot commented Mar 17, 2021

Codecov Report

Merging #984 (dcbf73b) into master (7af1951) will decrease coverage by 0.01%.
The diff coverage is 95.23%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master     #984      +/-   ##
============================================
- Coverage     85.11%   85.09%   -0.02%     
+ Complexity     2618     2617       -1     
============================================
  Files           154      154              
  Lines         14310    14319       +9     
  Branches       1331     1331              
============================================
+ Hits          12180    12185       +5     
- Misses         1564     1570       +6     
+ Partials        566      564       -2     
Impacted Files Coverage Δ Complexity Δ
...om/google/cloud/spanner/connection/Connection.java 100.00% <ø> (ø) 0.00 <0.00> (ø)
...oogle/cloud/spanner/connection/ConnectionImpl.java 84.13% <95.23%> (+0.08%) 181.00 <1.00> (+1.00)
...le/cloud/spanner/connection/StatementExecutor.java 76.92% <0.00%> (-3.85%) 8.00% <0.00%> (-1.00%)
...ain/java/com/google/cloud/spanner/SessionPool.java 89.12% <0.00%> (-0.20%) 72.00% <0.00%> (-1.00%)
...a/com/google/cloud/spanner/SessionPoolOptions.java 69.53% <0.00%> (ø) 17.00% <0.00%> (-1.00%)
.../google/cloud/spanner/AbstractLazyInitializer.java 100.00% <0.00%> (+7.14%) 5.00% <0.00%> (+1.00%)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 7af1951...dcbf73b. Read the comment docs.

Copy link
Contributor

@elefeint elefeint left a comment

Thank you!

@thiagotnunes thiagotnunes changed the title feat: add closeAsync() method to Connection feat!: add closeAsync() method to Connection Mar 18, 2021
@thiagotnunes thiagotnunes merged commit e7ec96e into master Mar 18, 2021
17 of 18 checks passed
@thiagotnunes thiagotnunes deleted the connection-close-async branch Mar 18, 2021
@release-please release-please bot mentioned this pull request Mar 18, 2021
thiagotnunes added a commit that referenced this issue Mar 19, 2021
Co-authored-by: Thiago Nunes <thiagotnunes@google.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: spanner cla: yes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants