Skip to content

chore(spanner): add sample codes and sample ITs for Cloud Spanner Queues. - #14203

Open
finnzzf wants to merge 8 commits into
googleapis:mainfrom
finnzzf:main
Open

chore(spanner): add sample codes and sample ITs for Cloud Spanner Queues.#14203
finnzzf wants to merge 8 commits into
googleapis:mainfrom
finnzzf:main

Conversation

@finnzzf

@finnzzf finnzzf commented Aug 27, 2026

Copy link
Copy Markdown
Contributor

Adding sample codes and tests for queues.

@finnzzf
finnzzf requested review from a team as code owners August 27, 2026 19:52

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a new QueueSample class and its corresponding integration test QueueSampleIT to demonstrate Spanner queue operations, including database creation, sending, receiving, acknowledging, and deleting messages using both Mutation and SQL APIs. The review feedback suggests improving exception handling in the sample code by propagating exceptions in createQueueDatabase instead of catching and swallowing them, which simplifies the code and ensures failures are properly propagated.

Comment thread java-spanner/samples/snippets/src/main/java/com/example/spanner/QueueSample.java Outdated
@sakthivelmanii sakthivelmanii added the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Sep 1, 2026
@yoshi-kokoro yoshi-kokoro removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Sep 1, 2026
@rahul2393

Copy link
Copy Markdown
Contributor

We don't have any sample tags here?

@rahul2393 rahul2393 changed the title feat(spanner): add sample codes and sample ITs for Cloud Spanner Queues. chore(spanner): add sample codes and sample ITs for Cloud Spanner Queues. Sep 4, 2026
@snippet-bot

snippet-bot Bot commented Sep 4, 2026

Copy link
Copy Markdown

Here is the summary of changes.

You are about to add 9 region tags.

This comment is generated by snippet-bot.
If you find problems with this result, please file an issue at:
https://github.com/googleapis/repo-automation-bots/issues.
To update this comment, add snippet-bot:force-run label or use the checkbox below:

  • Refresh this comment

@rahul2393

Copy link
Copy Markdown
Contributor

Ok when we add tag we make sure that tags are common across all languages so that in future if we write a cloud doc and try to link sample they all can get linked

I see in python we have sparate sets of tags then here https://github.com/finnzzf/google-cloud-python/blob/main/packages/google-cloud-spanner/samples/samples/queue_snippets.py, do we have agreement on how we will be showcasing this?

Comment thread java-spanner/samples/snippets/src/main/java/com/example/spanner/QueueSample.java Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants