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

samples: add samples for cloud storage buckets #1931

Merged
merged 12 commits into from
Jul 8, 2024

Conversation

feywind
Copy link
Collaborator

@feywind feywind commented Jun 6, 2024

Fixes: #1742

@feywind feywind requested review from a team as code owners June 6, 2024 20:41
Copy link

snippet-bot bot commented Jun 6, 2024

Here is the summary of changes.

You are about to add 2 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

@product-auto-label product-auto-label bot added the size: m Pull request size is medium. label Jun 6, 2024
@feywind feywind added do not merge Indicates a pull request not ready for merge, due to either quality or timing. and removed size: m Pull request size is medium. labels Jun 6, 2024
@product-auto-label product-auto-label bot added api: pubsub Issues related to the googleapis/nodejs-pubsub API. samples Issues that are directly related to samples. labels Jun 6, 2024
@product-auto-label product-auto-label bot added the size: m Pull request size is medium. label Jun 6, 2024
@feywind feywind removed the do not merge Indicates a pull request not ready for merge, due to either quality or timing. label Jun 11, 2024
@feywind
Copy link
Collaborator Author

feywind commented Jun 11, 2024

It's only one sample for now, this is good to go again.

@feywind feywind added the owlbot:run Add this label to trigger the Owlbot post processor. label Jun 11, 2024
@gcf-owl-bot gcf-owl-bot bot removed the owlbot:run Add this label to trigger the Owlbot post processor. label Jun 11, 2024
@product-auto-label product-auto-label bot added size: l Pull request size is large. and removed size: m Pull request size is medium. labels Jun 11, 2024
Copy link

Warning: This pull request is touching the following templated files:

@feywind feywind changed the title feat: add samples for cloud storage buckets, and getters for topic/sub admin clients samples: add samples for cloud storage buckets Jun 11, 2024
@feywind feywind added the owlbot:run Add this label to trigger the Owlbot post processor. label Jun 11, 2024
@gcf-owl-bot gcf-owl-bot bot removed the owlbot:run Add this label to trigger the Owlbot post processor. label Jun 11, 2024
Copy link

@lahuang4 lahuang4 left a comment

Choose a reason for hiding this comment

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

Looks good overall!

samples/README.md Outdated Show resolved Hide resolved
// Creates a client; cache this for further use
const pubSubClient = new PubSub();

async function createSubscriptionWithCloudStorage(

Choose a reason for hiding this comment

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

Maybe name this createCloudStorageSubscription instead of createSubscriptionWithCloudStorage? Same suggestion applies to the typescript sample.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I picked createSubscriptionWithCloudStorage because the library has five others with that naming scheme from earlier. Unless there's a strong objection, I think I'd probably keep the current name for that reason. Actually, the sample tags are all over the place already, so I don't think I'd want to try to fix it in this PR.

  • pubsub_create_cloud_storage_subscription (this one)
  • pubsub_dead_letter_create_subscription (createSubscriptionWithDeadLetterPolicy)
  • pubsub_create_subscription_with_exactly_once_delivery (createSubscriptionWithExactlyOnceDelivery)
  • pubsub_create_subscription_with_filter (createSubscriptionWithFiltering)
  • pubsub_enable_subscription_ordering (createSubscriptionWithOrdering)
  • createSubscriptionWithRetryPolicy - doesn't seem to have sample tags at all (??)

Maybe for the purposes of this PR, I'll just update the function name to match the tag and leave the filename as-is.

samples/createSubscriptionWithCloudStorage.js Outdated Show resolved Hide resolved
@feywind feywind added the owlbot:run Add this label to trigger the Owlbot post processor. label Jul 5, 2024
@gcf-owl-bot gcf-owl-bot bot removed the owlbot:run Add this label to trigger the Owlbot post processor. label Jul 5, 2024
@feywind feywind added the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Jul 8, 2024
@yoshi-kokoro yoshi-kokoro removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Jul 8, 2024
@feywind feywind added the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Jul 8, 2024
@yoshi-kokoro yoshi-kokoro removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Jul 8, 2024
@feywind feywind merged commit ac48418 into googleapis:main Jul 8, 2024
15 checks passed
@feywind feywind deleted the gh1742-cloud-storage-subs branch July 8, 2024 21:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: pubsub Issues related to the googleapis/nodejs-pubsub API. samples Issues that are directly related to samples. size: l Pull request size is large.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add samples for cloud storage connector
4 participants