-
Notifications
You must be signed in to change notification settings - Fork 451
Update discovery document and documentation for Requester Pays #694
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
Update discovery document and documentation for Requester Pays #694
Conversation
src/Storage/Bucket.php
Outdated
| public function createNotification($topic, array $options = []) | ||
| { | ||
| $res = $this->connection->insertNotification($options + [ | ||
| $res = $this->connection->insertNotification($options + array_filter([ |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
src/Storage/StorageClient.php
Outdated
| $bucket | ||
| ); | ||
| function (array $bucket) use ($requesterPays) { | ||
| return new Bucket($this->connection, $bucket['name'], $bucket, $requesterPays); |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
src/Storage/StorageClient.php
Outdated
| $name, | ||
| $response | ||
| $response, | ||
| $requesterPays |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
|
@dwsupplee updated. |
|
@frankyn, I updated the documentation in this pull request. PTAL |
frankyn
left a comment
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 @jdpedrie! PTAL.
| { | ||
| $this->connection | ||
| ->insertNotification([ | ||
| 'userProject' => null, |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
src/Storage/StorageClient.php
Outdated
| * be either 'full' or 'noAcl'. | ||
| * @type string $fields Selector which will cause the response to only | ||
| * return the specified fields. | ||
| * @type string $userProject The user project to be used for |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
|
@frankyn should be good now! |
frankyn
left a comment
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 @jdpedrie, apologies for the delay. I have added a few questions.
| * | ||
| * @param string $name The name of the bucket to request. | ||
| * @param string|bool $requesterPays If true, the current Project ID | ||
| * @param string|bool $userProject If true, the current Project ID |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
| { | ||
| $this->connection | ||
| ->insertNotification([ | ||
| 'userProject' => null, |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
| // to short circuit all the response handling and get back to the assertion with the query string. | ||
| throw new \Exception($request->getUri()->getQuery()); | ||
| } | ||
| } No newline at end of file |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
| @@ -0,0 +1,430 @@ | |||
| <?php | |||
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
frankyn
left a comment
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.
LGTM! Thanks @jdpedrie!
Most of the remaining Requester Pays methods were implemented with a discovery document update. Additional documentation has been added where appropriate, and a unit test class has been added to demonstrate that the
userProjectquery parameter is added where appropriate.Closes #699, #696.