Skip to content

Conversation

@plamut
Copy link
Contributor

@plamut plamut commented Sep 30, 2019

Closes #9339
Re-introduces #9252.

This PR fixes a regression from the 1.0.1 release that caused the streaming pull to additionally require the subscriptions.get permission (the default pubsub.subscriber role was not sufficient anymore for the streaming pull).

By avoiding the call that fetched a subscription and read its ACK deadline, and replacing that deadline with a fixed value of 60 seconds, this will re-introduce #9252, albeit in a less severe manner.

How to test

Using an account that has no roles assigned other than roles/pubsub.subscriber, try opening a streaming pull (subscriber.subscribe()). That call should succeed without a permission error.

@plamut plamut added the api: pubsub Issues related to the Pub/Sub API. label Sep 30, 2019
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Sep 30, 2019
@plamut plamut requested a review from pradn September 30, 2019 17:27
Pulling the mesages with the streaming pull should work with the
default pubsub.subscriber role.

This commit removes the call to fetch a subscription, and replaces the
subscription's ACK deadline with a fixed deadline of 60 seconds.

That *will* re-introduce the issue googleapis#9252, but at least in a less severe
manner.
@plamut plamut merged commit 7cd36a5 into googleapis:master Sep 30, 2019
@plamut plamut deleted the iss-9339 branch September 30, 2019 18:19
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 Pub/Sub API. cla: yes This human has signed the Contributor License Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

PubSub: Subscribing to a Pub/Sub topic requires additional permissions as a result of the release of google-cloud-pubsub 1.0.1

3 participants