Skip to content
Permalink
Browse files
feat: add RPC retry information for MacSign, MacVerify, and GenerateR…
…andomBytes (#636)

* feat: add RPC retry information for MacSign, MacVerify, and GenerateRandomBytes Committer: @bdhess

PiperOrigin-RevId: 399925901

Source-Link: googleapis/googleapis@ae7e399

Source-Link: https://github.com/googleapis/googleapis-gen/commit/3a8128528ceddba0c1775401eef57ecb582db350
Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiM2E4MTI4NTI4Y2VkZGJhMGMxNzc1NDAxZWVmNTdlY2I1ODJkYjM1MCJ9

* 🦉 Updates from OwlBot

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

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
  • Loading branch information
gcf-owl-bot[bot] and gcf-owl-bot[bot] committed Oct 1, 2021
1 parent c271e93 commit ba0a626fe790521d0e082373842a367dfd8de1b3
Showing with 6 additions and 9 deletions.
  1. +6 −9 google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/KeyManagementServiceStubSettings.java
@@ -761,7 +761,6 @@ protected KeyManagementServiceStubSettings(Builder settingsBuilder) throws IOExc
StatusCode.Code.UNAVAILABLE, StatusCode.Code.DEADLINE_EXCEEDED)));
definitions.put(
"no_retry_0_codes", ImmutableSet.copyOf(Lists.<StatusCode.Code>newArrayList()));
definitions.put("no_retry_codes", ImmutableSet.copyOf(Lists.<StatusCode.Code>newArrayList()));
RETRYABLE_CODE_DEFINITIONS = definitions.build();
}

@@ -789,8 +788,6 @@ protected KeyManagementServiceStubSettings(Builder settingsBuilder) throws IOExc
.setTotalTimeout(Duration.ofMillis(60000L))
.build();
definitions.put("no_retry_0_params", settings);
settings = RetrySettings.newBuilder().setRpcTimeoutMultiplier(1.0).build();
definitions.put("no_retry_params", settings);
RETRY_PARAM_DEFINITIONS = definitions.build();
}

@@ -1064,18 +1061,18 @@ private static Builder initDefaults(Builder builder) {

builder
.macSignSettings()
.setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes"))
.setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params"));
.setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_1_codes"))
.setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_1_params"));

builder
.macVerifySettings()
.setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes"))
.setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params"));
.setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_1_codes"))
.setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_1_params"));

builder
.generateRandomBytesSettings()
.setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes"))
.setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params"));
.setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_1_codes"))
.setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_1_params"));

builder
.setIamPolicySettings()

0 comments on commit ba0a626

Please sign in to comment.