Skip to content

Commit

Permalink
fix(deps): [Many APIs] Update the Java code generator (gapic-generato…
Browse files Browse the repository at this point in the history
…r-java) to 2.32.0 (#10255)

* fix(deps): Update the Java code generator (gapic-generator-java) to 2.32.0

PiperOrigin-RevId: 599914188

Source-Link: googleapis/googleapis@17e6661

Source-Link: googleapis/googleapis-gen@d86ba5b
Copy-Tag: eyJwIjoiamF2YS1zZXJ2aWNlLXVzYWdlLy5Pd2xCb3QueWFtbCIsImgiOiJkODZiYTViZTUzN2U0ODk0MzUxMDVjYTg1NTY2Y2M0MTAzMzAxYWJhIn0=
Copy-Tag: eyJwIjoiamF2YS1zZXJ2aWNlZGlyZWN0b3J5Ly5Pd2xCb3QueWFtbCIsImgiOiJkODZiYTViZTUzN2U0ODk0MzUxMDVjYTg1NTY2Y2M0MTAzMzAxYWJhIn0=
Copy-Tag: eyJwIjoiamF2YS1zaGVsbC8uT3dsQm90LnlhbWwiLCJoIjoiZDg2YmE1YmU1MzdlNDg5NDM1MTA1Y2E4NTU2NmNjNDEwMzMwMWFiYSJ9
Copy-Tag: eyJwIjoiamF2YS1zaG9wcGluZy1jc3MvLk93bEJvdC55YW1sIiwiaCI6ImQ4NmJhNWJlNTM3ZTQ4OTQzNTEwNWNhODU1NjZjYzQxMDMzMDFhYmEifQ==
Copy-Tag: eyJwIjoiamF2YS1zaG9wcGluZy1tZXJjaGFudC1pbnZlbnRvcmllcy8uT3dsQm90LnlhbWwiLCJoIjoiZDg2YmE1YmU1MzdlNDg5NDM1MTA1Y2E4NTU2NmNjNDEwMzMwMWFiYSJ9
Copy-Tag: eyJwIjoiamF2YS1zaG9wcGluZy1tZXJjaGFudC1yZXBvcnRzLy5Pd2xCb3QueWFtbCIsImgiOiJkODZiYTViZTUzN2U0ODk0MzUxMDVjYTg1NTY2Y2M0MTAzMzAxYWJhIn0=
Copy-Tag: eyJwIjoiamF2YS1zcGVlY2gvLk93bEJvdC55YW1sIiwiaCI6ImQ4NmJhNWJlNTM3ZTQ4OTQzNT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C55YW1sIiwiaCI6ImQ4NmJhNWJlNTM3ZTQ4OTQzNTEwNWNhODU1NjZjYzQxMDMzMDFhYmEifQ==
Copy-Tag: eyJwIjoiamF2YS12aWRlby1pbnRlbGxpZ2VuY2UvLk93bEJvdC55YW1sIiwiaCI6ImQ4NmJhNWJlNTM3ZTQ4OTQzNTEwNWNhODU1NjZjYzQxMDMzMDFhYmEifQ==
Copy-Tag: eyJwIjoiamF2YS12aWRlby1saXZlLXN0cmVhbS8uT3dsQm90LnlhbWwiLCJoIjoiZDg2YmE1YmU1MzdlNDg5NDM1MTA1Y2E4NTU2NmNjNDEwMzMwMWFiYSJ9
Copy-Tag: eyJwIjoiamF2YS12aWRlby1zdGl0Y2hlci8uT3dsQm90LnlhbWwiLCJoIjoiZDg2YmE1YmU1MzdlNDg5NDM1MTA1Y2E4NTU2NmNjNDEwMzMwMWFiYSJ9
Copy-Tag: eyJwIjoiamF2YS12aWRlby10cmFuc2NvZGVyLy5Pd2xCb3QueWFtbCIsImgiOiJkODZiYTViZTUzN2U0ODk0MzUxMDVjYTg1NTY2Y2M0MTAzMzAxYWJhIn0=

* 🦉 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

* chore: Remove duplicate google.api classes

---------

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
Co-authored-by: Lawrence Qiu <lawrenceqiu@google.com>
  • Loading branch information
3 people committed Jan 23, 2024
1 parent 667293a commit 67ef0cc
Show file tree
Hide file tree
Showing 131 changed files with 3,577 additions and 2,621 deletions.
2 changes: 1 addition & 1 deletion java-service-usage/README.md
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-service-usage.svg
[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-service-usage/2.32.0
[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-service-usage/2.33.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
Expand Up @@ -64,101 +64,102 @@
* as threads. In the example above, try-with-resources is used, which automatically calls close().
*
* <table>
* <caption>Methods</caption>
* <tr>
* <th>Method</th>
* <th>Description</th>
* <th>Method Variants</th>
* </tr>
* <tr>
* <td>EnableService</td>
* <td><p> EnableService</td>
* <td><p> Enable a service so that it can be used with a project.</td>
* <td>
* <p>Request object method variants only take one parameter, a request object, which must be constructed before the call.</p>
* <ul>
* <li>enableServiceAsync(EnableServiceRequest request)
* <li><p> enableServiceAsync(EnableServiceRequest request)
* </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>enableServiceOperationCallable()
* <li>enableServiceCallable()
* <li><p> enableServiceOperationCallable()
* <li><p> enableServiceCallable()
* </ul>
* </td>
* </tr>
* <tr>
* <td>DisableService</td>
* <td><p> DisableService</td>
* <td><p> Disable a service so that it can no longer be used with a project. This prevents unintended usage that may cause unexpected billing charges or security leaks.
* <p> It is not valid to call the disable method on a service that is not currently enabled. Callers will receive a `FAILED_PRECONDITION` status if the target service is not currently enabled.</td>
* <td>
* <p>Request object method variants only take one parameter, a request object, which must be constructed before the call.</p>
* <ul>
* <li>disableServiceAsync(DisableServiceRequest request)
* <li><p> disableServiceAsync(DisableServiceRequest request)
* </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>disableServiceOperationCallable()
* <li>disableServiceCallable()
* <li><p> disableServiceOperationCallable()
* <li><p> disableServiceCallable()
* </ul>
* </td>
* </tr>
* <tr>
* <td>GetService</td>
* <td><p> GetService</td>
* <td><p> Returns the service configuration and enabled state for a given service.</td>
* <td>
* <p>Request object method variants only take one parameter, a request object, which must be constructed before the call.</p>
* <ul>
* <li>getService(GetServiceRequest request)
* <li><p> getService(GetServiceRequest request)
* </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>getServiceCallable()
* <li><p> getServiceCallable()
* </ul>
* </td>
* </tr>
* <tr>
* <td>ListServices</td>
* <td><p> ListServices</td>
* <td><p> List all services available to the specified project, and the current state of those services with respect to the project. The list includes all public services, all services for which the calling user has the `servicemanagement.services.bind` permission, and all services that have already been enabled on the project. The list can be filtered to only include services in a specific state, for example to only include services enabled on the project.
* <p> WARNING: If you need to query enabled services frequently or across an organization, you should use [Cloud Asset Inventory API](https://cloud.google.com/asset-inventory/docs/apis), which provides higher throughput and richer filtering capability.</td>
* <td>
* <p>Request object method variants only take one parameter, a request object, which must be constructed before the call.</p>
* <ul>
* <li>listServices(ListServicesRequest request)
* <li><p> listServices(ListServicesRequest request)
* </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>listServicesPagedCallable()
* <li>listServicesCallable()
* <li><p> listServicesPagedCallable()
* <li><p> listServicesCallable()
* </ul>
* </td>
* </tr>
* <tr>
* <td>BatchEnableServices</td>
* <td><p> BatchEnableServices</td>
* <td><p> Enable multiple services on a project. The operation is atomic: if enabling any service fails, then the entire batch fails, and no state changes occur. To enable a single service, use the `EnableService` method instead.</td>
* <td>
* <p>Request object method variants only take one parameter, a request object, which must be constructed before the call.</p>
* <ul>
* <li>batchEnableServicesAsync(BatchEnableServicesRequest request)
* <li><p> batchEnableServicesAsync(BatchEnableServicesRequest request)
* </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>batchEnableServicesOperationCallable()
* <li>batchEnableServicesCallable()
* <li><p> batchEnableServicesOperationCallable()
* <li><p> batchEnableServicesCallable()
* </ul>
* </td>
* </tr>
* <tr>
* <td>BatchGetServices</td>
* <td><p> BatchGetServices</td>
* <td><p> Returns the service configurations and enabled states for a given list of services.</td>
* <td>
* <p>Request object method variants only take one parameter, a request object, which must be constructed before the call.</p>
* <ul>
* <li>batchGetServices(BatchGetServicesRequest request)
* <li><p> batchGetServices(BatchGetServicesRequest request)
* </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>batchGetServicesCallable()
* <li><p> batchGetServicesCallable()
* </ul>
* </td>
* </tr>
* </tr>
* </table>
*
* <p>See the individual methods for example code.
Expand Down
Expand Up @@ -257,6 +257,15 @@ public ServiceUsageStub createStub() throws IOException {
"Transport not supported: %s", getTransportChannelProvider().getTransportName()));
}

/** Returns the endpoint set by the user or the the service's default endpoint. */
@Override
public String getEndpoint() {
if (super.getEndpoint() != null) {
return super.getEndpoint();
}
return getDefaultEndpoint();
}

/** Returns the default service name. */
@Override
public String getServiceName() {
Expand Down Expand Up @@ -473,7 +482,6 @@ private static Builder createDefault() {
builder.setTransportChannelProvider(defaultTransportChannelProvider());
builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build());
builder.setInternalHeaderProvider(defaultApiClientHeaderProviderBuilder().build());
builder.setEndpoint(getDefaultEndpoint());
builder.setMtlsEndpoint(getDefaultMtlsEndpoint());
builder.setSwitchToMtlsEndpointAllowed(true);

Expand All @@ -486,7 +494,6 @@ private static Builder createHttpJsonDefault() {
builder.setTransportChannelProvider(defaultHttpJsonTransportProviderBuilder().build());
builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build());
builder.setInternalHeaderProvider(defaultHttpJsonApiClientHeaderProviderBuilder().build());
builder.setEndpoint(getDefaultEndpoint());
builder.setMtlsEndpoint(getDefaultMtlsEndpoint());
builder.setSwitchToMtlsEndpointAllowed(true);

Expand Down Expand Up @@ -676,6 +683,15 @@ public UnaryCallSettings.Builder<GetServiceRequest, Service> getServiceSettings(
return batchGetServicesSettings;
}

/** Returns the endpoint set by the user or the the service's default endpoint. */
@Override
public String getEndpoint() {
if (super.getEndpoint() != null) {
return super.getEndpoint();
}
return getDefaultEndpoint();
}

@Override
public ServiceUsageStubSettings build() throws IOException {
return new ServiceUsageStubSettings(this);
Expand Down

0 comments on commit 67ef0cc

Please sign in to comment.