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

docs(pubsub): The immediate: false option is recommended to avoid adverse impacts on the performance of pull operations #11153

Merged
merged 1 commit into from
Apr 15, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions google-cloud-pubsub/OVERVIEW.md
Original file line number Diff line number Diff line change
Expand Up @@ -205,8 +205,8 @@ sleep
Messages also can be pulled directly in a one-time operation. (See
{Google::Cloud::PubSub::Subscription#pull Subscription#pull})

The `immediate: false` option is now recommended to avoid adverse impacts on
pull operations.
The `immediate: false` option is recommended to avoid adverse impacts on the
performance of pull operations.

```ruby
require "google/cloud/pubsub"
Expand Down
9 changes: 5 additions & 4 deletions google-cloud-pubsub/lib/google/cloud/pubsub/subscription.rb
Original file line number Diff line number Diff line change
Expand Up @@ -734,10 +734,11 @@ def detach

##
# Pulls messages from the server, blocking until messages are available
# when called with the `immediate: false` option, which is now recommended
# to avoid adverse impacts on pull operations. Raises an API error with
# status `UNAVAILABLE` if there are too many concurrent pull requests
# pending for the given subscription.
# when called with the `immediate: false` option, which is recommended
# to avoid adverse impacts on the performance of pull operations.
#
# Raises an API error with status `UNAVAILABLE` if there are too many
# concurrent pull requests pending for the given subscription.
#
# See also {#listen} for the preferred way to process messages as they
# become available.
Expand Down