-
Notifications
You must be signed in to change notification settings - Fork 207
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: sample for receiving messages with exactly-once delivery enabled #588
Conversation
Here is the summary of changes. You are about to add 1 region tag.
This comment is generated by snippet-bot.
|
samples/snippets/subscriber.py
Outdated
project_id: str, subscription_id: str, timeout: Optional[float] = None | ||
) -> None: | ||
"""Receives messages from a pull subscription with exactly-once delivery enabled.""" | ||
# [START pubsub_subscriber_pull_with_exactly_once_delivery_enabled] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please change this to pubsub_subscriber_exactly_once
(as described in b/221257565)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pubsub_subscriber_exactly_once_delivery please.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- You need to add a sample test.
- You need to update how one is to call this method in
python-pubsub/samples/snippets/subscriber.py
Line 825 in 8ffe648
if __name__ == "__main__": # noqa
8ffe648
to
2ab6383
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! LGTM.
[![WhiteSource Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [google-cloud-bigquery](https://togithub.com/googleapis/python-bigquery) | `==2.32.0` -> `==2.34.2` | [![age](https://badges.renovateapi.com/packages/pypi/google-cloud-bigquery/2.34.2/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/pypi/google-cloud-bigquery/2.34.2/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/pypi/google-cloud-bigquery/2.34.2/compatibility-slim/2.32.0)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/pypi/google-cloud-bigquery/2.34.2/confidence-slim/2.32.0)](https://docs.renovatebot.com/merge-confidence/) | | [google-cloud-pubsub](https://togithub.com/googleapis/python-pubsub) | `==2.9.0` -> `==2.10.0` | [![age](https://badges.renovateapi.com/packages/pypi/google-cloud-pubsub/2.10.0/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/pypi/google-cloud-pubsub/2.10.0/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/pypi/google-cloud-pubsub/2.10.0/compatibility-slim/2.9.0)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/pypi/google-cloud-pubsub/2.10.0/confidence-slim/2.9.0)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>googleapis/python-bigquery</summary> ### [`v2.34.2`](https://togithub.com/googleapis/python-bigquery/blob/HEAD/CHANGELOG.md#​2342-httpsgithubcomgoogleapispython-bigquerycomparev2341v2342-2022-03-05) [Compare Source](https://togithub.com/googleapis/python-bigquery/compare/v2.34.1...v2.34.2) ### [`v2.34.1`](https://togithub.com/googleapis/python-bigquery/blob/HEAD/CHANGELOG.md#​2341-httpsgithubcomgoogleapispython-bigquerycomparev2340v2341-2022-03-02) [Compare Source](https://togithub.com/googleapis/python-bigquery/compare/v2.34.0...v2.34.1) ### [`v2.34.0`](https://togithub.com/googleapis/python-bigquery/blob/HEAD/CHANGELOG.md#​2340-httpsgithubcomgoogleapispython-bigquerycomparev2330v2340-2022-02-18) [Compare Source](https://togithub.com/googleapis/python-bigquery/compare/v2.33.0...v2.34.0) ##### Features - support BI Engine statistics in query job ([#​1144](https://togithub.com/googleapis/python-bigquery/issues/1144)) ([7482549](https://togithub.com/googleapis/python-bigquery/commit/7482549cb42ed5302634ab4fb7b4efcd97b35c68)) ### [`v2.33.0`](https://togithub.com/googleapis/python-bigquery/blob/HEAD/CHANGELOG.md#​2330-httpsgithubcomgoogleapispython-bigquerycomparev2320v2330-2022-02-16) [Compare Source](https://togithub.com/googleapis/python-bigquery/compare/v2.32.0...v2.33.0) ##### Features - add `--no_query_cache` option to `%%bigquery` magics to disable query cache ([#​1141](https://togithub.com/googleapis/python-bigquery/issues/1141)) ([7dd30af](https://togithub.com/googleapis/python-bigquery/commit/7dd30af41b8a595b96176c964ba14aa41645ef0d)) ##### Bug Fixes - return 403 when VPC-SC violation happens ([#​1131](https://togithub.com/googleapis/python-bigquery/issues/1131)) ([f5daa9b](https://togithub.com/googleapis/python-bigquery/commit/f5daa9b41377a58cb3220bb2ab7c72adc6462196)) ##### Documentation - reference BigQuery REST API defaults in `LoadJobConfig` descrip… ([#​1132](https://togithub.com/googleapis/python-bigquery/issues/1132)) ([18d9580](https://togithub.com/googleapis/python-bigquery/commit/18d958062721d6be81e7bd7a5bd66f277344a864)) - show common job properties in `get_job` and `cancel_job` samples ([#​1137](https://togithub.com/googleapis/python-bigquery/issues/1137)) ([8edc10d](https://togithub.com/googleapis/python-bigquery/commit/8edc10d019bd96defebc4f92a47774901e9b956f)) </details> <details> <summary>googleapis/python-pubsub</summary> ### [`v2.10.0`](https://togithub.com/googleapis/python-pubsub/blob/HEAD/CHANGELOG.md#​2100-httpsgithubcomgoogleapispython-pubsubcomparev290v2100-2022-03-04) [Compare Source](https://togithub.com/googleapis/python-pubsub/compare/v2.9.0...v2.10.0) ##### Features - add api key support ([#​571](https://togithub.com/googleapis/python-pubsub/issues/571)) ([cdda762](https://togithub.com/googleapis/python-pubsub/commit/cdda762f6d15d96f5e2d7fac975f3494dc49eaa9)) - add exactly once delivery flag ([#​577](https://togithub.com/googleapis/python-pubsub/issues/577)) ([d6614e2](https://togithub.com/googleapis/python-pubsub/commit/d6614e274328c58449e67dfc788e2e7986c0c10b)) - add support for exactly once delivery ([#​578](https://togithub.com/googleapis/python-pubsub/issues/578)) ([95a86fa](https://togithub.com/googleapis/python-pubsub/commit/95a86fa5f528701b760064f0cece0efa4e60cd44)) - exactly-once delivery support ([#​550](https://togithub.com/googleapis/python-pubsub/issues/550)) ([2fb6e15](https://togithub.com/googleapis/python-pubsub/commit/2fb6e1533192ae81dceee5c71283169a0a85a015)) ##### Bug Fixes - **deps:** move libcst to extras ([#​585](https://togithub.com/googleapis/python-pubsub/issues/585)) ([0846762](https://togithub.com/googleapis/python-pubsub/commit/084676243ca4afd54cda601e589b80883f9703a3)) - refactor client classes for safer type checking ([#​552](https://togithub.com/googleapis/python-pubsub/issues/552)) ([7f705be](https://togithub.com/googleapis/python-pubsub/commit/7f705beb927383f14b9d56f0341ee0de101f7c05)) - resolve DuplicateCredentialArgs error when using credentials_file ([8ca8cf2](https://togithub.com/googleapis/python-pubsub/commit/8ca8cf27333baf823a1dffd081e63079f1a12625)) ##### Samples - samples: create subscription with filtering enabled [#​580](https://togithub.com/googleapis/python-pubsub/pull/580) - samples: handle empty response in sync pull samples [#​586](https://togithub.com/googleapis/python-pubsub/pull/586) - samples: sample for receiving messages with exactly-once delivery enabled [#​588](https://togithub.com/googleapis/python-pubsub/pull/588) - samples: create subscription with exactly once delivery [#​592](https://togithub.com/googleapis/python-pubsub/pull/592) [https://github.com/googleapis/python-pubsub/pull/588](https://togithub.com/googleapis/python-pubsub/pull/588)/588 ##### Documentation - add autogenerated code snippets ([aa3754c](https://togithub.com/googleapis/python-pubsub/commit/aa3754cf432bd02be2734a23a32d5b36cd216aee)) - Docs have inconsistent default values for max_latency and max_bytes ([#​572](https://togithub.com/googleapis/python-pubsub/issues/572)) ([d136dfd](https://togithub.com/googleapis/python-pubsub/commit/d136dfdb69ebeebd1411a1415f863b94d07078f0)) </details> --- ### Configuration 📅 **Schedule**: At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](https://togithub.com/renovatebot/renovate/discussions) if that's undesired. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/python-logging).
Towards b/221257565