Skip to content

Commit 405cb92

Browse files
feat: [compute] Update Compute Engine API to revision 20230307 (#770) (#9230)
* feat: Update Compute Engine API to revision 20230307 (#770) Source-Link: googleapis/googleapis@c2016e5 Source-Link: https://github.com/googleapis/googleapis-gen/commit/0885fd7ae8a805a377974edfba60ab7c9327f75a Copy-Tag: eyJwIjoiamF2YS1jb21wdXRlLy5Pd2xCb3QueWFtbCIsImgiOiIwODg1ZmQ3YWU4YTgwNWEzNzc5NzRlZGZiYTYwYWI3YzkzMjdmNzVhIn0= * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 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 8e44284 commit 405cb92

173 files changed

Lines changed: 48232 additions & 15775 deletions

File tree

Some content is hidden

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

java-compute/README.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ Java idiomatic client for [Compute Engine][product-docs].
1414

1515
If you are using Maven, add this to your pom.xml file:
1616

17-
<!--- {x-version-update-start:google-cloud-compute:released} -->
1817

1918
```xml
2019
<dependency>
@@ -35,7 +34,6 @@ If you are using SBT, add this to your dependencies:
3534
```Scala
3635
libraryDependencies += "com.google.cloud" % "google-cloud-compute" % "1.22.0"
3736
```
38-
<!--- {x-version-update-end} -->
3937

4038
## Authentication
4139

java-compute/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/AutoscalersClient.java

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -444,8 +444,7 @@ public final UnaryCallable<DeleteAutoscalerRequest, Operation> deleteCallable()
444444

445445
// AUTO-GENERATED DOCUMENTATION AND METHOD.
446446
/**
447-
* Returns the specified autoscaler resource. Gets a list of available autoscalers by making a
448-
* list() request.
447+
* Returns the specified autoscaler resource.
449448
*
450449
* <p>Sample code:
451450
*
@@ -480,8 +479,7 @@ public final Autoscaler get(String project, String zone, String autoscaler) {
480479

481480
// AUTO-GENERATED DOCUMENTATION AND METHOD.
482481
/**
483-
* Returns the specified autoscaler resource. Gets a list of available autoscalers by making a
484-
* list() request.
482+
* Returns the specified autoscaler resource.
485483
*
486484
* <p>Sample code:
487485
*
@@ -511,8 +509,7 @@ public final Autoscaler get(GetAutoscalerRequest request) {
511509

512510
// AUTO-GENERATED DOCUMENTATION AND METHOD.
513511
/**
514-
* Returns the specified autoscaler resource. Gets a list of available autoscalers by making a
515-
* list() request.
512+
* Returns the specified autoscaler resource.
516513
*
517514
* <p>Sample code:
518515
*

java-compute/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/BackendBucketsClient.java

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -563,8 +563,7 @@ public final OperationFuture<Operation, Operation> deleteSignedUrlKeyAsync(
563563

564564
// AUTO-GENERATED DOCUMENTATION AND METHOD.
565565
/**
566-
* Returns the specified BackendBucket resource. Gets a list of available backend buckets by
567-
* making a list() request.
566+
* Returns the specified BackendBucket resource.
568567
*
569568
* <p>Sample code:
570569
*
@@ -596,8 +595,7 @@ public final BackendBucket get(String project, String backendBucket) {
596595

597596
// AUTO-GENERATED DOCUMENTATION AND METHOD.
598597
/**
599-
* Returns the specified BackendBucket resource. Gets a list of available backend buckets by
600-
* making a list() request.
598+
* Returns the specified BackendBucket resource.
601599
*
602600
* <p>Sample code:
603601
*
@@ -626,8 +624,7 @@ public final BackendBucket get(GetBackendBucketRequest request) {
626624

627625
// AUTO-GENERATED DOCUMENTATION AND METHOD.
628626
/**
629-
* Returns the specified BackendBucket resource. Gets a list of available backend buckets by
630-
* making a list() request.
627+
* Returns the specified BackendBucket resource.
631628
*
632629
* <p>Sample code:
633630
*

java-compute/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/BackendServicesClient.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -720,7 +720,7 @@ public final OperationFuture<Operation, Operation> deleteSignedUrlKeyAsync(
720720

721721
// AUTO-GENERATED DOCUMENTATION AND METHOD.
722722
/**
723-
* Returns the specified BackendService resource. Gets a list of available backend services.
723+
* Returns the specified BackendService resource.
724724
*
725725
* <p>Sample code:
726726
*
@@ -752,7 +752,7 @@ public final BackendService get(String project, String backendService) {
752752

753753
// AUTO-GENERATED DOCUMENTATION AND METHOD.
754754
/**
755-
* Returns the specified BackendService resource. Gets a list of available backend services.
755+
* Returns the specified BackendService resource.
756756
*
757757
* <p>Sample code:
758758
*
@@ -781,7 +781,7 @@ public final BackendService get(GetBackendServiceRequest request) {
781781

782782
// AUTO-GENERATED DOCUMENTATION AND METHOD.
783783
/**
784-
* Returns the specified BackendService resource. Gets a list of available backend services.
784+
* Returns the specified BackendService resource.
785785
*
786786
* <p>Sample code:
787787
*

java-compute/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/DiskTypesClient.java

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -307,8 +307,7 @@ public final AggregatedListPagedResponse aggregatedList(AggregatedListDiskTypesR
307307

308308
// AUTO-GENERATED DOCUMENTATION AND METHOD.
309309
/**
310-
* Returns the specified disk type. Gets a list of available disk types by making a list()
311-
* request.
310+
* Returns the specified disk type.
312311
*
313312
* <p>Sample code:
314313
*
@@ -343,8 +342,7 @@ public final DiskType get(String project, String zone, String diskType) {
343342

344343
// AUTO-GENERATED DOCUMENTATION AND METHOD.
345344
/**
346-
* Returns the specified disk type. Gets a list of available disk types by making a list()
347-
* request.
345+
* Returns the specified disk type.
348346
*
349347
* <p>Sample code:
350348
*
@@ -374,8 +372,7 @@ public final DiskType get(GetDiskTypeRequest request) {
374372

375373
// AUTO-GENERATED DOCUMENTATION AND METHOD.
376374
/**
377-
* Returns the specified disk type. Gets a list of available disk types by making a list()
378-
* request.
375+
* Returns the specified disk type.
379376
*
380377
* <p>Sample code:
381378
*

java-compute/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/DisksClient.java

Lines changed: 154 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -748,8 +748,7 @@ public final UnaryCallable<DeleteDiskRequest, Operation> deleteCallable() {
748748

749749
// AUTO-GENERATED DOCUMENTATION AND METHOD.
750750
/**
751-
* Returns a specified persistent disk. Gets a list of available persistent disks by making a
752-
* list() request.
751+
* Returns the specified persistent disk.
753752
*
754753
* <p>Sample code:
755754
*
@@ -780,8 +779,7 @@ public final Disk get(String project, String zone, String disk) {
780779

781780
// AUTO-GENERATED DOCUMENTATION AND METHOD.
782781
/**
783-
* Returns a specified persistent disk. Gets a list of available persistent disks by making a
784-
* list() request.
782+
* Returns the specified persistent disk.
785783
*
786784
* <p>Sample code:
787785
*
@@ -811,8 +809,7 @@ public final Disk get(GetDiskRequest request) {
811809

812810
// AUTO-GENERATED DOCUMENTATION AND METHOD.
813811
/**
814-
* Returns a specified persistent disk. Gets a list of available persistent disks by making a
815-
* list() request.
812+
* Returns the specified persistent disk.
816813
*
817814
* <p>Sample code:
818815
*
@@ -1874,6 +1871,157 @@ public final TestPermissionsResponse testIamPermissions(TestIamPermissionsDiskRe
18741871
return stub.testIamPermissionsCallable();
18751872
}
18761873

1874+
// AUTO-GENERATED DOCUMENTATION AND METHOD.
1875+
/**
1876+
* Updates the specified disk with the data included in the request. The update is performed only
1877+
* on selected fields included as part of update-mask. Only the following fields can be modified:
1878+
* user_license.
1879+
*
1880+
* <p>Sample code:
1881+
*
1882+
* <pre>{@code
1883+
* // This snippet has been automatically generated and should be regarded as a code template only.
1884+
* // It will require modifications to work:
1885+
* // - It may require correct/in-range values for request initialization.
1886+
* // - It may require specifying regional endpoints when creating the service client as shown in
1887+
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1888+
* try (DisksClient disksClient = DisksClient.create()) {
1889+
* String project = "project-309310695";
1890+
* String zone = "zone3744684";
1891+
* String disk = "disk3083677";
1892+
* Disk diskResource = Disk.newBuilder().build();
1893+
* Operation response = disksClient.updateAsync(project, zone, disk, diskResource).get();
1894+
* }
1895+
* }</pre>
1896+
*
1897+
* @param project Project ID for this request.
1898+
* @param zone The name of the zone for this request.
1899+
* @param disk The disk name for this request.
1900+
* @param diskResource The body resource for this request
1901+
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
1902+
*/
1903+
public final OperationFuture<Operation, Operation> updateAsync(
1904+
String project, String zone, String disk, Disk diskResource) {
1905+
UpdateDiskRequest request =
1906+
UpdateDiskRequest.newBuilder()
1907+
.setProject(project)
1908+
.setZone(zone)
1909+
.setDisk(disk)
1910+
.setDiskResource(diskResource)
1911+
.build();
1912+
return updateAsync(request);
1913+
}
1914+
1915+
// AUTO-GENERATED DOCUMENTATION AND METHOD.
1916+
/**
1917+
* Updates the specified disk with the data included in the request. The update is performed only
1918+
* on selected fields included as part of update-mask. Only the following fields can be modified:
1919+
* user_license.
1920+
*
1921+
* <p>Sample code:
1922+
*
1923+
* <pre>{@code
1924+
* // This snippet has been automatically generated and should be regarded as a code template only.
1925+
* // It will require modifications to work:
1926+
* // - It may require correct/in-range values for request initialization.
1927+
* // - It may require specifying regional endpoints when creating the service client as shown in
1928+
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1929+
* try (DisksClient disksClient = DisksClient.create()) {
1930+
* UpdateDiskRequest request =
1931+
* UpdateDiskRequest.newBuilder()
1932+
* .setDisk("disk3083677")
1933+
* .setDiskResource(Disk.newBuilder().build())
1934+
* .setPaths("paths106438894")
1935+
* .setProject("project-309310695")
1936+
* .setRequestId("requestId693933066")
1937+
* .setUpdateMask("updateMask-296147115")
1938+
* .setZone("zone3744684")
1939+
* .build();
1940+
* Operation response = disksClient.updateAsync(request).get();
1941+
* }
1942+
* }</pre>
1943+
*
1944+
* @param request The request object containing all of the parameters for the API call.
1945+
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
1946+
*/
1947+
@BetaApi(
1948+
"The surface for long-running operations is not stable yet and may change in the future.")
1949+
public final OperationFuture<Operation, Operation> updateAsync(UpdateDiskRequest request) {
1950+
return updateOperationCallable().futureCall(request);
1951+
}
1952+
1953+
// AUTO-GENERATED DOCUMENTATION AND METHOD.
1954+
/**
1955+
* Updates the specified disk with the data included in the request. The update is performed only
1956+
* on selected fields included as part of update-mask. Only the following fields can be modified:
1957+
* user_license.
1958+
*
1959+
* <p>Sample code:
1960+
*
1961+
* <pre>{@code
1962+
* // This snippet has been automatically generated and should be regarded as a code template only.
1963+
* // It will require modifications to work:
1964+
* // - It may require correct/in-range values for request initialization.
1965+
* // - It may require specifying regional endpoints when creating the service client as shown in
1966+
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1967+
* try (DisksClient disksClient = DisksClient.create()) {
1968+
* UpdateDiskRequest request =
1969+
* UpdateDiskRequest.newBuilder()
1970+
* .setDisk("disk3083677")
1971+
* .setDiskResource(Disk.newBuilder().build())
1972+
* .setPaths("paths106438894")
1973+
* .setProject("project-309310695")
1974+
* .setRequestId("requestId693933066")
1975+
* .setUpdateMask("updateMask-296147115")
1976+
* .setZone("zone3744684")
1977+
* .build();
1978+
* OperationFuture<Operation, Operation> future =
1979+
* disksClient.updateOperationCallable().futureCall(request);
1980+
* // Do something.
1981+
* Operation response = future.get();
1982+
* }
1983+
* }</pre>
1984+
*/
1985+
public final OperationCallable<UpdateDiskRequest, Operation, Operation>
1986+
updateOperationCallable() {
1987+
return stub.updateOperationCallable();
1988+
}
1989+
1990+
// AUTO-GENERATED DOCUMENTATION AND METHOD.
1991+
/**
1992+
* Updates the specified disk with the data included in the request. The update is performed only
1993+
* on selected fields included as part of update-mask. Only the following fields can be modified:
1994+
* user_license.
1995+
*
1996+
* <p>Sample code:
1997+
*
1998+
* <pre>{@code
1999+
* // This snippet has been automatically generated and should be regarded as a code template only.
2000+
* // It will require modifications to work:
2001+
* // - It may require correct/in-range values for request initialization.
2002+
* // - It may require specifying regional endpoints when creating the service client as shown in
2003+
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
2004+
* try (DisksClient disksClient = DisksClient.create()) {
2005+
* UpdateDiskRequest request =
2006+
* UpdateDiskRequest.newBuilder()
2007+
* .setDisk("disk3083677")
2008+
* .setDiskResource(Disk.newBuilder().build())
2009+
* .setPaths("paths106438894")
2010+
* .setProject("project-309310695")
2011+
* .setRequestId("requestId693933066")
2012+
* .setUpdateMask("updateMask-296147115")
2013+
* .setZone("zone3744684")
2014+
* .build();
2015+
* ApiFuture<Operation> future = disksClient.updateCallable().futureCall(request);
2016+
* // Do something.
2017+
* Operation response = future.get();
2018+
* }
2019+
* }</pre>
2020+
*/
2021+
public final UnaryCallable<UpdateDiskRequest, Operation> updateCallable() {
2022+
return stub.updateCallable();
2023+
}
2024+
18772025
@Override
18782026
public final void close() {
18792027
stub.close();

java-compute/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/DisksSettings.java

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -184,6 +184,16 @@ public UnaryCallSettings<SetLabelsDiskRequest, Operation> setLabelsSettings() {
184184
return ((DisksStubSettings) getStubSettings()).testIamPermissionsSettings();
185185
}
186186

187+
/** Returns the object with the settings used for calls to update. */
188+
public UnaryCallSettings<UpdateDiskRequest, Operation> updateSettings() {
189+
return ((DisksStubSettings) getStubSettings()).updateSettings();
190+
}
191+
192+
/** Returns the object with the settings used for calls to update. */
193+
public OperationCallSettings<UpdateDiskRequest, Operation, Operation> updateOperationSettings() {
194+
return ((DisksStubSettings) getStubSettings()).updateOperationSettings();
195+
}
196+
187197
public static final DisksSettings create(DisksStubSettings stub) throws IOException {
188198
return new DisksSettings.Builder(stub.toBuilder()).build();
189199
}
@@ -394,6 +404,17 @@ public UnaryCallSettings.Builder<SetLabelsDiskRequest, Operation> setLabelsSetti
394404
return getStubSettingsBuilder().testIamPermissionsSettings();
395405
}
396406

407+
/** Returns the builder for the settings used for calls to update. */
408+
public UnaryCallSettings.Builder<UpdateDiskRequest, Operation> updateSettings() {
409+
return getStubSettingsBuilder().updateSettings();
410+
}
411+
412+
/** Returns the builder for the settings used for calls to update. */
413+
public OperationCallSettings.Builder<UpdateDiskRequest, Operation, Operation>
414+
updateOperationSettings() {
415+
return getStubSettingsBuilder().updateOperationSettings();
416+
}
417+
397418
@Override
398419
public DisksSettings build() throws IOException {
399420
return new DisksSettings(this);

java-compute/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/FirewallPoliciesClient.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1376,7 +1376,9 @@ public final FirewallPoliciesListAssociationsResponse listAssociations(
13761376
* }</pre>
13771377
*
13781378
* @param firewallPolicy Name of the firewall policy to update.
1379-
* @param parentId The new parent of the firewall policy.
1379+
* @param parentId The new parent of the firewall policy. The ID can be either be
1380+
* "folders/[FOLDER_ID]" if the parent is a folder or "organizations/[ORGANIZATION_ID]" if the
1381+
* parent is an organization.
13801382
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
13811383
*/
13821384
public final OperationFuture<Operation, Operation> moveAsync(

java-compute/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/GlobalAddressesClient.java

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -288,8 +288,7 @@ public final UnaryCallable<DeleteGlobalAddressRequest, Operation> deleteCallable
288288

289289
// AUTO-GENERATED DOCUMENTATION AND METHOD.
290290
/**
291-
* Returns the specified address resource. Gets a list of available addresses by making a list()
292-
* request.
291+
* Returns the specified address resource.
293292
*
294293
* <p>Sample code:
295294
*
@@ -318,8 +317,7 @@ public final Address get(String project, String address) {
318317

319318
// AUTO-GENERATED DOCUMENTATION AND METHOD.
320319
/**
321-
* Returns the specified address resource. Gets a list of available addresses by making a list()
322-
* request.
320+
* Returns the specified address resource.
323321
*
324322
* <p>Sample code:
325323
*
@@ -348,8 +346,7 @@ public final Address get(GetGlobalAddressRequest request) {
348346

349347
// AUTO-GENERATED DOCUMENTATION AND METHOD.
350348
/**
351-
* Returns the specified address resource. Gets a list of available addresses by making a list()
352-
* request.
349+
* Returns the specified address resource.
353350
*
354351
* <p>Sample code:
355352
*

0 commit comments

Comments
 (0)