Skip to content

Commit

Permalink
feat: [metastore] added Admin Interface (v1) (#9612)
Browse files Browse the repository at this point in the history
* feat: added Admin Interface (v1)
feat: added gRPC endpoint protocol (v1)
feat: added BigQuery as a backend metastore (v1)

PiperOrigin-RevId: 545570906

Source-Link: googleapis/googleapis@ba4742e

Source-Link: googleapis/googleapis-gen@ab122fc
Copy-Tag: eyJwIjoiamF2YS1kYXRhcHJvYy1tZXRhc3RvcmUvLk93bEJvdC55YW1sIiwiaCI6ImFiMTIyZmNkZmMyNjhmNzU3NjM3ZmQ1Yzc0ZDliOWY5NjVkMDJjZjMifQ==

* 🦉 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>
  • Loading branch information
gcf-owl-bot[bot] and gcf-owl-bot[bot] committed Jul 7, 2023
1 parent 79b80a3 commit 9cb69a8
Show file tree
Hide file tree
Showing 51 changed files with 11,787 additions and 654 deletions.
4 changes: 2 additions & 2 deletions java-dataproc-metastore/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ If you are using Maven with [BOM][libraries-bom], add this to your pom.xml file:
<dependency>
<groupId>com.google.cloud</groupId>
<artifactId>libraries-bom</artifactId>
<version>26.16.0</version>
<version>26.18.0</version>
<type>pom</type>
<scope>import</scope>
</dependency>
Expand Down Expand Up @@ -195,7 +195,7 @@ Java is a registered trademark of Oracle and/or its affiliates.
[kokoro-badge-link-5]: http://storage.googleapis.com/cloud-devrel-public/java/badges/google-cloud-java/java11.html
[stability-image]: https://img.shields.io/badge/stability-stable-green
[maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-dataproc-metastore.svg
[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dataproc-metastore/2.20.0
[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dataproc-metastore/2.21.0
[authentication]: https://github.com/googleapis/google-cloud-java#authentication
[auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes
[predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2535,6 +2535,297 @@ public final UnaryCallable<DeleteBackupRequest, Operation> deleteBackupCallable(
return stub.deleteBackupCallable();
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Query DPMS metadata.
*
* <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 (DataprocMetastoreClient dataprocMetastoreClient = DataprocMetastoreClient.create()) {
* QueryMetadataRequest request =
* QueryMetadataRequest.newBuilder()
* .setService(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString())
* .setQuery("query107944136")
* .build();
* QueryMetadataResponse response = dataprocMetastoreClient.queryMetadataAsync(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<QueryMetadataResponse, OperationMetadata> queryMetadataAsync(
QueryMetadataRequest request) {
return queryMetadataOperationCallable().futureCall(request);
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Query DPMS metadata.
*
* <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 (DataprocMetastoreClient dataprocMetastoreClient = DataprocMetastoreClient.create()) {
* QueryMetadataRequest request =
* QueryMetadataRequest.newBuilder()
* .setService(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString())
* .setQuery("query107944136")
* .build();
* OperationFuture<QueryMetadataResponse, OperationMetadata> future =
* dataprocMetastoreClient.queryMetadataOperationCallable().futureCall(request);
* // Do something.
* QueryMetadataResponse response = future.get();
* }
* }</pre>
*/
public final OperationCallable<QueryMetadataRequest, QueryMetadataResponse, OperationMetadata>
queryMetadataOperationCallable() {
return stub.queryMetadataOperationCallable();
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Query DPMS metadata.
*
* <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 (DataprocMetastoreClient dataprocMetastoreClient = DataprocMetastoreClient.create()) {
* QueryMetadataRequest request =
* QueryMetadataRequest.newBuilder()
* .setService(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString())
* .setQuery("query107944136")
* .build();
* ApiFuture<Operation> future =
* dataprocMetastoreClient.queryMetadataCallable().futureCall(request);
* // Do something.
* Operation response = future.get();
* }
* }</pre>
*/
public final UnaryCallable<QueryMetadataRequest, Operation> queryMetadataCallable() {
return stub.queryMetadataCallable();
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Move a table to another database.
*
* <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 (DataprocMetastoreClient dataprocMetastoreClient = DataprocMetastoreClient.create()) {
* MoveTableToDatabaseRequest request =
* MoveTableToDatabaseRequest.newBuilder()
* .setService(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString())
* .setTableName("tableName-1988717703")
* .setDbName("dbName-1339126743")
* .setDestinationDbName("destinationDbName-2077361705")
* .build();
* MoveTableToDatabaseResponse response =
* dataprocMetastoreClient.moveTableToDatabaseAsync(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<MoveTableToDatabaseResponse, OperationMetadata>
moveTableToDatabaseAsync(MoveTableToDatabaseRequest request) {
return moveTableToDatabaseOperationCallable().futureCall(request);
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Move a table to another database.
*
* <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 (DataprocMetastoreClient dataprocMetastoreClient = DataprocMetastoreClient.create()) {
* MoveTableToDatabaseRequest request =
* MoveTableToDatabaseRequest.newBuilder()
* .setService(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString())
* .setTableName("tableName-1988717703")
* .setDbName("dbName-1339126743")
* .setDestinationDbName("destinationDbName-2077361705")
* .build();
* OperationFuture<MoveTableToDatabaseResponse, OperationMetadata> future =
* dataprocMetastoreClient.moveTableToDatabaseOperationCallable().futureCall(request);
* // Do something.
* MoveTableToDatabaseResponse response = future.get();
* }
* }</pre>
*/
public final OperationCallable<
MoveTableToDatabaseRequest, MoveTableToDatabaseResponse, OperationMetadata>
moveTableToDatabaseOperationCallable() {
return stub.moveTableToDatabaseOperationCallable();
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Move a table to another database.
*
* <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 (DataprocMetastoreClient dataprocMetastoreClient = DataprocMetastoreClient.create()) {
* MoveTableToDatabaseRequest request =
* MoveTableToDatabaseRequest.newBuilder()
* .setService(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString())
* .setTableName("tableName-1988717703")
* .setDbName("dbName-1339126743")
* .setDestinationDbName("destinationDbName-2077361705")
* .build();
* ApiFuture<Operation> future =
* dataprocMetastoreClient.moveTableToDatabaseCallable().futureCall(request);
* // Do something.
* Operation response = future.get();
* }
* }</pre>
*/
public final UnaryCallable<MoveTableToDatabaseRequest, Operation> moveTableToDatabaseCallable() {
return stub.moveTableToDatabaseCallable();
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Alter metadata resource location. The metadata resource can be a database, table, or partition.
* This functionality only updates the parent directory for the respective metadata resource and
* does not transfer any existing data to the new location.
*
* <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 (DataprocMetastoreClient dataprocMetastoreClient = DataprocMetastoreClient.create()) {
* AlterMetadataResourceLocationRequest request =
* AlterMetadataResourceLocationRequest.newBuilder()
* .setService(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString())
* .setResourceName("resourceName-384566343")
* .setLocationUri("locationUri552310135")
* .build();
* AlterMetadataResourceLocationResponse response =
* dataprocMetastoreClient.alterMetadataResourceLocationAsync(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<AlterMetadataResourceLocationResponse, OperationMetadata>
alterMetadataResourceLocationAsync(AlterMetadataResourceLocationRequest request) {
return alterMetadataResourceLocationOperationCallable().futureCall(request);
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Alter metadata resource location. The metadata resource can be a database, table, or partition.
* This functionality only updates the parent directory for the respective metadata resource and
* does not transfer any existing data to the new location.
*
* <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 (DataprocMetastoreClient dataprocMetastoreClient = DataprocMetastoreClient.create()) {
* AlterMetadataResourceLocationRequest request =
* AlterMetadataResourceLocationRequest.newBuilder()
* .setService(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString())
* .setResourceName("resourceName-384566343")
* .setLocationUri("locationUri552310135")
* .build();
* OperationFuture<AlterMetadataResourceLocationResponse, OperationMetadata> future =
* dataprocMetastoreClient
* .alterMetadataResourceLocationOperationCallable()
* .futureCall(request);
* // Do something.
* AlterMetadataResourceLocationResponse response = future.get();
* }
* }</pre>
*/
public final OperationCallable<
AlterMetadataResourceLocationRequest,
AlterMetadataResourceLocationResponse,
OperationMetadata>
alterMetadataResourceLocationOperationCallable() {
return stub.alterMetadataResourceLocationOperationCallable();
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Alter metadata resource location. The metadata resource can be a database, table, or partition.
* This functionality only updates the parent directory for the respective metadata resource and
* does not transfer any existing data to the new location.
*
* <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 (DataprocMetastoreClient dataprocMetastoreClient = DataprocMetastoreClient.create()) {
* AlterMetadataResourceLocationRequest request =
* AlterMetadataResourceLocationRequest.newBuilder()
* .setService(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString())
* .setResourceName("resourceName-384566343")
* .setLocationUri("locationUri552310135")
* .build();
* ApiFuture<Operation> future =
* dataprocMetastoreClient.alterMetadataResourceLocationCallable().futureCall(request);
* // Do something.
* Operation response = future.get();
* }
* }</pre>
*/
public final UnaryCallable<AlterMetadataResourceLocationRequest, Operation>
alterMetadataResourceLocationCallable() {
return stub.alterMetadataResourceLocationCallable();
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Lists information about the supported locations for this service.
Expand Down
Loading

0 comments on commit 9cb69a8

Please sign in to comment.