Skip to content

Conversation

@ShuranZhang
Copy link
Contributor

@ShuranZhang ShuranZhang commented Apr 15, 2024

Add support for excluding transactions from being recorded in the change streams by passing a new boolean option ExcludeTxnFromChangeStreams in the various write APIs:

  • Apply
  • ApplyAtLeastOnce
  • ReadWriteTransactionWithOptions
  • BtachWriteWithOptions
  • PartitionedUpdateWithOptions

This pr follows the exact same design with the merged Java client lib pr for this feature at googleapis/java-spanner#2959 including error handling.
Passing this option to a request level DML request will receive an error errExcludeRequestLevelDmlFromChangeStreams. This new option is added to struct QueryOptions, but it can only be used for PartitionedUpdate API.

Note: Samples will be added later in separate prs.

@ShuranZhang ShuranZhang requested review from a team as code owners April 15, 2024 21:30
@product-auto-label product-auto-label bot added the api: spanner Issues related to the Spanner API. label Apr 15, 2024
@ShuranZhang ShuranZhang force-pushed the spanner-cdc-txn-exclusion branch from 79a3207 to abbc23a Compare April 15, 2024 21:36
@ShuranZhang ShuranZhang force-pushed the spanner-cdc-txn-exclusion branch from abbc23a to 26ba6b0 Compare April 16, 2024 22:01
@ShuranZhang ShuranZhang requested a review from dedocibula April 16, 2024 22:02
@ShuranZhang ShuranZhang force-pushed the spanner-cdc-txn-exclusion branch from 26ba6b0 to f0f2dc4 Compare April 19, 2024 17:11
@rahul2393 rahul2393 added the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Apr 22, 2024
@rahul2393 rahul2393 enabled auto-merge (squash) April 22, 2024 06:13
@kokoro-team kokoro-team removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Apr 22, 2024
@rahul2393 rahul2393 changed the title feat(spanner):add support for change streams transaction exclusion option feat(spanner): add support for change streams transaction exclusion option Apr 22, 2024
@rahul2393 rahul2393 added the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Apr 22, 2024
@kokoro-team kokoro-team removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Apr 22, 2024
@rahul2393 rahul2393 merged commit 979ce94 into googleapis:main Apr 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api: spanner Issues related to the Spanner API.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants