Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/hermetic_library_generation.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ jobs:
echo "SHOULD_RUN=false" >> $GITHUB_ENV
fi

- uses: googleapis/sdk-platform-java/.github/scripts@v2.66.0
- uses: googleapis/sdk-platform-java/.github/scripts@v2.66.1
if: env.SHOULD_RUN == 'true'
with:
base_ref: ${{ github.base_ref }}
Expand Down
2 changes: 1 addition & 1 deletion .kokoro/presubmit/graalvm-native-a.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Configure the docker image for kokoro-trampoline.
env_vars: {
key: "TRAMPOLINE_IMAGE"
value: "gcr.io/cloud-devrel-public-resources/graalvm_sdk_platform_a:3.56.0" # {x-version-update:google-cloud-shared-dependencies:current}
value: "gcr.io/cloud-devrel-public-resources/graalvm_sdk_platform_a:3.56.1" # {x-version-update:google-cloud-shared-dependencies:current}
}

env_vars: {
Expand Down
2 changes: 1 addition & 1 deletion .kokoro/presubmit/graalvm-native-b.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Configure the docker image for kokoro-trampoline.
env_vars: {
key: "TRAMPOLINE_IMAGE"
value: "gcr.io/cloud-devrel-public-resources/graalvm_sdk_platform_b:3.56.0" # {x-version-update:google-cloud-shared-dependencies:current}
value: "gcr.io/cloud-devrel-public-resources/graalvm_sdk_platform_b:3.56.1" # {x-version-update:google-cloud-shared-dependencies:current}
}

env_vars: {
Expand Down
2 changes: 1 addition & 1 deletion .kokoro/presubmit/graalvm-native-c.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Configure the docker image for kokoro-trampoline.
env_vars: {
key: "TRAMPOLINE_IMAGE"
value: "gcr.io/cloud-devrel-public-resources/graalvm_sdk_platform_c:3.56.0" # {x-version-update:google-cloud-shared-dependencies:current}
value: "gcr.io/cloud-devrel-public-resources/graalvm_sdk_platform_c:3.56.1" # {x-version-update:google-cloud-shared-dependencies:current}
}

env_vars: {
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,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.74.0')
implementation platform('com.google.cloud:libraries-bom:26.75.0')

implementation 'com.google.cloud:google-cloud-storage'
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -405,7 +405,7 @@
* <tr>
* <td><p> BidiReadObject</td>
* <td><p> Reads an object's data.
* <p> This bi-directional API reads data from an object, allowing you to request multiple data ranges within a single stream, even across several messages. If an error occurs with any request, the stream closes with a relevant error code. Since you can have multiple outstanding requests, the error response includes a `BidiReadObjectRangesError` field detailing the specific error for each pending `read_id`.
* <p> This bi-directional API reads data from an object, allowing you to request multiple data ranges within a single stream, even across several messages. If an error occurs with any request, the stream closes with a relevant error code. Since you can have multiple outstanding requests, the error response includes a `BidiReadObjectError` proto in its `details` field, reporting the specific error, if any, for each pending `read_id`.
* <p> &#42;&#42;IAM Permissions&#42;&#42;:
* <p> Requires `storage.objects.get` IAM permission on the bucket.</td>
* <td>
Expand Down Expand Up @@ -2139,6 +2139,7 @@ public final UnaryCallable<UpdateBucketRequest, Bucket> updateBucketCallable() {
* .toString())
* .setCommonObjectRequestParams(CommonObjectRequestParams.newBuilder().build())
* .setObjectChecksums(ObjectChecksums.newBuilder().build())
* .setDeleteSourceObjects(true)
* .build();
* Object response = storageClient.composeObject(request);
* }
Expand Down Expand Up @@ -2185,6 +2186,7 @@ public final Object composeObject(ComposeObjectRequest request) {
* .toString())
* .setCommonObjectRequestParams(CommonObjectRequestParams.newBuilder().build())
* .setObjectChecksums(ObjectChecksums.newBuilder().build())
* .setDeleteSourceObjects(true)
* .build();
* ApiFuture<Object> future = storageClient.composeObjectCallable().futureCall(request);
* // Do something.
Expand Down Expand Up @@ -3093,8 +3095,8 @@ public final ServerStreamingCallable<ReadObjectRequest, ReadObjectResponse> read
* <p>This bi-directional API reads data from an object, allowing you to request multiple data
* ranges within a single stream, even across several messages. If an error occurs with any
* request, the stream closes with a relevant error code. Since you can have multiple outstanding
* requests, the error response includes a `BidiReadObjectRangesError` field detailing the
* specific error for each pending `read_id`.
* requests, the error response includes a `BidiReadObjectError` proto in its `details` field,
* reporting the specific error, if any, for each pending `read_id`.
*
* <p>&#42;&#42;IAM Permissions&#42;&#42;:
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1064,6 +1064,7 @@ public void composeObjectTest() throws Exception {
.toString())
.setCommonObjectRequestParams(CommonObjectRequestParams.newBuilder().build())
.setObjectChecksums(ObjectChecksums.newBuilder().build())
.setDeleteSourceObjects(true)
.build();

Object actualResponse = client.composeObject(request);
Expand All @@ -1084,6 +1085,7 @@ public void composeObjectTest() throws Exception {
Assert.assertEquals(
request.getCommonObjectRequestParams(), actualRequest.getCommonObjectRequestParams());
Assert.assertEquals(request.getObjectChecksums(), actualRequest.getObjectChecksums());
Assert.assertEquals(request.getDeleteSourceObjects(), actualRequest.getDeleteSourceObjects());
Assert.assertTrue(
channelProvider.isHeaderSent(
ApiClientHeaderProvider.getDefaultApiClientHeaderKey(),
Expand All @@ -1108,6 +1110,7 @@ public void composeObjectExceptionTest() throws Exception {
.toString())
.setCommonObjectRequestParams(CommonObjectRequestParams.newBuilder().build())
.setObjectChecksums(ObjectChecksums.newBuilder().build())
.setDeleteSourceObjects(true)
.build();
client.composeObject(request);
Assert.fail("No exception raised");
Expand Down
6 changes: 3 additions & 3 deletions generation_config.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
gapic_generator_version: 2.66.0
googleapis_commitish: cfe62b3c5ceb9f81879c61480f26707980534462
libraries_bom_version: 26.74.0
gapic_generator_version: 2.66.1
googleapis_commitish: 725496d32a359a40dd773995d3fda0342b440e15
libraries_bom_version: 26.75.0
libraries:
- api_shortname: storage
name_pretty: Cloud Storage
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,26 @@
* </td>
* </tr>
* <tr>
* <td><p> DeleteFolderRecursive</td>
* <td><p> Deletes a folder recursively. This operation is only applicable to a hierarchical namespace enabled bucket.</td>
* <td>
* <p>Request object method variants only take one parameter, a request object, which must be constructed before the call.</p>
* <ul>
* <li><p> deleteFolderRecursiveAsync(DeleteFolderRecursiveRequest request)
* </ul>
* <p>Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.</p>
* <ul>
* <li><p> deleteFolderRecursiveAsync(FolderName name)
* <li><p> deleteFolderRecursiveAsync(String name)
* </ul>
* <p>Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.</p>
* <ul>
* <li><p> deleteFolderRecursiveOperationCallable()
* <li><p> deleteFolderRecursiveCallable()
* </ul>
* </td>
* </tr>
* <tr>
* <td><p> GetStorageLayout</td>
* <td><p> Returns the storage layout configuration for a given bucket.</td>
* <td>
Expand Down Expand Up @@ -1450,6 +1470,167 @@ public final UnaryCallable<RenameFolderRequest, Operation> renameFolderCallable(
return stub.renameFolderCallable();
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Deletes a folder recursively. This operation is only applicable to a hierarchical namespace
* enabled bucket.
*
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* try (StorageControlClient storageControlClient = StorageControlClient.create()) {
* FolderName name = FolderName.of("[PROJECT]", "[BUCKET]", "[FOLDER]");
* storageControlClient.deleteFolderRecursiveAsync(name).get();
* }
* }</pre>
*
* @param name Required. Name of the folder being deleted, however all of its contents will be
* deleted too. Format: `projects/{project}/buckets/{bucket}/folders/{folder}`
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
public final OperationFuture<Empty, DeleteFolderRecursiveMetadata> deleteFolderRecursiveAsync(
FolderName name) {
DeleteFolderRecursiveRequest request =
DeleteFolderRecursiveRequest.newBuilder()
.setName(name == null ? null : name.toString())
.build();
return deleteFolderRecursiveAsync(request);
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Deletes a folder recursively. This operation is only applicable to a hierarchical namespace
* enabled bucket.
*
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* try (StorageControlClient storageControlClient = StorageControlClient.create()) {
* String name = FolderName.of("[PROJECT]", "[BUCKET]", "[FOLDER]").toString();
* storageControlClient.deleteFolderRecursiveAsync(name).get();
* }
* }</pre>
*
* @param name Required. Name of the folder being deleted, however all of its contents will be
* deleted too. Format: `projects/{project}/buckets/{bucket}/folders/{folder}`
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
public final OperationFuture<Empty, DeleteFolderRecursiveMetadata> deleteFolderRecursiveAsync(
String name) {
DeleteFolderRecursiveRequest request =
DeleteFolderRecursiveRequest.newBuilder().setName(name).build();
return deleteFolderRecursiveAsync(request);
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Deletes a folder recursively. This operation is only applicable to a hierarchical namespace
* enabled bucket.
*
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* try (StorageControlClient storageControlClient = StorageControlClient.create()) {
* DeleteFolderRecursiveRequest request =
* DeleteFolderRecursiveRequest.newBuilder()
* .setName(FolderName.of("[PROJECT]", "[BUCKET]", "[FOLDER]").toString())
* .setIfMetagenerationMatch(1043427781)
* .setIfMetagenerationNotMatch(1025430873)
* .setRequestId("requestId693933066")
* .build();
* storageControlClient.deleteFolderRecursiveAsync(request).get();
* }
* }</pre>
*
* @param request The request object containing all of the parameters for the API call.
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
public final OperationFuture<Empty, DeleteFolderRecursiveMetadata> deleteFolderRecursiveAsync(
DeleteFolderRecursiveRequest request) {
return deleteFolderRecursiveOperationCallable().futureCall(request);
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Deletes a folder recursively. This operation is only applicable to a hierarchical namespace
* enabled bucket.
*
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* try (StorageControlClient storageControlClient = StorageControlClient.create()) {
* DeleteFolderRecursiveRequest request =
* DeleteFolderRecursiveRequest.newBuilder()
* .setName(FolderName.of("[PROJECT]", "[BUCKET]", "[FOLDER]").toString())
* .setIfMetagenerationMatch(1043427781)
* .setIfMetagenerationNotMatch(1025430873)
* .setRequestId("requestId693933066")
* .build();
* OperationFuture<Empty, DeleteFolderRecursiveMetadata> future =
* storageControlClient.deleteFolderRecursiveOperationCallable().futureCall(request);
* // Do something.
* future.get();
* }
* }</pre>
*/
public final OperationCallable<DeleteFolderRecursiveRequest, Empty, DeleteFolderRecursiveMetadata>
deleteFolderRecursiveOperationCallable() {
return stub.deleteFolderRecursiveOperationCallable();
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Deletes a folder recursively. This operation is only applicable to a hierarchical namespace
* enabled bucket.
*
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* try (StorageControlClient storageControlClient = StorageControlClient.create()) {
* DeleteFolderRecursiveRequest request =
* DeleteFolderRecursiveRequest.newBuilder()
* .setName(FolderName.of("[PROJECT]", "[BUCKET]", "[FOLDER]").toString())
* .setIfMetagenerationMatch(1043427781)
* .setIfMetagenerationNotMatch(1025430873)
* .setRequestId("requestId693933066")
* .build();
* ApiFuture<Operation> future =
* storageControlClient.deleteFolderRecursiveCallable().futureCall(request);
* // Do something.
* future.get();
* }
* }</pre>
*/
public final UnaryCallable<DeleteFolderRecursiveRequest, Operation>
deleteFolderRecursiveCallable() {
return stub.deleteFolderRecursiveCallable();
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Returns the storage layout configuration for a given bucket.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,19 @@ public UnaryCallSettings<RenameFolderRequest, Operation> renameFolderSettings()
return ((StorageControlStubSettings) getStubSettings()).renameFolderOperationSettings();
}

/** Returns the object with the settings used for calls to deleteFolderRecursive. */
public UnaryCallSettings<DeleteFolderRecursiveRequest, Operation>
deleteFolderRecursiveSettings() {
return ((StorageControlStubSettings) getStubSettings()).deleteFolderRecursiveSettings();
}

/** Returns the object with the settings used for calls to deleteFolderRecursive. */
public OperationCallSettings<DeleteFolderRecursiveRequest, Empty, DeleteFolderRecursiveMetadata>
deleteFolderRecursiveOperationSettings() {
return ((StorageControlStubSettings) getStubSettings())
.deleteFolderRecursiveOperationSettings();
}

/** Returns the object with the settings used for calls to getStorageLayout. */
public UnaryCallSettings<GetStorageLayoutRequest, StorageLayout> getStorageLayoutSettings() {
return ((StorageControlStubSettings) getStubSettings()).getStorageLayoutSettings();
Expand Down Expand Up @@ -440,6 +453,19 @@ public UnaryCallSettings.Builder<RenameFolderRequest, Operation> renameFolderSet
return getStubSettingsBuilder().renameFolderOperationSettings();
}

/** Returns the builder for the settings used for calls to deleteFolderRecursive. */
public UnaryCallSettings.Builder<DeleteFolderRecursiveRequest, Operation>
deleteFolderRecursiveSettings() {
return getStubSettingsBuilder().deleteFolderRecursiveSettings();
}

/** Returns the builder for the settings used for calls to deleteFolderRecursive. */
public OperationCallSettings.Builder<
DeleteFolderRecursiveRequest, Empty, DeleteFolderRecursiveMetadata>
deleteFolderRecursiveOperationSettings() {
return getStubSettingsBuilder().deleteFolderRecursiveOperationSettings();
}

/** Returns the builder for the settings used for calls to getStorageLayout. */
public UnaryCallSettings.Builder<GetStorageLayoutRequest, StorageLayout>
getStorageLayoutSettings() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@
"DeleteFolder": {
"methods": ["deleteFolder", "deleteFolder", "deleteFolder", "deleteFolderCallable"]
},
"DeleteFolderRecursive": {
"methods": ["deleteFolderRecursiveAsync", "deleteFolderRecursiveAsync", "deleteFolderRecursiveAsync", "deleteFolderRecursiveOperationCallable", "deleteFolderRecursiveCallable"]
},
"DeleteManagedFolder": {
"methods": ["deleteManagedFolder", "deleteManagedFolder", "deleteManagedFolder", "deleteManagedFolderCallable"]
},
Expand Down
Loading