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
Let Result.getRowsUpdated() return Long
#255
Comments
|
This is also an issue for H2 because they now return a |
|
It's also an issue for Oracle R2DBC. We throw an ArithmeticException if an update count exceeds Integer.MAX_VALUE. Publishing Long, rather than Integer, seems like the right thing to do. This way, it will be consistent with Result.UpdateCount.value():
The only reason I can think of not to do this would be a significant performance benefit from using Integer instead of Long. If that can be demonstrated, then there might be case for SPI methods that expose int-valued updated counts. |
|
I'm wondering what's the best way to go about it without creating too much trouble. The SPI could specify Switching with 1.0 directly from Likely, regardless of what we do, either drivers or clients will break. |
Result.getRowsUpdated() return Long
Currently,
Result.getRowsUpdated()returns aPublisher<Integer>.Cloud Spanner naturally returns
Long(internally known as INT64) values, and the Cloud Spanner R2DBC driver works around the mismatch by converting too-large numbers with a warning and loss of original value.Ideally, we would be able to pass the original value through to the end user. This would require the result specification to change from
Publisher<Integer> getRowsUpdated()toPublisher<Long> getRowsUpdated().This may also help future-proof the spec as datasets grow ever-larger.
The text was updated successfully, but these errors were encountered: