Skip to content

Commit

Permalink
fix: don't retry non-idempotent functions (#1517)
Browse files Browse the repository at this point in the history
* fix: don't retry non-idempotent functions

* 🦉 Updates from OwlBot

See https://github.com/googleapis/repo-automation-bots/blob/master/packages/owl-bot/README.md

* added comment

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
  • Loading branch information
shaffeeullah and gcf-owl-bot[bot] authored Aug 2, 2021
1 parent 4432072 commit c938795
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/bucket.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1710,6 +1710,7 @@ class Bucket extends ServiceObject {
uri: '/notificationConfigs',
json: snakeize(body),
qs: query,
maxRetries: 0, //explicitly set this value since this is a non-idempotent function
},
(err, apiResponse) => {
if (err) {
Expand Down
1 change: 1 addition & 0 deletions src/storage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -950,6 +950,7 @@ export class Storage extends Service {
method: 'POST',
uri: `/projects/${projectId}/hmacKeys`,
qs: query,
maxRetries: 0, //explicitly set this value since this is a non-idempotent function
},
(err, resp: HmacKeyResourceResponse) => {
if (err) {
Expand Down

0 comments on commit c938795

Please sign in to comment.