spanner: add (Batch)?Update(WithOptions)? to Client #9583
Labels
api: spanner
Issues related to the Spanner API.
needs more info
This issue needs more information from the customer to proceed.
type: feature request
‘Nice-to-have’ improvement, new feature or different behavior or design.
Is your feature request related to a problem? Please describe.
If a ReadWriteTransaction needs to perform only a batch of one or more update operations, it is wasteful and unneccessary to keep the transaction open for an extra roundtrip.
Describe the solution you'd like
Add the following methods to spanner.Client:
that would behave as a ReadWriteTransaction containing a single call to corresponding method above, so e.g.
would behave as
but allowing Spanner to close the transaction as soon as the update completes, without waiting for the client to explicitly commit.
Describe alternatives you've considered
The equivalent code above works today, but is less efficient.
The text was updated successfully, but these errors were encountered: