Skip to content

Commit

Permalink
chore: generate libraries at Thu Jan 23 21:55:39 UTC 2025
Browse files Browse the repository at this point in the history
  • Loading branch information
cloud-java-bot committed Jan 23, 2025
1 parent c01b5d2 commit 1d67266
Show file tree
Hide file tree
Showing 8 changed files with 486 additions and 153 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ If you are using Maven without the BOM, add this to your dependencies:
If you are using Gradle 5.x or later, add this to your dependencies:

```Groovy
implementation platform('com.google.cloud:libraries-bom:26.52.0')
implementation platform('com.google.cloud:libraries-bom:26.53.0')
implementation 'com.google.cloud:google-cloud-firestore'
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3168,6 +3168,7 @@ public final ListBackupsResponse listBackups(String parent) {
* ListBackupsRequest request =
* ListBackupsRequest.newBuilder()
* .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
* .setFilter("filter-1274492040")
* .build();
* ListBackupsResponse response = firestoreAdminClient.listBackups(request);
* }
Expand Down Expand Up @@ -3196,6 +3197,7 @@ public final ListBackupsResponse listBackups(ListBackupsRequest request) {
* ListBackupsRequest request =
* ListBackupsRequest.newBuilder()
* .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
* .setFilter("filter-1274492040")
* .build();
* ApiFuture<ListBackupsResponse> future =
* firestoreAdminClient.listBackupsCallable().futureCall(request);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -758,6 +758,8 @@ public static class Builder extends StubSettings.Builder<FirestoreAdminStubSetti
StatusCode.Code.UNAVAILABLE,
StatusCode.Code.INTERNAL,
StatusCode.Code.DEADLINE_EXCEEDED)));
definitions.put(
"no_retry_2_codes", ImmutableSet.copyOf(Lists.<StatusCode.Code>newArrayList()));
definitions.put("no_retry_codes", ImmutableSet.copyOf(Lists.<StatusCode.Code>newArrayList()));
RETRYABLE_CODE_DEFINITIONS = definitions.build();
}
Expand Down Expand Up @@ -786,6 +788,14 @@ public static class Builder extends StubSettings.Builder<FirestoreAdminStubSetti
.setTotalTimeoutDuration(Duration.ofMillis(60000L))
.build();
definitions.put("retry_policy_0_params", settings);
settings =
RetrySettings.newBuilder()
.setInitialRpcTimeoutDuration(Duration.ofMillis(120000L))
.setRpcTimeoutMultiplier(1.0)
.setMaxRpcTimeoutDuration(Duration.ofMillis(120000L))
.setTotalTimeoutDuration(Duration.ofMillis(120000L))
.build();
definitions.put("no_retry_2_params", settings);
settings = RetrySettings.newBuilder().setRpcTimeoutMultiplier(1.0).build();
definitions.put("no_retry_params", settings);
RETRY_PARAM_DEFINITIONS = definitions.build();
Expand Down Expand Up @@ -1004,8 +1014,8 @@ private static Builder initDefaults(Builder builder) {

builder
.createDatabaseSettings()
.setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes"))
.setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params"));
.setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_2_codes"))
.setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_2_params"));

builder
.getDatabaseSettings()
Expand Down Expand Up @@ -1044,8 +1054,8 @@ private static Builder initDefaults(Builder builder) {

builder
.restoreDatabaseSettings()
.setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes"))
.setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params"));
.setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_2_codes"))
.setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_2_params"));

builder
.createBackupScheduleSettings()
Expand Down Expand Up @@ -1197,8 +1207,8 @@ private static Builder initDefaults(Builder builder) {
.setInitialCallSettings(
UnaryCallSettings
.<CreateDatabaseRequest, OperationSnapshot>newUnaryCallSettingsBuilder()
.setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes"))
.setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params"))
.setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_2_codes"))
.setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_2_params"))
.build())
.setResponseTransformer(
ProtoOperationTransformers.ResponseTransformer.create(Database.class))
Expand Down Expand Up @@ -1269,8 +1279,8 @@ private static Builder initDefaults(Builder builder) {
.setInitialCallSettings(
UnaryCallSettings
.<RestoreDatabaseRequest, OperationSnapshot>newUnaryCallSettingsBuilder()
.setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes"))
.setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params"))
.setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_2_codes"))
.setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_2_params"))
.build())
.setResponseTransformer(
ProtoOperationTransformers.ResponseTransformer.create(Database.class))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -740,6 +740,7 @@ public class HttpJsonFirestoreAdminStub extends FirestoreAdminStub {
Map<String, List<String>> fields = new HashMap<>();
ProtoRestSerializer<ListBackupsRequest> serializer =
ProtoRestSerializer.create();
serializer.putQueryParam(fields, "filter", request.getFilter());
serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int");
return fields;
})
Expand Down
Loading

0 comments on commit 1d67266

Please sign in to comment.