Skip to content

Commit c226997

Browse files
chore(deps): Update gapic-generator-java to 2.21.0 (#1084)
* chore(deps): Update gapic-generator-java to 2.21.0 PiperOrigin-RevId: 538365689 Source-Link: googleapis/googleapis@7ac8a24 Source-Link: https://github.com/googleapis/googleapis-gen/commit/e58eedb75d3c07878097cdfbfd3ffdb7646763a3 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiZTU4ZWVkYjc1ZDNjMDc4NzgwOTdjZGZiZmQzZmZkYjc2NDY3NjNhMyJ9 chore: upgrading protobuf to 23.2 for code generation PiperOrigin-RevId: 537035741 Source-Link: googleapis/googleapis@640f743 Source-Link: https://github.com/googleapis/googleapis-gen/commit/5ec02ed2022878f99c94c763060ff6a018896b6e Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiNWVjMDJlZDIwMjI4NzhmOTljOTRjNzYzMDYwZmY2YTAxODg5NmI2ZSJ9 chore: upgrading Protobuf to 23.1 and gRPC to 1.55.0 in code generation PiperOrigin-RevId: 534084593 Source-Link: googleapis/googleapis@aa4559a Source-Link: https://github.com/googleapis/googleapis-gen/commit/370325af8236732f5885f5940e0ef481fee83003 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiMzcwMzI1YWY4MjM2NzMyZjU4ODVmNTk0MGUwZWY0ODFmZWU4MzAwMyJ9 * 🦉 Updates from OwlBot post-processor 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>
1 parent fc9b091 commit c226997

File tree

106 files changed

+1351
-729
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

106 files changed

+1351
-729
lines changed

google-cloud-datastore/src/main/java/com/google/cloud/datastore/admin/v1/DatastoreAdminClient.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2022 Google LLC
2+
* Copyright 2023 Google LLC
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.

google-cloud-datastore/src/main/java/com/google/cloud/datastore/admin/v1/DatastoreAdminSettings.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2022 Google LLC
2+
* Copyright 2023 Google LLC
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.

google-cloud-datastore/src/main/java/com/google/cloud/datastore/admin/v1/package-info.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2022 Google LLC
2+
* Copyright 2023 Google LLC
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.

google-cloud-datastore/src/main/java/com/google/cloud/datastore/admin/v1/stub/DatastoreAdminStub.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2022 Google LLC
2+
* Copyright 2023 Google LLC
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.

google-cloud-datastore/src/main/java/com/google/cloud/datastore/admin/v1/stub/DatastoreAdminStubSettings.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2022 Google LLC
2+
* Copyright 2023 Google LLC
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.

google-cloud-datastore/src/main/java/com/google/cloud/datastore/admin/v1/stub/GrpcDatastoreAdminCallableFactory.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2022 Google LLC
2+
* Copyright 2023 Google LLC
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.

google-cloud-datastore/src/main/java/com/google/cloud/datastore/admin/v1/stub/GrpcDatastoreAdminStub.java

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2022 Google LLC
2+
* Copyright 2023 Google LLC
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -24,8 +24,8 @@
2424
import com.google.api.gax.grpc.GrpcStubCallableFactory;
2525
import com.google.api.gax.rpc.ClientContext;
2626
import com.google.api.gax.rpc.OperationCallable;
27+
import com.google.api.gax.rpc.RequestParamsBuilder;
2728
import com.google.api.gax.rpc.UnaryCallable;
28-
import com.google.common.collect.ImmutableMap;
2929
import com.google.datastore.admin.v1.CreateIndexRequest;
3030
import com.google.datastore.admin.v1.DeleteIndexRequest;
3131
import com.google.datastore.admin.v1.ExportEntitiesMetadata;
@@ -176,61 +176,61 @@ protected GrpcDatastoreAdminStub(
176176
.setMethodDescriptor(exportEntitiesMethodDescriptor)
177177
.setParamsExtractor(
178178
request -> {
179-
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
180-
params.put("project_id", String.valueOf(request.getProjectId()));
181-
return params.build();
179+
RequestParamsBuilder builder = RequestParamsBuilder.create();
180+
builder.add("project_id", String.valueOf(request.getProjectId()));
181+
return builder.build();
182182
})
183183
.build();
184184
GrpcCallSettings<ImportEntitiesRequest, Operation> importEntitiesTransportSettings =
185185
GrpcCallSettings.<ImportEntitiesRequest, Operation>newBuilder()
186186
.setMethodDescriptor(importEntitiesMethodDescriptor)
187187
.setParamsExtractor(
188188
request -> {
189-
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
190-
params.put("project_id", String.valueOf(request.getProjectId()));
191-
return params.build();
189+
RequestParamsBuilder builder = RequestParamsBuilder.create();
190+
builder.add("project_id", String.valueOf(request.getProjectId()));
191+
return builder.build();
192192
})
193193
.build();
194194
GrpcCallSettings<CreateIndexRequest, Operation> createIndexTransportSettings =
195195
GrpcCallSettings.<CreateIndexRequest, Operation>newBuilder()
196196
.setMethodDescriptor(createIndexMethodDescriptor)
197197
.setParamsExtractor(
198198
request -> {
199-
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
200-
params.put("project_id", String.valueOf(request.getProjectId()));
201-
return params.build();
199+
RequestParamsBuilder builder = RequestParamsBuilder.create();
200+
builder.add("project_id", String.valueOf(request.getProjectId()));
201+
return builder.build();
202202
})
203203
.build();
204204
GrpcCallSettings<DeleteIndexRequest, Operation> deleteIndexTransportSettings =
205205
GrpcCallSettings.<DeleteIndexRequest, Operation>newBuilder()
206206
.setMethodDescriptor(deleteIndexMethodDescriptor)
207207
.setParamsExtractor(
208208
request -> {
209-
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
210-
params.put("index_id", String.valueOf(request.getIndexId()));
211-
params.put("project_id", String.valueOf(request.getProjectId()));
212-
return params.build();
209+
RequestParamsBuilder builder = RequestParamsBuilder.create();
210+
builder.add("index_id", String.valueOf(request.getIndexId()));
211+
builder.add("project_id", String.valueOf(request.getProjectId()));
212+
return builder.build();
213213
})
214214
.build();
215215
GrpcCallSettings<GetIndexRequest, Index> getIndexTransportSettings =
216216
GrpcCallSettings.<GetIndexRequest, Index>newBuilder()
217217
.setMethodDescriptor(getIndexMethodDescriptor)
218218
.setParamsExtractor(
219219
request -> {
220-
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
221-
params.put("index_id", String.valueOf(request.getIndexId()));
222-
params.put("project_id", String.valueOf(request.getProjectId()));
223-
return params.build();
220+
RequestParamsBuilder builder = RequestParamsBuilder.create();
221+
builder.add("index_id", String.valueOf(request.getIndexId()));
222+
builder.add("project_id", String.valueOf(request.getProjectId()));
223+
return builder.build();
224224
})
225225
.build();
226226
GrpcCallSettings<ListIndexesRequest, ListIndexesResponse> listIndexesTransportSettings =
227227
GrpcCallSettings.<ListIndexesRequest, ListIndexesResponse>newBuilder()
228228
.setMethodDescriptor(listIndexesMethodDescriptor)
229229
.setParamsExtractor(
230230
request -> {
231-
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
232-
params.put("project_id", String.valueOf(request.getProjectId()));
233-
return params.build();
231+
RequestParamsBuilder builder = RequestParamsBuilder.create();
232+
builder.add("project_id", String.valueOf(request.getProjectId()));
233+
return builder.build();
234234
})
235235
.build();
236236

google-cloud-datastore/src/main/java/com/google/cloud/datastore/admin/v1/stub/HttpJsonDatastoreAdminCallableFactory.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2022 Google LLC
2+
* Copyright 2023 Google LLC
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.

google-cloud-datastore/src/main/java/com/google/cloud/datastore/admin/v1/stub/HttpJsonDatastoreAdminStub.java

Lines changed: 40 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2022 Google LLC
2+
* Copyright 2023 Google LLC
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -33,6 +33,7 @@
3333
import com.google.api.gax.httpjson.longrunning.stub.HttpJsonOperationsStub;
3434
import com.google.api.gax.rpc.ClientContext;
3535
import com.google.api.gax.rpc.OperationCallable;
36+
import com.google.api.gax.rpc.RequestParamsBuilder;
3637
import com.google.api.gax.rpc.UnaryCallable;
3738
import com.google.common.collect.ImmutableMap;
3839
import com.google.datastore.admin.v1.CreateIndexRequest;
@@ -392,31 +393,69 @@ protected HttpJsonDatastoreAdminStub(
392393
HttpJsonCallSettings.<ExportEntitiesRequest, Operation>newBuilder()
393394
.setMethodDescriptor(exportEntitiesMethodDescriptor)
394395
.setTypeRegistry(typeRegistry)
396+
.setParamsExtractor(
397+
request -> {
398+
RequestParamsBuilder builder = RequestParamsBuilder.create();
399+
builder.add("project_id", String.valueOf(request.getProjectId()));
400+
return builder.build();
401+
})
395402
.build();
396403
HttpJsonCallSettings<ImportEntitiesRequest, Operation> importEntitiesTransportSettings =
397404
HttpJsonCallSettings.<ImportEntitiesRequest, Operation>newBuilder()
398405
.setMethodDescriptor(importEntitiesMethodDescriptor)
399406
.setTypeRegistry(typeRegistry)
407+
.setParamsExtractor(
408+
request -> {
409+
RequestParamsBuilder builder = RequestParamsBuilder.create();
410+
builder.add("project_id", String.valueOf(request.getProjectId()));
411+
return builder.build();
412+
})
400413
.build();
401414
HttpJsonCallSettings<CreateIndexRequest, Operation> createIndexTransportSettings =
402415
HttpJsonCallSettings.<CreateIndexRequest, Operation>newBuilder()
403416
.setMethodDescriptor(createIndexMethodDescriptor)
404417
.setTypeRegistry(typeRegistry)
418+
.setParamsExtractor(
419+
request -> {
420+
RequestParamsBuilder builder = RequestParamsBuilder.create();
421+
builder.add("project_id", String.valueOf(request.getProjectId()));
422+
return builder.build();
423+
})
405424
.build();
406425
HttpJsonCallSettings<DeleteIndexRequest, Operation> deleteIndexTransportSettings =
407426
HttpJsonCallSettings.<DeleteIndexRequest, Operation>newBuilder()
408427
.setMethodDescriptor(deleteIndexMethodDescriptor)
409428
.setTypeRegistry(typeRegistry)
429+
.setParamsExtractor(
430+
request -> {
431+
RequestParamsBuilder builder = RequestParamsBuilder.create();
432+
builder.add("index_id", String.valueOf(request.getIndexId()));
433+
builder.add("project_id", String.valueOf(request.getProjectId()));
434+
return builder.build();
435+
})
410436
.build();
411437
HttpJsonCallSettings<GetIndexRequest, Index> getIndexTransportSettings =
412438
HttpJsonCallSettings.<GetIndexRequest, Index>newBuilder()
413439
.setMethodDescriptor(getIndexMethodDescriptor)
414440
.setTypeRegistry(typeRegistry)
441+
.setParamsExtractor(
442+
request -> {
443+
RequestParamsBuilder builder = RequestParamsBuilder.create();
444+
builder.add("index_id", String.valueOf(request.getIndexId()));
445+
builder.add("project_id", String.valueOf(request.getProjectId()));
446+
return builder.build();
447+
})
415448
.build();
416449
HttpJsonCallSettings<ListIndexesRequest, ListIndexesResponse> listIndexesTransportSettings =
417450
HttpJsonCallSettings.<ListIndexesRequest, ListIndexesResponse>newBuilder()
418451
.setMethodDescriptor(listIndexesMethodDescriptor)
419452
.setTypeRegistry(typeRegistry)
453+
.setParamsExtractor(
454+
request -> {
455+
RequestParamsBuilder builder = RequestParamsBuilder.create();
456+
builder.add("project_id", String.valueOf(request.getProjectId()));
457+
return builder.build();
458+
})
420459
.build();
421460

422461
this.exportEntitiesCallable =

google-cloud-datastore/src/test/java/com/google/cloud/datastore/admin/v1/DatastoreAdminClientHttpJsonTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2022 Google LLC
2+
* Copyright 2023 Google LLC
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.

google-cloud-datastore/src/test/java/com/google/cloud/datastore/admin/v1/DatastoreAdminClientTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2022 Google LLC
2+
* Copyright 2023 Google LLC
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.

google-cloud-datastore/src/test/java/com/google/cloud/datastore/admin/v1/MockDatastoreAdmin.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2022 Google LLC
2+
* Copyright 2023 Google LLC
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.

google-cloud-datastore/src/test/java/com/google/cloud/datastore/admin/v1/MockDatastoreAdminImpl.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2022 Google LLC
2+
* Copyright 2023 Google LLC
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.

proto-google-cloud-datastore-admin-v1/src/main/java/com/google/datastore/admin/v1/CommonMetadata.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -48,11 +48,6 @@ protected java.lang.Object newInstance(UnusedPrivateParameter unused) {
4848
return new CommonMetadata();
4949
}
5050

51-
@java.lang.Override
52-
public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
53-
return this.unknownFields;
54-
}
55-
5651
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
5752
return com.google.datastore.admin.v1.DatastoreAdminProto
5853
.internal_static_google_datastore_admin_v1_CommonMetadata_descriptor;

proto-google-cloud-datastore-admin-v1/src/main/java/com/google/datastore/admin/v1/CreateIndexRequest.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -48,11 +48,6 @@ protected java.lang.Object newInstance(UnusedPrivateParameter unused) {
4848
return new CreateIndexRequest();
4949
}
5050

51-
@java.lang.Override
52-
public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
53-
return this.unknownFields;
54-
}
55-
5651
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
5752
return com.google.datastore.admin.v1.DatastoreAdminProto
5853
.internal_static_google_datastore_admin_v1_CreateIndexRequest_descriptor;

0 commit comments

Comments
 (0)