From 5beedfa50c4ce32b0a25ad4fefa14ff254ecae19 Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Mon, 20 Sep 2021 15:02:10 +0000 Subject: [PATCH] fix: Remove ActivateSpoke and DeactivateSpoke methods (#136) ActivateSpoke and DeactivateSpoke were included in a previous change by mistake feat: Add hub.routing_vpcs field docs: Specify that site_to_site_data_transfer field must be set to true - [x] Regenerate this pull request now. PiperOrigin-RevId: 392500501 Source-Link: https://github.com/googleapis/googleapis/commit/d06d94e541c6405a2f12cc35bb60ecc1a7dfdb52 Source-Link: https://github.com/googleapis/googleapis-gen/commit/b368af0aabeac99dfd7c267950a412e2c1eaca11 --- .../v1/HubServiceClient.java | 242 ----- .../v1/HubServiceSettings.java | 44 - .../v1/gapic_metadata.json | 6 - .../v1/stub/GrpcHubServiceStub.java | 88 -- .../v1/stub/HubServiceStub.java | 20 - .../v1/stub/HubServiceStubSettings.java | 137 --- .../v1/HubServiceClientTest.java | 230 +---- .../v1/MockHubServiceImpl.java | 42 - .../v1/HubServiceGrpc.java | 243 +---- .../v1/ActivateSpokeRequest.java | 910 ----------------- .../v1/ActivateSpokeRequestOrBuilder.java | 101 -- .../v1/DeactivateSpokeRequest.java | 913 ------------------ .../v1/DeactivateSpokeRequestOrBuilder.java | 101 -- .../cloud/networkconnectivity/v1/Hub.java | 594 +++++++++++- .../networkconnectivity/v1/HubOrBuilder.java | 72 ++ .../networkconnectivity/v1/HubProto.java | 398 ++++---- .../v1/LinkedInterconnectAttachments.java | 32 +- ...inkedInterconnectAttachmentsOrBuilder.java | 8 +- .../v1/LinkedRouterApplianceInstances.java | 32 +- ...nkedRouterApplianceInstancesOrBuilder.java | 8 +- .../v1/LinkedVpnTunnels.java | 32 +- .../v1/LinkedVpnTunnelsOrBuilder.java | 8 +- .../v1/OperationMetadata.java | 8 +- .../v1/OperationMetadataOrBuilder.java | 2 +- .../networkconnectivity/v1/RoutingVPC.java | 638 ++++++++++++ .../v1/RoutingVPCOrBuilder.java | 50 + .../cloud/networkconnectivity/v1/common.proto | 2 +- .../cloud/networkconnectivity/v1/hub.proto | 124 +-- 28 files changed, 1609 insertions(+), 3476 deletions(-) delete mode 100644 proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ActivateSpokeRequest.java delete mode 100644 proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ActivateSpokeRequestOrBuilder.java delete mode 100644 proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/DeactivateSpokeRequest.java delete mode 100644 proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/DeactivateSpokeRequestOrBuilder.java create mode 100644 proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/RoutingVPC.java create mode 100644 proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/RoutingVPCOrBuilder.java diff --git a/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceClient.java b/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceClient.java index 507cb25d..b4289363 100644 --- a/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceClient.java +++ b/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceClient.java @@ -1212,248 +1212,6 @@ public final UnaryCallable updateSpokeCallable() return stub.updateSpokeCallable(); } - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Deactivates the specified spoke. Deactivating keeps the spoke information for future - * re-activation, but disconnects the Google Cloud network from non-Google-Cloud network. - * - *

Sample code: - * - *

{@code
-   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
-   *   SpokeName name = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]");
-   *   Spoke response = hubServiceClient.deactivateSpokeAsync(name).get();
-   * }
-   * }
- * - * @param name Required. The name of the spoke to deactivate. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture deactivateSpokeAsync(SpokeName name) { - DeactivateSpokeRequest request = - DeactivateSpokeRequest.newBuilder().setName(name == null ? null : name.toString()).build(); - return deactivateSpokeAsync(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Deactivates the specified spoke. Deactivating keeps the spoke information for future - * re-activation, but disconnects the Google Cloud network from non-Google-Cloud network. - * - *

Sample code: - * - *

{@code
-   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
-   *   String name = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString();
-   *   Spoke response = hubServiceClient.deactivateSpokeAsync(name).get();
-   * }
-   * }
- * - * @param name Required. The name of the spoke to deactivate. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture deactivateSpokeAsync(String name) { - DeactivateSpokeRequest request = DeactivateSpokeRequest.newBuilder().setName(name).build(); - return deactivateSpokeAsync(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Deactivates the specified spoke. Deactivating keeps the spoke information for future - * re-activation, but disconnects the Google Cloud network from non-Google-Cloud network. - * - *

Sample code: - * - *

{@code
-   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
-   *   DeactivateSpokeRequest request =
-   *       DeactivateSpokeRequest.newBuilder()
-   *           .setName(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString())
-   *           .setRequestId("requestId693933066")
-   *           .build();
-   *   Spoke response = hubServiceClient.deactivateSpokeAsync(request).get();
-   * }
-   * }
- * - * @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 deactivateSpokeAsync( - DeactivateSpokeRequest request) { - return deactivateSpokeOperationCallable().futureCall(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Deactivates the specified spoke. Deactivating keeps the spoke information for future - * re-activation, but disconnects the Google Cloud network from non-Google-Cloud network. - * - *

Sample code: - * - *

{@code
-   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
-   *   DeactivateSpokeRequest request =
-   *       DeactivateSpokeRequest.newBuilder()
-   *           .setName(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString())
-   *           .setRequestId("requestId693933066")
-   *           .build();
-   *   OperationFuture future =
-   *       hubServiceClient.deactivateSpokeOperationCallable().futureCall(request);
-   *   // Do something.
-   *   Spoke response = future.get();
-   * }
-   * }
- */ - public final OperationCallable - deactivateSpokeOperationCallable() { - return stub.deactivateSpokeOperationCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Deactivates the specified spoke. Deactivating keeps the spoke information for future - * re-activation, but disconnects the Google Cloud network from non-Google-Cloud network. - * - *

Sample code: - * - *

{@code
-   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
-   *   DeactivateSpokeRequest request =
-   *       DeactivateSpokeRequest.newBuilder()
-   *           .setName(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString())
-   *           .setRequestId("requestId693933066")
-   *           .build();
-   *   ApiFuture future = hubServiceClient.deactivateSpokeCallable().futureCall(request);
-   *   // Do something.
-   *   Operation response = future.get();
-   * }
-   * }
- */ - public final UnaryCallable deactivateSpokeCallable() { - return stub.deactivateSpokeCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Activates the specified spoke. Activating reconnects the Google Cloud network with the - * non-Google-Cloud network. - * - *

Sample code: - * - *

{@code
-   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
-   *   SpokeName name = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]");
-   *   Spoke response = hubServiceClient.activateSpokeAsync(name).get();
-   * }
-   * }
- * - * @param name Required. The name of the spoke to activate. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture activateSpokeAsync(SpokeName name) { - ActivateSpokeRequest request = - ActivateSpokeRequest.newBuilder().setName(name == null ? null : name.toString()).build(); - return activateSpokeAsync(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Activates the specified spoke. Activating reconnects the Google Cloud network with the - * non-Google-Cloud network. - * - *

Sample code: - * - *

{@code
-   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
-   *   String name = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString();
-   *   Spoke response = hubServiceClient.activateSpokeAsync(name).get();
-   * }
-   * }
- * - * @param name Required. The name of the spoke to activate. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture activateSpokeAsync(String name) { - ActivateSpokeRequest request = ActivateSpokeRequest.newBuilder().setName(name).build(); - return activateSpokeAsync(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Activates the specified spoke. Activating reconnects the Google Cloud network with the - * non-Google-Cloud network. - * - *

Sample code: - * - *

{@code
-   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
-   *   ActivateSpokeRequest request =
-   *       ActivateSpokeRequest.newBuilder()
-   *           .setName(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString())
-   *           .setRequestId("requestId693933066")
-   *           .build();
-   *   Spoke response = hubServiceClient.activateSpokeAsync(request).get();
-   * }
-   * }
- * - * @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 activateSpokeAsync( - ActivateSpokeRequest request) { - return activateSpokeOperationCallable().futureCall(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Activates the specified spoke. Activating reconnects the Google Cloud network with the - * non-Google-Cloud network. - * - *

Sample code: - * - *

{@code
-   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
-   *   ActivateSpokeRequest request =
-   *       ActivateSpokeRequest.newBuilder()
-   *           .setName(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString())
-   *           .setRequestId("requestId693933066")
-   *           .build();
-   *   OperationFuture future =
-   *       hubServiceClient.activateSpokeOperationCallable().futureCall(request);
-   *   // Do something.
-   *   Spoke response = future.get();
-   * }
-   * }
- */ - public final OperationCallable - activateSpokeOperationCallable() { - return stub.activateSpokeOperationCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Activates the specified spoke. Activating reconnects the Google Cloud network with the - * non-Google-Cloud network. - * - *

Sample code: - * - *

{@code
-   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
-   *   ActivateSpokeRequest request =
-   *       ActivateSpokeRequest.newBuilder()
-   *           .setName(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString())
-   *           .setRequestId("requestId693933066")
-   *           .build();
-   *   ApiFuture future = hubServiceClient.activateSpokeCallable().futureCall(request);
-   *   // Do something.
-   *   Operation response = future.get();
-   * }
-   * }
- */ - public final UnaryCallable activateSpokeCallable() { - return stub.activateSpokeCallable(); - } - // AUTO-GENERATED DOCUMENTATION AND METHOD. /** * Deletes the specified spoke. diff --git a/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceSettings.java b/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceSettings.java index 798c1e4c..f452d00f 100644 --- a/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceSettings.java +++ b/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceSettings.java @@ -150,28 +150,6 @@ public UnaryCallSettings updateSpokeSettings() { return ((HubServiceStubSettings) getStubSettings()).updateSpokeOperationSettings(); } - /** Returns the object with the settings used for calls to deactivateSpoke. */ - public UnaryCallSettings deactivateSpokeSettings() { - return ((HubServiceStubSettings) getStubSettings()).deactivateSpokeSettings(); - } - - /** Returns the object with the settings used for calls to deactivateSpoke. */ - public OperationCallSettings - deactivateSpokeOperationSettings() { - return ((HubServiceStubSettings) getStubSettings()).deactivateSpokeOperationSettings(); - } - - /** Returns the object with the settings used for calls to activateSpoke. */ - public UnaryCallSettings activateSpokeSettings() { - return ((HubServiceStubSettings) getStubSettings()).activateSpokeSettings(); - } - - /** Returns the object with the settings used for calls to activateSpoke. */ - public OperationCallSettings - activateSpokeOperationSettings() { - return ((HubServiceStubSettings) getStubSettings()).activateSpokeOperationSettings(); - } - /** Returns the object with the settings used for calls to deleteSpoke. */ public UnaryCallSettings deleteSpokeSettings() { return ((HubServiceStubSettings) getStubSettings()).deleteSpokeSettings(); @@ -356,28 +334,6 @@ public UnaryCallSettings.Builder updateSpokeSetti return getStubSettingsBuilder().updateSpokeOperationSettings(); } - /** Returns the builder for the settings used for calls to deactivateSpoke. */ - public UnaryCallSettings.Builder deactivateSpokeSettings() { - return getStubSettingsBuilder().deactivateSpokeSettings(); - } - - /** Returns the builder for the settings used for calls to deactivateSpoke. */ - public OperationCallSettings.Builder - deactivateSpokeOperationSettings() { - return getStubSettingsBuilder().deactivateSpokeOperationSettings(); - } - - /** Returns the builder for the settings used for calls to activateSpoke. */ - public UnaryCallSettings.Builder activateSpokeSettings() { - return getStubSettingsBuilder().activateSpokeSettings(); - } - - /** Returns the builder for the settings used for calls to activateSpoke. */ - public OperationCallSettings.Builder - activateSpokeOperationSettings() { - return getStubSettingsBuilder().activateSpokeOperationSettings(); - } - /** Returns the builder for the settings used for calls to deleteSpoke. */ public UnaryCallSettings.Builder deleteSpokeSettings() { return getStubSettingsBuilder().deleteSpokeSettings(); diff --git a/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/gapic_metadata.json b/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/gapic_metadata.json index e67aa4c4..466ca637 100644 --- a/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/gapic_metadata.json +++ b/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/gapic_metadata.json @@ -10,18 +10,12 @@ "grpc": { "libraryClient": "HubServiceClient", "rpcs": { - "ActivateSpoke": { - "methods": ["activateSpokeAsync", "activateSpokeAsync", "activateSpokeAsync", "activateSpokeOperationCallable", "activateSpokeCallable"] - }, "CreateHub": { "methods": ["createHubAsync", "createHubAsync", "createHubAsync", "createHubOperationCallable", "createHubCallable"] }, "CreateSpoke": { "methods": ["createSpokeAsync", "createSpokeAsync", "createSpokeAsync", "createSpokeOperationCallable", "createSpokeCallable"] }, - "DeactivateSpoke": { - "methods": ["deactivateSpokeAsync", "deactivateSpokeAsync", "deactivateSpokeAsync", "deactivateSpokeOperationCallable", "deactivateSpokeCallable"] - }, "DeleteHub": { "methods": ["deleteHubAsync", "deleteHubAsync", "deleteHubAsync", "deleteHubOperationCallable", "deleteHubCallable"] }, diff --git a/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/GrpcHubServiceStub.java b/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/GrpcHubServiceStub.java index 60e388c5..b3673309 100644 --- a/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/GrpcHubServiceStub.java +++ b/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/GrpcHubServiceStub.java @@ -26,10 +26,8 @@ import com.google.api.gax.rpc.ClientContext; import com.google.api.gax.rpc.OperationCallable; import com.google.api.gax.rpc.UnaryCallable; -import com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest; import com.google.cloud.networkconnectivity.v1.CreateHubRequest; import com.google.cloud.networkconnectivity.v1.CreateSpokeRequest; -import com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest; import com.google.cloud.networkconnectivity.v1.DeleteHubRequest; import com.google.cloud.networkconnectivity.v1.DeleteSpokeRequest; import com.google.cloud.networkconnectivity.v1.GetHubRequest; @@ -135,26 +133,6 @@ public class GrpcHubServiceStub extends HubServiceStub { .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) .build(); - private static final MethodDescriptor - deactivateSpokeMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.cloud.networkconnectivity.v1.HubService/DeactivateSpoke") - .setRequestMarshaller( - ProtoUtils.marshaller(DeactivateSpokeRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) - .build(); - - private static final MethodDescriptor - activateSpokeMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.cloud.networkconnectivity.v1.HubService/ActivateSpoke") - .setRequestMarshaller( - ProtoUtils.marshaller(ActivateSpokeRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) - .build(); - private static final MethodDescriptor deleteSpokeMethodDescriptor = MethodDescriptor.newBuilder() .setType(MethodDescriptor.MethodType.UNARY) @@ -184,12 +162,6 @@ public class GrpcHubServiceStub extends HubServiceStub { private final UnaryCallable updateSpokeCallable; private final OperationCallable updateSpokeOperationCallable; - private final UnaryCallable deactivateSpokeCallable; - private final OperationCallable - deactivateSpokeOperationCallable; - private final UnaryCallable activateSpokeCallable; - private final OperationCallable - activateSpokeOperationCallable; private final UnaryCallable deleteSpokeCallable; private final OperationCallable deleteSpokeOperationCallable; @@ -326,26 +298,6 @@ protected GrpcHubServiceStub( return params.build(); }) .build(); - GrpcCallSettings deactivateSpokeTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(deactivateSpokeMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - return params.build(); - }) - .build(); - GrpcCallSettings activateSpokeTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(activateSpokeMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - return params.build(); - }) - .build(); GrpcCallSettings deleteSpokeTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(deleteSpokeMethodDescriptor) @@ -420,24 +372,6 @@ protected GrpcHubServiceStub( settings.updateSpokeOperationSettings(), clientContext, operationsStub); - this.deactivateSpokeCallable = - callableFactory.createUnaryCallable( - deactivateSpokeTransportSettings, settings.deactivateSpokeSettings(), clientContext); - this.deactivateSpokeOperationCallable = - callableFactory.createOperationCallable( - deactivateSpokeTransportSettings, - settings.deactivateSpokeOperationSettings(), - clientContext, - operationsStub); - this.activateSpokeCallable = - callableFactory.createUnaryCallable( - activateSpokeTransportSettings, settings.activateSpokeSettings(), clientContext); - this.activateSpokeOperationCallable = - callableFactory.createOperationCallable( - activateSpokeTransportSettings, - settings.activateSpokeOperationSettings(), - clientContext, - operationsStub); this.deleteSpokeCallable = callableFactory.createUnaryCallable( deleteSpokeTransportSettings, settings.deleteSpokeSettings(), clientContext); @@ -539,28 +473,6 @@ public UnaryCallable updateSpokeCallable() { return updateSpokeOperationCallable; } - @Override - public UnaryCallable deactivateSpokeCallable() { - return deactivateSpokeCallable; - } - - @Override - public OperationCallable - deactivateSpokeOperationCallable() { - return deactivateSpokeOperationCallable; - } - - @Override - public UnaryCallable activateSpokeCallable() { - return activateSpokeCallable; - } - - @Override - public OperationCallable - activateSpokeOperationCallable() { - return activateSpokeOperationCallable; - } - @Override public UnaryCallable deleteSpokeCallable() { return deleteSpokeCallable; diff --git a/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/HubServiceStub.java b/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/HubServiceStub.java index 860d4c79..3d47c728 100644 --- a/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/HubServiceStub.java +++ b/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/HubServiceStub.java @@ -22,10 +22,8 @@ import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.rpc.OperationCallable; import com.google.api.gax.rpc.UnaryCallable; -import com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest; import com.google.cloud.networkconnectivity.v1.CreateHubRequest; import com.google.cloud.networkconnectivity.v1.CreateSpokeRequest; -import com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest; import com.google.cloud.networkconnectivity.v1.DeleteHubRequest; import com.google.cloud.networkconnectivity.v1.DeleteSpokeRequest; import com.google.cloud.networkconnectivity.v1.GetHubRequest; @@ -124,24 +122,6 @@ public UnaryCallable updateSpokeCallable() { throw new UnsupportedOperationException("Not implemented: updateSpokeCallable()"); } - public OperationCallable - deactivateSpokeOperationCallable() { - throw new UnsupportedOperationException("Not implemented: deactivateSpokeOperationCallable()"); - } - - public UnaryCallable deactivateSpokeCallable() { - throw new UnsupportedOperationException("Not implemented: deactivateSpokeCallable()"); - } - - public OperationCallable - activateSpokeOperationCallable() { - throw new UnsupportedOperationException("Not implemented: activateSpokeOperationCallable()"); - } - - public UnaryCallable activateSpokeCallable() { - throw new UnsupportedOperationException("Not implemented: activateSpokeCallable()"); - } - public OperationCallable deleteSpokeOperationCallable() { throw new UnsupportedOperationException("Not implemented: deleteSpokeOperationCallable()"); diff --git a/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/HubServiceStubSettings.java b/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/HubServiceStubSettings.java index 4939354c..2047e0e6 100644 --- a/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/HubServiceStubSettings.java +++ b/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/HubServiceStubSettings.java @@ -45,10 +45,8 @@ import com.google.api.gax.rpc.TransportChannelProvider; import com.google.api.gax.rpc.UnaryCallSettings; import com.google.api.gax.rpc.UnaryCallable; -import com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest; import com.google.cloud.networkconnectivity.v1.CreateHubRequest; import com.google.cloud.networkconnectivity.v1.CreateSpokeRequest; -import com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest; import com.google.cloud.networkconnectivity.v1.DeleteHubRequest; import com.google.cloud.networkconnectivity.v1.DeleteSpokeRequest; import com.google.cloud.networkconnectivity.v1.GetHubRequest; @@ -132,12 +130,6 @@ public class HubServiceStubSettings extends StubSettings private final UnaryCallSettings updateSpokeSettings; private final OperationCallSettings updateSpokeOperationSettings; - private final UnaryCallSettings deactivateSpokeSettings; - private final OperationCallSettings - deactivateSpokeOperationSettings; - private final UnaryCallSettings activateSpokeSettings; - private final OperationCallSettings - activateSpokeOperationSettings; private final UnaryCallSettings deleteSpokeSettings; private final OperationCallSettings deleteSpokeOperationSettings; @@ -324,28 +316,6 @@ public UnaryCallSettings updateSpokeSettings() { return updateSpokeOperationSettings; } - /** Returns the object with the settings used for calls to deactivateSpoke. */ - public UnaryCallSettings deactivateSpokeSettings() { - return deactivateSpokeSettings; - } - - /** Returns the object with the settings used for calls to deactivateSpoke. */ - public OperationCallSettings - deactivateSpokeOperationSettings() { - return deactivateSpokeOperationSettings; - } - - /** Returns the object with the settings used for calls to activateSpoke. */ - public UnaryCallSettings activateSpokeSettings() { - return activateSpokeSettings; - } - - /** Returns the object with the settings used for calls to activateSpoke. */ - public OperationCallSettings - activateSpokeOperationSettings() { - return activateSpokeOperationSettings; - } - /** Returns the object with the settings used for calls to deleteSpoke. */ public UnaryCallSettings deleteSpokeSettings() { return deleteSpokeSettings; @@ -447,10 +417,6 @@ protected HubServiceStubSettings(Builder settingsBuilder) throws IOException { createSpokeOperationSettings = settingsBuilder.createSpokeOperationSettings().build(); updateSpokeSettings = settingsBuilder.updateSpokeSettings().build(); updateSpokeOperationSettings = settingsBuilder.updateSpokeOperationSettings().build(); - deactivateSpokeSettings = settingsBuilder.deactivateSpokeSettings().build(); - deactivateSpokeOperationSettings = settingsBuilder.deactivateSpokeOperationSettings().build(); - activateSpokeSettings = settingsBuilder.activateSpokeSettings().build(); - activateSpokeOperationSettings = settingsBuilder.activateSpokeOperationSettings().build(); deleteSpokeSettings = settingsBuilder.deleteSpokeSettings().build(); deleteSpokeOperationSettings = settingsBuilder.deleteSpokeOperationSettings().build(); } @@ -481,13 +447,6 @@ public static class Builder extends StubSettings.Builder updateSpokeSettings; private final OperationCallSettings.Builder updateSpokeOperationSettings; - private final UnaryCallSettings.Builder - deactivateSpokeSettings; - private final OperationCallSettings.Builder - deactivateSpokeOperationSettings; - private final UnaryCallSettings.Builder activateSpokeSettings; - private final OperationCallSettings.Builder - activateSpokeOperationSettings; private final UnaryCallSettings.Builder deleteSpokeSettings; private final OperationCallSettings.Builder deleteSpokeOperationSettings; @@ -553,10 +512,6 @@ protected Builder(ClientContext clientContext) { createSpokeOperationSettings = OperationCallSettings.newBuilder(); updateSpokeSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); updateSpokeOperationSettings = OperationCallSettings.newBuilder(); - deactivateSpokeSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - deactivateSpokeOperationSettings = OperationCallSettings.newBuilder(); - activateSpokeSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - activateSpokeOperationSettings = OperationCallSettings.newBuilder(); deleteSpokeSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); deleteSpokeOperationSettings = OperationCallSettings.newBuilder(); @@ -571,8 +526,6 @@ protected Builder(ClientContext clientContext) { getSpokeSettings, createSpokeSettings, updateSpokeSettings, - deactivateSpokeSettings, - activateSpokeSettings, deleteSpokeSettings); initDefaults(this); } @@ -594,10 +547,6 @@ protected Builder(HubServiceStubSettings settings) { createSpokeOperationSettings = settings.createSpokeOperationSettings.toBuilder(); updateSpokeSettings = settings.updateSpokeSettings.toBuilder(); updateSpokeOperationSettings = settings.updateSpokeOperationSettings.toBuilder(); - deactivateSpokeSettings = settings.deactivateSpokeSettings.toBuilder(); - deactivateSpokeOperationSettings = settings.deactivateSpokeOperationSettings.toBuilder(); - activateSpokeSettings = settings.activateSpokeSettings.toBuilder(); - activateSpokeOperationSettings = settings.activateSpokeOperationSettings.toBuilder(); deleteSpokeSettings = settings.deleteSpokeSettings.toBuilder(); deleteSpokeOperationSettings = settings.deleteSpokeOperationSettings.toBuilder(); @@ -612,8 +561,6 @@ protected Builder(HubServiceStubSettings settings) { getSpokeSettings, createSpokeSettings, updateSpokeSettings, - deactivateSpokeSettings, - activateSpokeSettings, deleteSpokeSettings); } @@ -676,16 +623,6 @@ private static Builder initDefaults(Builder builder) { .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); - builder - .deactivateSpokeSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); - - builder - .activateSpokeSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); - builder .deleteSpokeSettings() .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) @@ -804,54 +741,6 @@ private static Builder initDefaults(Builder builder) { .setTotalTimeout(Duration.ofMillis(300000L)) .build())); - builder - .deactivateSpokeOperationSettings() - .setInitialCallSettings( - UnaryCallSettings - .newUnaryCallSettingsBuilder() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")) - .build()) - .setResponseTransformer( - ProtoOperationTransformers.ResponseTransformer.create(Spoke.class)) - .setMetadataTransformer( - ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) - .setPollingAlgorithm( - OperationTimedPollAlgorithm.create( - RetrySettings.newBuilder() - .setInitialRetryDelay(Duration.ofMillis(5000L)) - .setRetryDelayMultiplier(1.5) - .setMaxRetryDelay(Duration.ofMillis(45000L)) - .setInitialRpcTimeout(Duration.ZERO) - .setRpcTimeoutMultiplier(1.0) - .setMaxRpcTimeout(Duration.ZERO) - .setTotalTimeout(Duration.ofMillis(300000L)) - .build())); - - builder - .activateSpokeOperationSettings() - .setInitialCallSettings( - UnaryCallSettings - .newUnaryCallSettingsBuilder() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")) - .build()) - .setResponseTransformer( - ProtoOperationTransformers.ResponseTransformer.create(Spoke.class)) - .setMetadataTransformer( - ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) - .setPollingAlgorithm( - OperationTimedPollAlgorithm.create( - RetrySettings.newBuilder() - .setInitialRetryDelay(Duration.ofMillis(5000L)) - .setRetryDelayMultiplier(1.5) - .setMaxRetryDelay(Duration.ofMillis(45000L)) - .setInitialRpcTimeout(Duration.ZERO) - .setRpcTimeoutMultiplier(1.0) - .setMaxRpcTimeout(Duration.ZERO) - .setTotalTimeout(Duration.ofMillis(300000L)) - .build())); - builder .deleteSpokeOperationSettings() .setInitialCallSettings( @@ -980,32 +869,6 @@ public UnaryCallSettings.Builder updateSpokeSetti return updateSpokeOperationSettings; } - /** Returns the builder for the settings used for calls to deactivateSpoke. */ - public UnaryCallSettings.Builder deactivateSpokeSettings() { - return deactivateSpokeSettings; - } - - /** Returns the builder for the settings used for calls to deactivateSpoke. */ - @BetaApi( - "The surface for use by generated code is not stable yet and may change in the future.") - public OperationCallSettings.Builder - deactivateSpokeOperationSettings() { - return deactivateSpokeOperationSettings; - } - - /** Returns the builder for the settings used for calls to activateSpoke. */ - public UnaryCallSettings.Builder activateSpokeSettings() { - return activateSpokeSettings; - } - - /** Returns the builder for the settings used for calls to activateSpoke. */ - @BetaApi( - "The surface for use by generated code is not stable yet and may change in the future.") - public OperationCallSettings.Builder - activateSpokeOperationSettings() { - return activateSpokeOperationSettings; - } - /** Returns the builder for the settings used for calls to deleteSpoke. */ public UnaryCallSettings.Builder deleteSpokeSettings() { return deleteSpokeSettings; diff --git a/google-cloud-networkconnectivity/src/test/java/com/google/cloud/networkconnectivity/v1/HubServiceClientTest.java b/google-cloud-networkconnectivity/src/test/java/com/google/cloud/networkconnectivity/v1/HubServiceClientTest.java index 63ee2fb9..82d2c3b3 100644 --- a/google-cloud-networkconnectivity/src/test/java/com/google/cloud/networkconnectivity/v1/HubServiceClientTest.java +++ b/google-cloud-networkconnectivity/src/test/java/com/google/cloud/networkconnectivity/v1/HubServiceClientTest.java @@ -36,6 +36,7 @@ import com.google.protobuf.Timestamp; import io.grpc.StatusRuntimeException; import java.io.IOException; +import java.util.ArrayList; import java.util.Arrays; import java.util.HashMap; import java.util.List; @@ -186,6 +187,7 @@ public void getHubTest() throws Exception { .setDescription("description-1724546052") .setUniqueId("uniqueId-294460212") .setState(State.forNumber(0)) + .addAllRoutingVpcs(new ArrayList()) .build(); mockHubService.addResponse(expectedResponse); @@ -230,6 +232,7 @@ public void getHubTest2() throws Exception { .setDescription("description-1724546052") .setUniqueId("uniqueId-294460212") .setState(State.forNumber(0)) + .addAllRoutingVpcs(new ArrayList()) .build(); mockHubService.addResponse(expectedResponse); @@ -274,6 +277,7 @@ public void createHubTest() throws Exception { .setDescription("description-1724546052") .setUniqueId("uniqueId-294460212") .setState(State.forNumber(0)) + .addAllRoutingVpcs(new ArrayList()) .build(); Operation resultOperation = Operation.newBuilder() @@ -332,6 +336,7 @@ public void createHubTest2() throws Exception { .setDescription("description-1724546052") .setUniqueId("uniqueId-294460212") .setState(State.forNumber(0)) + .addAllRoutingVpcs(new ArrayList()) .build(); Operation resultOperation = Operation.newBuilder() @@ -390,6 +395,7 @@ public void updateHubTest() throws Exception { .setDescription("description-1724546052") .setUniqueId("uniqueId-294460212") .setState(State.forNumber(0)) + .addAllRoutingVpcs(new ArrayList()) .build(); Operation resultOperation = Operation.newBuilder() @@ -885,230 +891,6 @@ public void updateSpokeExceptionTest() throws Exception { } } - @Test - public void deactivateSpokeTest() throws Exception { - Spoke expectedResponse = - Spoke.newBuilder() - .setName(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString()) - .setCreateTime(Timestamp.newBuilder().build()) - .setUpdateTime(Timestamp.newBuilder().build()) - .putAllLabels(new HashMap()) - .setDescription("description-1724546052") - .setHub(HubName.of("[PROJECT]", "[HUB]").toString()) - .setLinkedVpnTunnels(LinkedVpnTunnels.newBuilder().build()) - .setLinkedInterconnectAttachments(LinkedInterconnectAttachments.newBuilder().build()) - .setLinkedRouterApplianceInstances(LinkedRouterApplianceInstances.newBuilder().build()) - .setUniqueId("uniqueId-294460212") - .setState(State.forNumber(0)) - .build(); - Operation resultOperation = - Operation.newBuilder() - .setName("deactivateSpokeTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockHubService.addResponse(resultOperation); - - SpokeName name = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]"); - - Spoke actualResponse = client.deactivateSpokeAsync(name).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockHubService.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - DeactivateSpokeRequest actualRequest = ((DeactivateSpokeRequest) actualRequests.get(0)); - - Assert.assertEquals(name.toString(), actualRequest.getName()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void deactivateSpokeExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockHubService.addException(exception); - - try { - SpokeName name = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]"); - client.deactivateSpokeAsync(name).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); - InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); - Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); - } - } - - @Test - public void deactivateSpokeTest2() throws Exception { - Spoke expectedResponse = - Spoke.newBuilder() - .setName(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString()) - .setCreateTime(Timestamp.newBuilder().build()) - .setUpdateTime(Timestamp.newBuilder().build()) - .putAllLabels(new HashMap()) - .setDescription("description-1724546052") - .setHub(HubName.of("[PROJECT]", "[HUB]").toString()) - .setLinkedVpnTunnels(LinkedVpnTunnels.newBuilder().build()) - .setLinkedInterconnectAttachments(LinkedInterconnectAttachments.newBuilder().build()) - .setLinkedRouterApplianceInstances(LinkedRouterApplianceInstances.newBuilder().build()) - .setUniqueId("uniqueId-294460212") - .setState(State.forNumber(0)) - .build(); - Operation resultOperation = - Operation.newBuilder() - .setName("deactivateSpokeTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockHubService.addResponse(resultOperation); - - String name = "name3373707"; - - Spoke actualResponse = client.deactivateSpokeAsync(name).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockHubService.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - DeactivateSpokeRequest actualRequest = ((DeactivateSpokeRequest) actualRequests.get(0)); - - Assert.assertEquals(name, actualRequest.getName()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void deactivateSpokeExceptionTest2() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockHubService.addException(exception); - - try { - String name = "name3373707"; - client.deactivateSpokeAsync(name).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); - InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); - Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); - } - } - - @Test - public void activateSpokeTest() throws Exception { - Spoke expectedResponse = - Spoke.newBuilder() - .setName(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString()) - .setCreateTime(Timestamp.newBuilder().build()) - .setUpdateTime(Timestamp.newBuilder().build()) - .putAllLabels(new HashMap()) - .setDescription("description-1724546052") - .setHub(HubName.of("[PROJECT]", "[HUB]").toString()) - .setLinkedVpnTunnels(LinkedVpnTunnels.newBuilder().build()) - .setLinkedInterconnectAttachments(LinkedInterconnectAttachments.newBuilder().build()) - .setLinkedRouterApplianceInstances(LinkedRouterApplianceInstances.newBuilder().build()) - .setUniqueId("uniqueId-294460212") - .setState(State.forNumber(0)) - .build(); - Operation resultOperation = - Operation.newBuilder() - .setName("activateSpokeTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockHubService.addResponse(resultOperation); - - SpokeName name = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]"); - - Spoke actualResponse = client.activateSpokeAsync(name).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockHubService.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - ActivateSpokeRequest actualRequest = ((ActivateSpokeRequest) actualRequests.get(0)); - - Assert.assertEquals(name.toString(), actualRequest.getName()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void activateSpokeExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockHubService.addException(exception); - - try { - SpokeName name = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]"); - client.activateSpokeAsync(name).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); - InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); - Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); - } - } - - @Test - public void activateSpokeTest2() throws Exception { - Spoke expectedResponse = - Spoke.newBuilder() - .setName(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString()) - .setCreateTime(Timestamp.newBuilder().build()) - .setUpdateTime(Timestamp.newBuilder().build()) - .putAllLabels(new HashMap()) - .setDescription("description-1724546052") - .setHub(HubName.of("[PROJECT]", "[HUB]").toString()) - .setLinkedVpnTunnels(LinkedVpnTunnels.newBuilder().build()) - .setLinkedInterconnectAttachments(LinkedInterconnectAttachments.newBuilder().build()) - .setLinkedRouterApplianceInstances(LinkedRouterApplianceInstances.newBuilder().build()) - .setUniqueId("uniqueId-294460212") - .setState(State.forNumber(0)) - .build(); - Operation resultOperation = - Operation.newBuilder() - .setName("activateSpokeTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockHubService.addResponse(resultOperation); - - String name = "name3373707"; - - Spoke actualResponse = client.activateSpokeAsync(name).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockHubService.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - ActivateSpokeRequest actualRequest = ((ActivateSpokeRequest) actualRequests.get(0)); - - Assert.assertEquals(name, actualRequest.getName()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void activateSpokeExceptionTest2() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockHubService.addException(exception); - - try { - String name = "name3373707"; - client.activateSpokeAsync(name).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); - InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); - Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); - } - } - @Test public void deleteSpokeTest() throws Exception { Empty expectedResponse = Empty.newBuilder().build(); diff --git a/google-cloud-networkconnectivity/src/test/java/com/google/cloud/networkconnectivity/v1/MockHubServiceImpl.java b/google-cloud-networkconnectivity/src/test/java/com/google/cloud/networkconnectivity/v1/MockHubServiceImpl.java index 00d0c367..737726c5 100644 --- a/google-cloud-networkconnectivity/src/test/java/com/google/cloud/networkconnectivity/v1/MockHubServiceImpl.java +++ b/google-cloud-networkconnectivity/src/test/java/com/google/cloud/networkconnectivity/v1/MockHubServiceImpl.java @@ -240,48 +240,6 @@ public void updateSpoke(UpdateSpokeRequest request, StreamObserver re } } - @Override - public void deactivateSpoke( - DeactivateSpokeRequest request, StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof Operation) { - requests.add(request); - responseObserver.onNext(((Operation) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method DeactivateSpoke, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - Operation.class.getName(), - Exception.class.getName()))); - } - } - - @Override - public void activateSpoke( - ActivateSpokeRequest request, StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof Operation) { - requests.add(request); - responseObserver.onNext(((Operation) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method ActivateSpoke, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - Operation.class.getName(), - Exception.class.getName()))); - } - } - @Override public void deleteSpoke(DeleteSpokeRequest request, StreamObserver responseObserver) { Object response = responses.poll(); diff --git a/grpc-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceGrpc.java b/grpc-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceGrpc.java index 8f0b2846..b48ef1f3 100644 --- a/grpc-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceGrpc.java +++ b/grpc-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceGrpc.java @@ -443,97 +443,6 @@ private HubServiceGrpc() {} return getUpdateSpokeMethod; } - private static volatile io.grpc.MethodDescriptor< - com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest, - com.google.longrunning.Operation> - getDeactivateSpokeMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "DeactivateSpoke", - requestType = com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest.class, - responseType = com.google.longrunning.Operation.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest, - com.google.longrunning.Operation> - getDeactivateSpokeMethod() { - io.grpc.MethodDescriptor< - com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest, - com.google.longrunning.Operation> - getDeactivateSpokeMethod; - if ((getDeactivateSpokeMethod = HubServiceGrpc.getDeactivateSpokeMethod) == null) { - synchronized (HubServiceGrpc.class) { - if ((getDeactivateSpokeMethod = HubServiceGrpc.getDeactivateSpokeMethod) == null) { - HubServiceGrpc.getDeactivateSpokeMethod = - getDeactivateSpokeMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeactivateSpoke")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest - .getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor( - new HubServiceMethodDescriptorSupplier("DeactivateSpoke")) - .build(); - } - } - } - return getDeactivateSpokeMethod; - } - - private static volatile io.grpc.MethodDescriptor< - com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest, - com.google.longrunning.Operation> - getActivateSpokeMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "ActivateSpoke", - requestType = com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest.class, - responseType = com.google.longrunning.Operation.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest, - com.google.longrunning.Operation> - getActivateSpokeMethod() { - io.grpc.MethodDescriptor< - com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest, - com.google.longrunning.Operation> - getActivateSpokeMethod; - if ((getActivateSpokeMethod = HubServiceGrpc.getActivateSpokeMethod) == null) { - synchronized (HubServiceGrpc.class) { - if ((getActivateSpokeMethod = HubServiceGrpc.getActivateSpokeMethod) == null) { - HubServiceGrpc.getActivateSpokeMethod = - getActivateSpokeMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ActivateSpoke")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest - .getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor(new HubServiceMethodDescriptorSupplier("ActivateSpoke")) - .build(); - } - } - } - return getActivateSpokeMethod; - } - private static volatile io.grpc.MethodDescriptor< com.google.cloud.networkconnectivity.v1.DeleteSpokeRequest, com.google.longrunning.Operation> @@ -752,37 +661,6 @@ public void updateSpoke( getUpdateSpokeMethod(), responseObserver); } - /** - * - * - *
-     * Deactivates the specified spoke. Deactivating keeps the spoke information
-     * for future re-activation, but disconnects the Google Cloud network from
-     * non-Google-Cloud network.
-     * 
- */ - public void deactivateSpoke( - com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getDeactivateSpokeMethod(), responseObserver); - } - - /** - * - * - *
-     * Activates the specified spoke. Activating reconnects the Google Cloud
-     * network with the non-Google-Cloud network.
-     * 
- */ - public void activateSpoke( - com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getActivateSpokeMethod(), responseObserver); - } - /** * * @@ -856,18 +734,6 @@ public final io.grpc.ServerServiceDefinition bindService() { new MethodHandlers< com.google.cloud.networkconnectivity.v1.UpdateSpokeRequest, com.google.longrunning.Operation>(this, METHODID_UPDATE_SPOKE))) - .addMethod( - getDeactivateSpokeMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest, - com.google.longrunning.Operation>(this, METHODID_DEACTIVATE_SPOKE))) - .addMethod( - getActivateSpokeMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest, - com.google.longrunning.Operation>(this, METHODID_ACTIVATE_SPOKE))) .addMethod( getDeleteSpokeMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( @@ -1030,41 +896,6 @@ public void updateSpoke( responseObserver); } - /** - * - * - *
-     * Deactivates the specified spoke. Deactivating keeps the spoke information
-     * for future re-activation, but disconnects the Google Cloud network from
-     * non-Google-Cloud network.
-     * 
- */ - public void deactivateSpoke( - com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getDeactivateSpokeMethod(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Activates the specified spoke. Activating reconnects the Google Cloud
-     * network with the non-Google-Cloud network.
-     * 
- */ - public void activateSpoke( - com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getActivateSpokeMethod(), getCallOptions()), - request, - responseObserver); - } - /** * * @@ -1220,35 +1051,6 @@ public com.google.longrunning.Operation updateSpoke( getChannel(), getUpdateSpokeMethod(), getCallOptions(), request); } - /** - * - * - *
-     * Deactivates the specified spoke. Deactivating keeps the spoke information
-     * for future re-activation, but disconnects the Google Cloud network from
-     * non-Google-Cloud network.
-     * 
- */ - public com.google.longrunning.Operation deactivateSpoke( - com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getDeactivateSpokeMethod(), getCallOptions(), request); - } - - /** - * - * - *
-     * Activates the specified spoke. Activating reconnects the Google Cloud
-     * network with the non-Google-Cloud network.
-     * 
- */ - public com.google.longrunning.Operation activateSpoke( - com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getActivateSpokeMethod(), getCallOptions(), request); - } - /** * * @@ -1404,35 +1206,6 @@ protected HubServiceFutureStub build(io.grpc.Channel channel, io.grpc.CallOption getChannel().newCall(getUpdateSpokeMethod(), getCallOptions()), request); } - /** - * - * - *
-     * Deactivates the specified spoke. Deactivating keeps the spoke information
-     * for future re-activation, but disconnects the Google Cloud network from
-     * non-Google-Cloud network.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - deactivateSpoke(com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getDeactivateSpokeMethod(), getCallOptions()), request); - } - - /** - * - * - *
-     * Activates the specified spoke. Activating reconnects the Google Cloud
-     * network with the non-Google-Cloud network.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - activateSpoke(com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getActivateSpokeMethod(), getCallOptions()), request); - } - /** * * @@ -1456,9 +1229,7 @@ protected HubServiceFutureStub build(io.grpc.Channel channel, io.grpc.CallOption private static final int METHODID_GET_SPOKE = 6; private static final int METHODID_CREATE_SPOKE = 7; private static final int METHODID_UPDATE_SPOKE = 8; - private static final int METHODID_DEACTIVATE_SPOKE = 9; - private static final int METHODID_ACTIVATE_SPOKE = 10; - private static final int METHODID_DELETE_SPOKE = 11; + private static final int METHODID_DELETE_SPOKE = 9; private static final class MethodHandlers implements io.grpc.stub.ServerCalls.UnaryMethod, @@ -1528,16 +1299,6 @@ public void invoke(Req request, io.grpc.stub.StreamObserver responseObserv (com.google.cloud.networkconnectivity.v1.UpdateSpokeRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; - case METHODID_DEACTIVATE_SPOKE: - serviceImpl.deactivateSpoke( - (com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_ACTIVATE_SPOKE: - serviceImpl.activateSpoke( - (com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; case METHODID_DELETE_SPOKE: serviceImpl.deleteSpoke( (com.google.cloud.networkconnectivity.v1.DeleteSpokeRequest) request, @@ -1616,8 +1377,6 @@ public static io.grpc.ServiceDescriptor getServiceDescriptor() { .addMethod(getGetSpokeMethod()) .addMethod(getCreateSpokeMethod()) .addMethod(getUpdateSpokeMethod()) - .addMethod(getDeactivateSpokeMethod()) - .addMethod(getActivateSpokeMethod()) .addMethod(getDeleteSpokeMethod()) .build(); } diff --git a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ActivateSpokeRequest.java b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ActivateSpokeRequest.java deleted file mode 100644 index ee3a9075..00000000 --- a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ActivateSpokeRequest.java +++ /dev/null @@ -1,910 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/cloud/networkconnectivity/v1/hub.proto - -package com.google.cloud.networkconnectivity.v1; - -/** - * - * - *
- * The request for [HubService.ActivateSpoke][google.cloud.networkconnectivity.v1.HubService.ActivateSpoke].
- * 
- * - * Protobuf type {@code google.cloud.networkconnectivity.v1.ActivateSpokeRequest} - */ -public final class ActivateSpokeRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.networkconnectivity.v1.ActivateSpokeRequest) - ActivateSpokeRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use ActivateSpokeRequest.newBuilder() to construct. - private ActivateSpokeRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ActivateSpokeRequest() { - name_ = ""; - requestId_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ActivateSpokeRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private ActivateSpokeRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - requestId_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_ActivateSpokeRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_ActivateSpokeRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest.class, - com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * Required. The name of the spoke to activate.
-   * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * Required. The name of the spoke to activate.
-   * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int REQUEST_ID_FIELD_NUMBER = 2; - private volatile java.lang.Object requestId_; - /** - * - * - *
-   * Optional. A unique request ID (optional). If you specify this ID, you can use it
-   * in cases when you need to retry your request. When you need to retry, this
-   * ID lets the server know that it can ignore the request if it has already
-   * been completed. The server guarantees that for at least 60 minutes after
-   * the first request.
-   * For example, consider a situation where you make an initial request and
-   * the request times out. If you make the request again with the same request
-   * ID, the server can check to see whether the original operation
-   * was received. If it was, the server ignores the second request. This
-   * behavior prevents clients from mistakenly creating duplicate commitments.
-   * The request ID must be a valid UUID, with the exception that zero UUID is
-   * not supported (00000000-0000-0000-0000-000000000000).
-   * 
- * - * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The requestId. - */ - @java.lang.Override - public java.lang.String getRequestId() { - java.lang.Object ref = requestId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - requestId_ = s; - return s; - } - } - /** - * - * - *
-   * Optional. A unique request ID (optional). If you specify this ID, you can use it
-   * in cases when you need to retry your request. When you need to retry, this
-   * ID lets the server know that it can ignore the request if it has already
-   * been completed. The server guarantees that for at least 60 minutes after
-   * the first request.
-   * For example, consider a situation where you make an initial request and
-   * the request times out. If you make the request again with the same request
-   * ID, the server can check to see whether the original operation
-   * was received. If it was, the server ignores the second request. This
-   * behavior prevents clients from mistakenly creating duplicate commitments.
-   * The request ID must be a valid UUID, with the exception that zero UUID is
-   * not supported (00000000-0000-0000-0000-000000000000).
-   * 
- * - * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The bytes for requestId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getRequestIdBytes() { - java.lang.Object ref = requestId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - requestId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - if (!getRequestIdBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, requestId_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); - } - if (!getRequestIdBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, requestId_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest)) { - return super.equals(obj); - } - com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest other = - (com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (!getRequestId().equals(other.getRequestId())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + REQUEST_ID_FIELD_NUMBER; - hash = (53 * hash) + getRequestId().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * The request for [HubService.ActivateSpoke][google.cloud.networkconnectivity.v1.HubService.ActivateSpoke].
-   * 
- * - * Protobuf type {@code google.cloud.networkconnectivity.v1.ActivateSpokeRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.ActivateSpokeRequest) - com.google.cloud.networkconnectivity.v1.ActivateSpokeRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_ActivateSpokeRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_ActivateSpokeRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest.class, - com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest.Builder.class); - } - - // Construct using com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - requestId_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_ActivateSpokeRequest_descriptor; - } - - @java.lang.Override - public com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest - getDefaultInstanceForType() { - return com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest build() { - com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest buildPartial() { - com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest result = - new com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest(this); - result.name_ = name_; - result.requestId_ = requestId_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest) { - return mergeFrom((com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest other) { - if (other - == com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest.getDefaultInstance()) - return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getRequestId().isEmpty()) { - requestId_ = other.requestId_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * Required. The name of the spoke to activate.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. The name of the spoke to activate.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. The name of the spoke to activate.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. The name of the spoke to activate.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. The name of the spoke to activate.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private java.lang.Object requestId_ = ""; - /** - * - * - *
-     * Optional. A unique request ID (optional). If you specify this ID, you can use it
-     * in cases when you need to retry your request. When you need to retry, this
-     * ID lets the server know that it can ignore the request if it has already
-     * been completed. The server guarantees that for at least 60 minutes after
-     * the first request.
-     * For example, consider a situation where you make an initial request and
-     * the request times out. If you make the request again with the same request
-     * ID, the server can check to see whether the original operation
-     * was received. If it was, the server ignores the second request. This
-     * behavior prevents clients from mistakenly creating duplicate commitments.
-     * The request ID must be a valid UUID, with the exception that zero UUID is
-     * not supported (00000000-0000-0000-0000-000000000000).
-     * 
- * - * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The requestId. - */ - public java.lang.String getRequestId() { - java.lang.Object ref = requestId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - requestId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Optional. A unique request ID (optional). If you specify this ID, you can use it
-     * in cases when you need to retry your request. When you need to retry, this
-     * ID lets the server know that it can ignore the request if it has already
-     * been completed. The server guarantees that for at least 60 minutes after
-     * the first request.
-     * For example, consider a situation where you make an initial request and
-     * the request times out. If you make the request again with the same request
-     * ID, the server can check to see whether the original operation
-     * was received. If it was, the server ignores the second request. This
-     * behavior prevents clients from mistakenly creating duplicate commitments.
-     * The request ID must be a valid UUID, with the exception that zero UUID is
-     * not supported (00000000-0000-0000-0000-000000000000).
-     * 
- * - * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The bytes for requestId. - */ - public com.google.protobuf.ByteString getRequestIdBytes() { - java.lang.Object ref = requestId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - requestId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Optional. A unique request ID (optional). If you specify this ID, you can use it
-     * in cases when you need to retry your request. When you need to retry, this
-     * ID lets the server know that it can ignore the request if it has already
-     * been completed. The server guarantees that for at least 60 minutes after
-     * the first request.
-     * For example, consider a situation where you make an initial request and
-     * the request times out. If you make the request again with the same request
-     * ID, the server can check to see whether the original operation
-     * was received. If it was, the server ignores the second request. This
-     * behavior prevents clients from mistakenly creating duplicate commitments.
-     * The request ID must be a valid UUID, with the exception that zero UUID is
-     * not supported (00000000-0000-0000-0000-000000000000).
-     * 
- * - * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * - * @param value The requestId to set. - * @return This builder for chaining. - */ - public Builder setRequestId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - requestId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Optional. A unique request ID (optional). If you specify this ID, you can use it
-     * in cases when you need to retry your request. When you need to retry, this
-     * ID lets the server know that it can ignore the request if it has already
-     * been completed. The server guarantees that for at least 60 minutes after
-     * the first request.
-     * For example, consider a situation where you make an initial request and
-     * the request times out. If you make the request again with the same request
-     * ID, the server can check to see whether the original operation
-     * was received. If it was, the server ignores the second request. This
-     * behavior prevents clients from mistakenly creating duplicate commitments.
-     * The request ID must be a valid UUID, with the exception that zero UUID is
-     * not supported (00000000-0000-0000-0000-000000000000).
-     * 
- * - * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return This builder for chaining. - */ - public Builder clearRequestId() { - - requestId_ = getDefaultInstance().getRequestId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Optional. A unique request ID (optional). If you specify this ID, you can use it
-     * in cases when you need to retry your request. When you need to retry, this
-     * ID lets the server know that it can ignore the request if it has already
-     * been completed. The server guarantees that for at least 60 minutes after
-     * the first request.
-     * For example, consider a situation where you make an initial request and
-     * the request times out. If you make the request again with the same request
-     * ID, the server can check to see whether the original operation
-     * was received. If it was, the server ignores the second request. This
-     * behavior prevents clients from mistakenly creating duplicate commitments.
-     * The request ID must be a valid UUID, with the exception that zero UUID is
-     * not supported (00000000-0000-0000-0000-000000000000).
-     * 
- * - * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * - * @param value The bytes for requestId to set. - * @return This builder for chaining. - */ - public Builder setRequestIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - requestId_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.networkconnectivity.v1.ActivateSpokeRequest) - } - - // @@protoc_insertion_point(class_scope:google.cloud.networkconnectivity.v1.ActivateSpokeRequest) - private static final com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest(); - } - - public static com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ActivateSpokeRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ActivateSpokeRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.networkconnectivity.v1.ActivateSpokeRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ActivateSpokeRequestOrBuilder.java b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ActivateSpokeRequestOrBuilder.java deleted file mode 100644 index 8451bec6..00000000 --- a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ActivateSpokeRequestOrBuilder.java +++ /dev/null @@ -1,101 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/cloud/networkconnectivity/v1/hub.proto - -package com.google.cloud.networkconnectivity.v1; - -public interface ActivateSpokeRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.networkconnectivity.v1.ActivateSpokeRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Required. The name of the spoke to activate.
-   * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * Required. The name of the spoke to activate.
-   * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * Optional. A unique request ID (optional). If you specify this ID, you can use it
-   * in cases when you need to retry your request. When you need to retry, this
-   * ID lets the server know that it can ignore the request if it has already
-   * been completed. The server guarantees that for at least 60 minutes after
-   * the first request.
-   * For example, consider a situation where you make an initial request and
-   * the request times out. If you make the request again with the same request
-   * ID, the server can check to see whether the original operation
-   * was received. If it was, the server ignores the second request. This
-   * behavior prevents clients from mistakenly creating duplicate commitments.
-   * The request ID must be a valid UUID, with the exception that zero UUID is
-   * not supported (00000000-0000-0000-0000-000000000000).
-   * 
- * - * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The requestId. - */ - java.lang.String getRequestId(); - /** - * - * - *
-   * Optional. A unique request ID (optional). If you specify this ID, you can use it
-   * in cases when you need to retry your request. When you need to retry, this
-   * ID lets the server know that it can ignore the request if it has already
-   * been completed. The server guarantees that for at least 60 minutes after
-   * the first request.
-   * For example, consider a situation where you make an initial request and
-   * the request times out. If you make the request again with the same request
-   * ID, the server can check to see whether the original operation
-   * was received. If it was, the server ignores the second request. This
-   * behavior prevents clients from mistakenly creating duplicate commitments.
-   * The request ID must be a valid UUID, with the exception that zero UUID is
-   * not supported (00000000-0000-0000-0000-000000000000).
-   * 
- * - * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The bytes for requestId. - */ - com.google.protobuf.ByteString getRequestIdBytes(); -} diff --git a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/DeactivateSpokeRequest.java b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/DeactivateSpokeRequest.java deleted file mode 100644 index bc1a0c09..00000000 --- a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/DeactivateSpokeRequest.java +++ /dev/null @@ -1,913 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/cloud/networkconnectivity/v1/hub.proto - -package com.google.cloud.networkconnectivity.v1; - -/** - * - * - *
- * The request for [HubService.DeactivateSpoke][google.cloud.networkconnectivity.v1.HubService.DeactivateSpoke].
- * 
- * - * Protobuf type {@code google.cloud.networkconnectivity.v1.DeactivateSpokeRequest} - */ -public final class DeactivateSpokeRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.networkconnectivity.v1.DeactivateSpokeRequest) - DeactivateSpokeRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use DeactivateSpokeRequest.newBuilder() to construct. - private DeactivateSpokeRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private DeactivateSpokeRequest() { - name_ = ""; - requestId_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new DeactivateSpokeRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private DeactivateSpokeRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - requestId_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_DeactivateSpokeRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_DeactivateSpokeRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest.class, - com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * Required. The name of the spoke to deactivate.
-   * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * Required. The name of the spoke to deactivate.
-   * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int REQUEST_ID_FIELD_NUMBER = 2; - private volatile java.lang.Object requestId_; - /** - * - * - *
-   * Optional. A unique request ID (optional). If you specify this ID, you can use it
-   * in cases when you need to retry your request. When you need to retry, this
-   * ID lets the server know that it can ignore the request if it has already
-   * been completed. The server guarantees that for at least 60 minutes after
-   * the first request.
-   * For example, consider a situation where you make an initial request and
-   * the request times out. If you make the request again with the same request
-   * ID, the server can check to see whether the original operation
-   * was received. If it was, the server ignores the second request. This
-   * behavior prevents clients from mistakenly creating duplicate commitments.
-   * The request ID must be a valid UUID, with the exception that zero UUID is
-   * not supported (00000000-0000-0000-0000-000000000000).
-   * 
- * - * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The requestId. - */ - @java.lang.Override - public java.lang.String getRequestId() { - java.lang.Object ref = requestId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - requestId_ = s; - return s; - } - } - /** - * - * - *
-   * Optional. A unique request ID (optional). If you specify this ID, you can use it
-   * in cases when you need to retry your request. When you need to retry, this
-   * ID lets the server know that it can ignore the request if it has already
-   * been completed. The server guarantees that for at least 60 minutes after
-   * the first request.
-   * For example, consider a situation where you make an initial request and
-   * the request times out. If you make the request again with the same request
-   * ID, the server can check to see whether the original operation
-   * was received. If it was, the server ignores the second request. This
-   * behavior prevents clients from mistakenly creating duplicate commitments.
-   * The request ID must be a valid UUID, with the exception that zero UUID is
-   * not supported (00000000-0000-0000-0000-000000000000).
-   * 
- * - * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The bytes for requestId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getRequestIdBytes() { - java.lang.Object ref = requestId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - requestId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - if (!getRequestIdBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, requestId_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); - } - if (!getRequestIdBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, requestId_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest)) { - return super.equals(obj); - } - com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest other = - (com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (!getRequestId().equals(other.getRequestId())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + REQUEST_ID_FIELD_NUMBER; - hash = (53 * hash) + getRequestId().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * The request for [HubService.DeactivateSpoke][google.cloud.networkconnectivity.v1.HubService.DeactivateSpoke].
-   * 
- * - * Protobuf type {@code google.cloud.networkconnectivity.v1.DeactivateSpokeRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.DeactivateSpokeRequest) - com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_DeactivateSpokeRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_DeactivateSpokeRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest.class, - com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest.Builder.class); - } - - // Construct using com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - requestId_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_DeactivateSpokeRequest_descriptor; - } - - @java.lang.Override - public com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest - getDefaultInstanceForType() { - return com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest build() { - com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest buildPartial() { - com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest result = - new com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest(this); - result.name_ = name_; - result.requestId_ = requestId_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest) { - return mergeFrom((com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest other) { - if (other - == com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest.getDefaultInstance()) - return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getRequestId().isEmpty()) { - requestId_ = other.requestId_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * Required. The name of the spoke to deactivate.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. The name of the spoke to deactivate.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. The name of the spoke to deactivate.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. The name of the spoke to deactivate.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. The name of the spoke to deactivate.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private java.lang.Object requestId_ = ""; - /** - * - * - *
-     * Optional. A unique request ID (optional). If you specify this ID, you can use it
-     * in cases when you need to retry your request. When you need to retry, this
-     * ID lets the server know that it can ignore the request if it has already
-     * been completed. The server guarantees that for at least 60 minutes after
-     * the first request.
-     * For example, consider a situation where you make an initial request and
-     * the request times out. If you make the request again with the same request
-     * ID, the server can check to see whether the original operation
-     * was received. If it was, the server ignores the second request. This
-     * behavior prevents clients from mistakenly creating duplicate commitments.
-     * The request ID must be a valid UUID, with the exception that zero UUID is
-     * not supported (00000000-0000-0000-0000-000000000000).
-     * 
- * - * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The requestId. - */ - public java.lang.String getRequestId() { - java.lang.Object ref = requestId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - requestId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Optional. A unique request ID (optional). If you specify this ID, you can use it
-     * in cases when you need to retry your request. When you need to retry, this
-     * ID lets the server know that it can ignore the request if it has already
-     * been completed. The server guarantees that for at least 60 minutes after
-     * the first request.
-     * For example, consider a situation where you make an initial request and
-     * the request times out. If you make the request again with the same request
-     * ID, the server can check to see whether the original operation
-     * was received. If it was, the server ignores the second request. This
-     * behavior prevents clients from mistakenly creating duplicate commitments.
-     * The request ID must be a valid UUID, with the exception that zero UUID is
-     * not supported (00000000-0000-0000-0000-000000000000).
-     * 
- * - * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The bytes for requestId. - */ - public com.google.protobuf.ByteString getRequestIdBytes() { - java.lang.Object ref = requestId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - requestId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Optional. A unique request ID (optional). If you specify this ID, you can use it
-     * in cases when you need to retry your request. When you need to retry, this
-     * ID lets the server know that it can ignore the request if it has already
-     * been completed. The server guarantees that for at least 60 minutes after
-     * the first request.
-     * For example, consider a situation where you make an initial request and
-     * the request times out. If you make the request again with the same request
-     * ID, the server can check to see whether the original operation
-     * was received. If it was, the server ignores the second request. This
-     * behavior prevents clients from mistakenly creating duplicate commitments.
-     * The request ID must be a valid UUID, with the exception that zero UUID is
-     * not supported (00000000-0000-0000-0000-000000000000).
-     * 
- * - * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * - * @param value The requestId to set. - * @return This builder for chaining. - */ - public Builder setRequestId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - requestId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Optional. A unique request ID (optional). If you specify this ID, you can use it
-     * in cases when you need to retry your request. When you need to retry, this
-     * ID lets the server know that it can ignore the request if it has already
-     * been completed. The server guarantees that for at least 60 minutes after
-     * the first request.
-     * For example, consider a situation where you make an initial request and
-     * the request times out. If you make the request again with the same request
-     * ID, the server can check to see whether the original operation
-     * was received. If it was, the server ignores the second request. This
-     * behavior prevents clients from mistakenly creating duplicate commitments.
-     * The request ID must be a valid UUID, with the exception that zero UUID is
-     * not supported (00000000-0000-0000-0000-000000000000).
-     * 
- * - * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return This builder for chaining. - */ - public Builder clearRequestId() { - - requestId_ = getDefaultInstance().getRequestId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Optional. A unique request ID (optional). If you specify this ID, you can use it
-     * in cases when you need to retry your request. When you need to retry, this
-     * ID lets the server know that it can ignore the request if it has already
-     * been completed. The server guarantees that for at least 60 minutes after
-     * the first request.
-     * For example, consider a situation where you make an initial request and
-     * the request times out. If you make the request again with the same request
-     * ID, the server can check to see whether the original operation
-     * was received. If it was, the server ignores the second request. This
-     * behavior prevents clients from mistakenly creating duplicate commitments.
-     * The request ID must be a valid UUID, with the exception that zero UUID is
-     * not supported (00000000-0000-0000-0000-000000000000).
-     * 
- * - * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * - * @param value The bytes for requestId to set. - * @return This builder for chaining. - */ - public Builder setRequestIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - requestId_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.networkconnectivity.v1.DeactivateSpokeRequest) - } - - // @@protoc_insertion_point(class_scope:google.cloud.networkconnectivity.v1.DeactivateSpokeRequest) - private static final com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest(); - } - - public static com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public DeactivateSpokeRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new DeactivateSpokeRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.networkconnectivity.v1.DeactivateSpokeRequest - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/DeactivateSpokeRequestOrBuilder.java b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/DeactivateSpokeRequestOrBuilder.java deleted file mode 100644 index 3a7718f3..00000000 --- a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/DeactivateSpokeRequestOrBuilder.java +++ /dev/null @@ -1,101 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/cloud/networkconnectivity/v1/hub.proto - -package com.google.cloud.networkconnectivity.v1; - -public interface DeactivateSpokeRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.networkconnectivity.v1.DeactivateSpokeRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Required. The name of the spoke to deactivate.
-   * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * Required. The name of the spoke to deactivate.
-   * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * Optional. A unique request ID (optional). If you specify this ID, you can use it
-   * in cases when you need to retry your request. When you need to retry, this
-   * ID lets the server know that it can ignore the request if it has already
-   * been completed. The server guarantees that for at least 60 minutes after
-   * the first request.
-   * For example, consider a situation where you make an initial request and
-   * the request times out. If you make the request again with the same request
-   * ID, the server can check to see whether the original operation
-   * was received. If it was, the server ignores the second request. This
-   * behavior prevents clients from mistakenly creating duplicate commitments.
-   * The request ID must be a valid UUID, with the exception that zero UUID is
-   * not supported (00000000-0000-0000-0000-000000000000).
-   * 
- * - * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The requestId. - */ - java.lang.String getRequestId(); - /** - * - * - *
-   * Optional. A unique request ID (optional). If you specify this ID, you can use it
-   * in cases when you need to retry your request. When you need to retry, this
-   * ID lets the server know that it can ignore the request if it has already
-   * been completed. The server guarantees that for at least 60 minutes after
-   * the first request.
-   * For example, consider a situation where you make an initial request and
-   * the request times out. If you make the request again with the same request
-   * ID, the server can check to see whether the original operation
-   * was received. If it was, the server ignores the second request. This
-   * behavior prevents clients from mistakenly creating duplicate commitments.
-   * The request ID must be a valid UUID, with the exception that zero UUID is
-   * not supported (00000000-0000-0000-0000-000000000000).
-   * 
- * - * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The bytes for requestId. - */ - com.google.protobuf.ByteString getRequestIdBytes(); -} diff --git a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Hub.java b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Hub.java index cd8dad7a..062d31a4 100644 --- a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Hub.java +++ b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Hub.java @@ -44,6 +44,7 @@ private Hub() { description_ = ""; uniqueId_ = ""; state_ = 0; + routingVpcs_ = java.util.Collections.emptyList(); } @java.lang.Override @@ -147,6 +148,19 @@ private Hub( state_ = rawValue; break; } + case 82: + { + if (!((mutable_bitField0_ & 0x00000002) != 0)) { + routingVpcs_ = + new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000002; + } + routingVpcs_.add( + input.readMessage( + com.google.cloud.networkconnectivity.v1.RoutingVPC.parser(), + extensionRegistry)); + break; + } default: { if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { @@ -161,6 +175,9 @@ private Hub( } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { + if (((mutable_bitField0_ & 0x00000002) != 0)) { + routingVpcs_ = java.util.Collections.unmodifiableList(routingVpcs_); + } this.unknownFields = unknownFields.build(); makeExtensionsImmutable(); } @@ -591,6 +608,96 @@ public com.google.cloud.networkconnectivity.v1.State getState() { return result == null ? com.google.cloud.networkconnectivity.v1.State.UNRECOGNIZED : result; } + public static final int ROUTING_VPCS_FIELD_NUMBER = 10; + private java.util.List routingVpcs_; + /** + * + * + *
+   * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+   * VLAN attachments, and router appliance instances referenced by this hub's
+   * spokes must belong to this VPC network.
+   * This field is read-only. Network Connectivity Center automatically
+   * populates it based on the set of spokes attached to the hub.
+   * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + @java.lang.Override + public java.util.List getRoutingVpcsList() { + return routingVpcs_; + } + /** + * + * + *
+   * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+   * VLAN attachments, and router appliance instances referenced by this hub's
+   * spokes must belong to this VPC network.
+   * This field is read-only. Network Connectivity Center automatically
+   * populates it based on the set of spokes attached to the hub.
+   * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + @java.lang.Override + public java.util.List + getRoutingVpcsOrBuilderList() { + return routingVpcs_; + } + /** + * + * + *
+   * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+   * VLAN attachments, and router appliance instances referenced by this hub's
+   * spokes must belong to this VPC network.
+   * This field is read-only. Network Connectivity Center automatically
+   * populates it based on the set of spokes attached to the hub.
+   * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + @java.lang.Override + public int getRoutingVpcsCount() { + return routingVpcs_.size(); + } + /** + * + * + *
+   * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+   * VLAN attachments, and router appliance instances referenced by this hub's
+   * spokes must belong to this VPC network.
+   * This field is read-only. Network Connectivity Center automatically
+   * populates it based on the set of spokes attached to the hub.
+   * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.RoutingVPC getRoutingVpcs(int index) { + return routingVpcs_.get(index); + } + /** + * + * + *
+   * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+   * VLAN attachments, and router appliance instances referenced by this hub's
+   * spokes must belong to this VPC network.
+   * This field is read-only. Network Connectivity Center automatically
+   * populates it based on the set of spokes attached to the hub.
+   * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.RoutingVPCOrBuilder getRoutingVpcsOrBuilder( + int index) { + return routingVpcs_.get(index); + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -625,6 +732,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (state_ != com.google.cloud.networkconnectivity.v1.State.STATE_UNSPECIFIED.getNumber()) { output.writeEnum(9, state_); } + for (int i = 0; i < routingVpcs_.size(); i++) { + output.writeMessage(10, routingVpcs_.get(i)); + } unknownFields.writeTo(output); } @@ -662,6 +772,9 @@ public int getSerializedSize() { if (state_ != com.google.cloud.networkconnectivity.v1.State.STATE_UNSPECIFIED.getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(9, state_); } + for (int i = 0; i < routingVpcs_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, routingVpcs_.get(i)); + } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; @@ -691,6 +804,7 @@ public boolean equals(final java.lang.Object obj) { if (!getDescription().equals(other.getDescription())) return false; if (!getUniqueId().equals(other.getUniqueId())) return false; if (state_ != other.state_) return false; + if (!getRoutingVpcsList().equals(other.getRoutingVpcsList())) return false; if (!unknownFields.equals(other.unknownFields)) return false; return true; } @@ -722,6 +836,10 @@ public int hashCode() { hash = (53 * hash) + getUniqueId().hashCode(); hash = (37 * hash) + STATE_FIELD_NUMBER; hash = (53 * hash) + state_; + if (getRoutingVpcsCount() > 0) { + hash = (37 * hash) + ROUTING_VPCS_FIELD_NUMBER; + hash = (53 * hash) + getRoutingVpcsList().hashCode(); + } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; @@ -883,7 +1001,9 @@ private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { } private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getRoutingVpcsFieldBuilder(); + } } @java.lang.Override @@ -910,6 +1030,12 @@ public Builder clear() { state_ = 0; + if (routingVpcsBuilder_ == null) { + routingVpcs_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + } else { + routingVpcsBuilder_.clear(); + } return this; } @@ -954,6 +1080,15 @@ public com.google.cloud.networkconnectivity.v1.Hub buildPartial() { result.description_ = description_; result.uniqueId_ = uniqueId_; result.state_ = state_; + if (routingVpcsBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0)) { + routingVpcs_ = java.util.Collections.unmodifiableList(routingVpcs_); + bitField0_ = (bitField0_ & ~0x00000002); + } + result.routingVpcs_ = routingVpcs_; + } else { + result.routingVpcs_ = routingVpcsBuilder_.build(); + } onBuilt(); return result; } @@ -1025,6 +1160,33 @@ public Builder mergeFrom(com.google.cloud.networkconnectivity.v1.Hub other) { if (other.state_ != 0) { setStateValue(other.getStateValue()); } + if (routingVpcsBuilder_ == null) { + if (!other.routingVpcs_.isEmpty()) { + if (routingVpcs_.isEmpty()) { + routingVpcs_ = other.routingVpcs_; + bitField0_ = (bitField0_ & ~0x00000002); + } else { + ensureRoutingVpcsIsMutable(); + routingVpcs_.addAll(other.routingVpcs_); + } + onChanged(); + } + } else { + if (!other.routingVpcs_.isEmpty()) { + if (routingVpcsBuilder_.isEmpty()) { + routingVpcsBuilder_.dispose(); + routingVpcsBuilder_ = null; + routingVpcs_ = other.routingVpcs_; + bitField0_ = (bitField0_ & ~0x00000002); + routingVpcsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getRoutingVpcsFieldBuilder() + : null; + } else { + routingVpcsBuilder_.addAllMessages(other.routingVpcs_); + } + } + } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; @@ -2068,6 +2230,436 @@ public Builder clearState() { return this; } + private java.util.List routingVpcs_ = + java.util.Collections.emptyList(); + + private void ensureRoutingVpcsIsMutable() { + if (!((bitField0_ & 0x00000002) != 0)) { + routingVpcs_ = + new java.util.ArrayList( + routingVpcs_); + bitField0_ |= 0x00000002; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.networkconnectivity.v1.RoutingVPC, + com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder, + com.google.cloud.networkconnectivity.v1.RoutingVPCOrBuilder> + routingVpcsBuilder_; + + /** + * + * + *
+     * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+     * VLAN attachments, and router appliance instances referenced by this hub's
+     * spokes must belong to this VPC network.
+     * This field is read-only. Network Connectivity Center automatically
+     * populates it based on the set of spokes attached to the hub.
+     * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + public java.util.List getRoutingVpcsList() { + if (routingVpcsBuilder_ == null) { + return java.util.Collections.unmodifiableList(routingVpcs_); + } else { + return routingVpcsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+     * VLAN attachments, and router appliance instances referenced by this hub's
+     * spokes must belong to this VPC network.
+     * This field is read-only. Network Connectivity Center automatically
+     * populates it based on the set of spokes attached to the hub.
+     * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + public int getRoutingVpcsCount() { + if (routingVpcsBuilder_ == null) { + return routingVpcs_.size(); + } else { + return routingVpcsBuilder_.getCount(); + } + } + /** + * + * + *
+     * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+     * VLAN attachments, and router appliance instances referenced by this hub's
+     * spokes must belong to this VPC network.
+     * This field is read-only. Network Connectivity Center automatically
+     * populates it based on the set of spokes attached to the hub.
+     * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + public com.google.cloud.networkconnectivity.v1.RoutingVPC getRoutingVpcs(int index) { + if (routingVpcsBuilder_ == null) { + return routingVpcs_.get(index); + } else { + return routingVpcsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+     * VLAN attachments, and router appliance instances referenced by this hub's
+     * spokes must belong to this VPC network.
+     * This field is read-only. Network Connectivity Center automatically
+     * populates it based on the set of spokes attached to the hub.
+     * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + public Builder setRoutingVpcs( + int index, com.google.cloud.networkconnectivity.v1.RoutingVPC value) { + if (routingVpcsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureRoutingVpcsIsMutable(); + routingVpcs_.set(index, value); + onChanged(); + } else { + routingVpcsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+     * VLAN attachments, and router appliance instances referenced by this hub's
+     * spokes must belong to this VPC network.
+     * This field is read-only. Network Connectivity Center automatically
+     * populates it based on the set of spokes attached to the hub.
+     * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + public Builder setRoutingVpcs( + int index, com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder builderForValue) { + if (routingVpcsBuilder_ == null) { + ensureRoutingVpcsIsMutable(); + routingVpcs_.set(index, builderForValue.build()); + onChanged(); + } else { + routingVpcsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+     * VLAN attachments, and router appliance instances referenced by this hub's
+     * spokes must belong to this VPC network.
+     * This field is read-only. Network Connectivity Center automatically
+     * populates it based on the set of spokes attached to the hub.
+     * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + public Builder addRoutingVpcs(com.google.cloud.networkconnectivity.v1.RoutingVPC value) { + if (routingVpcsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureRoutingVpcsIsMutable(); + routingVpcs_.add(value); + onChanged(); + } else { + routingVpcsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+     * VLAN attachments, and router appliance instances referenced by this hub's
+     * spokes must belong to this VPC network.
+     * This field is read-only. Network Connectivity Center automatically
+     * populates it based on the set of spokes attached to the hub.
+     * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + public Builder addRoutingVpcs( + int index, com.google.cloud.networkconnectivity.v1.RoutingVPC value) { + if (routingVpcsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureRoutingVpcsIsMutable(); + routingVpcs_.add(index, value); + onChanged(); + } else { + routingVpcsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+     * VLAN attachments, and router appliance instances referenced by this hub's
+     * spokes must belong to this VPC network.
+     * This field is read-only. Network Connectivity Center automatically
+     * populates it based on the set of spokes attached to the hub.
+     * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + public Builder addRoutingVpcs( + com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder builderForValue) { + if (routingVpcsBuilder_ == null) { + ensureRoutingVpcsIsMutable(); + routingVpcs_.add(builderForValue.build()); + onChanged(); + } else { + routingVpcsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+     * VLAN attachments, and router appliance instances referenced by this hub's
+     * spokes must belong to this VPC network.
+     * This field is read-only. Network Connectivity Center automatically
+     * populates it based on the set of spokes attached to the hub.
+     * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + public Builder addRoutingVpcs( + int index, com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder builderForValue) { + if (routingVpcsBuilder_ == null) { + ensureRoutingVpcsIsMutable(); + routingVpcs_.add(index, builderForValue.build()); + onChanged(); + } else { + routingVpcsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+     * VLAN attachments, and router appliance instances referenced by this hub's
+     * spokes must belong to this VPC network.
+     * This field is read-only. Network Connectivity Center automatically
+     * populates it based on the set of spokes attached to the hub.
+     * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + public Builder addAllRoutingVpcs( + java.lang.Iterable values) { + if (routingVpcsBuilder_ == null) { + ensureRoutingVpcsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, routingVpcs_); + onChanged(); + } else { + routingVpcsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+     * VLAN attachments, and router appliance instances referenced by this hub's
+     * spokes must belong to this VPC network.
+     * This field is read-only. Network Connectivity Center automatically
+     * populates it based on the set of spokes attached to the hub.
+     * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + public Builder clearRoutingVpcs() { + if (routingVpcsBuilder_ == null) { + routingVpcs_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + } else { + routingVpcsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+     * VLAN attachments, and router appliance instances referenced by this hub's
+     * spokes must belong to this VPC network.
+     * This field is read-only. Network Connectivity Center automatically
+     * populates it based on the set of spokes attached to the hub.
+     * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + public Builder removeRoutingVpcs(int index) { + if (routingVpcsBuilder_ == null) { + ensureRoutingVpcsIsMutable(); + routingVpcs_.remove(index); + onChanged(); + } else { + routingVpcsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+     * VLAN attachments, and router appliance instances referenced by this hub's
+     * spokes must belong to this VPC network.
+     * This field is read-only. Network Connectivity Center automatically
+     * populates it based on the set of spokes attached to the hub.
+     * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + public com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder getRoutingVpcsBuilder( + int index) { + return getRoutingVpcsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+     * VLAN attachments, and router appliance instances referenced by this hub's
+     * spokes must belong to this VPC network.
+     * This field is read-only. Network Connectivity Center automatically
+     * populates it based on the set of spokes attached to the hub.
+     * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + public com.google.cloud.networkconnectivity.v1.RoutingVPCOrBuilder getRoutingVpcsOrBuilder( + int index) { + if (routingVpcsBuilder_ == null) { + return routingVpcs_.get(index); + } else { + return routingVpcsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+     * VLAN attachments, and router appliance instances referenced by this hub's
+     * spokes must belong to this VPC network.
+     * This field is read-only. Network Connectivity Center automatically
+     * populates it based on the set of spokes attached to the hub.
+     * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + public java.util.List + getRoutingVpcsOrBuilderList() { + if (routingVpcsBuilder_ != null) { + return routingVpcsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(routingVpcs_); + } + } + /** + * + * + *
+     * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+     * VLAN attachments, and router appliance instances referenced by this hub's
+     * spokes must belong to this VPC network.
+     * This field is read-only. Network Connectivity Center automatically
+     * populates it based on the set of spokes attached to the hub.
+     * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + public com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder addRoutingVpcsBuilder() { + return getRoutingVpcsFieldBuilder() + .addBuilder(com.google.cloud.networkconnectivity.v1.RoutingVPC.getDefaultInstance()); + } + /** + * + * + *
+     * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+     * VLAN attachments, and router appliance instances referenced by this hub's
+     * spokes must belong to this VPC network.
+     * This field is read-only. Network Connectivity Center automatically
+     * populates it based on the set of spokes attached to the hub.
+     * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + public com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder addRoutingVpcsBuilder( + int index) { + return getRoutingVpcsFieldBuilder() + .addBuilder( + index, com.google.cloud.networkconnectivity.v1.RoutingVPC.getDefaultInstance()); + } + /** + * + * + *
+     * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+     * VLAN attachments, and router appliance instances referenced by this hub's
+     * spokes must belong to this VPC network.
+     * This field is read-only. Network Connectivity Center automatically
+     * populates it based on the set of spokes attached to the hub.
+     * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + public java.util.List + getRoutingVpcsBuilderList() { + return getRoutingVpcsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.networkconnectivity.v1.RoutingVPC, + com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder, + com.google.cloud.networkconnectivity.v1.RoutingVPCOrBuilder> + getRoutingVpcsFieldBuilder() { + if (routingVpcsBuilder_ == null) { + routingVpcsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.networkconnectivity.v1.RoutingVPC, + com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder, + com.google.cloud.networkconnectivity.v1.RoutingVPCOrBuilder>( + routingVpcs_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean()); + routingVpcs_ = null; + } + return routingVpcsBuilder_; + } + @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); diff --git a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubOrBuilder.java b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubOrBuilder.java index ff51804d..497ad3a5 100644 --- a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubOrBuilder.java +++ b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubOrBuilder.java @@ -274,4 +274,76 @@ public interface HubOrBuilder * @return The state. */ com.google.cloud.networkconnectivity.v1.State getState(); + + /** + * + * + *
+   * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+   * VLAN attachments, and router appliance instances referenced by this hub's
+   * spokes must belong to this VPC network.
+   * This field is read-only. Network Connectivity Center automatically
+   * populates it based on the set of spokes attached to the hub.
+   * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + java.util.List getRoutingVpcsList(); + /** + * + * + *
+   * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+   * VLAN attachments, and router appliance instances referenced by this hub's
+   * spokes must belong to this VPC network.
+   * This field is read-only. Network Connectivity Center automatically
+   * populates it based on the set of spokes attached to the hub.
+   * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + com.google.cloud.networkconnectivity.v1.RoutingVPC getRoutingVpcs(int index); + /** + * + * + *
+   * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+   * VLAN attachments, and router appliance instances referenced by this hub's
+   * spokes must belong to this VPC network.
+   * This field is read-only. Network Connectivity Center automatically
+   * populates it based on the set of spokes attached to the hub.
+   * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + int getRoutingVpcsCount(); + /** + * + * + *
+   * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+   * VLAN attachments, and router appliance instances referenced by this hub's
+   * spokes must belong to this VPC network.
+   * This field is read-only. Network Connectivity Center automatically
+   * populates it based on the set of spokes attached to the hub.
+   * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + java.util.List + getRoutingVpcsOrBuilderList(); + /** + * + * + *
+   * The VPC network associated with this hub's spokes. All of the VPN tunnels,
+   * VLAN attachments, and router appliance instances referenced by this hub's
+   * spokes must belong to this VPC network.
+   * This field is read-only. Network Connectivity Center automatically
+   * populates it based on the set of spokes attached to the hub.
+   * 
+ * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + */ + com.google.cloud.networkconnectivity.v1.RoutingVPCOrBuilder getRoutingVpcsOrBuilder(int index); } diff --git a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubProto.java b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubProto.java index f026b372..543b7994 100644 --- a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubProto.java +++ b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubProto.java @@ -35,6 +35,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_networkconnectivity_v1_Hub_LabelsEntry_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_cloud_networkconnectivity_v1_Hub_LabelsEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_networkconnectivity_v1_RoutingVPC_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_networkconnectivity_v1_RoutingVPC_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_networkconnectivity_v1_Spoke_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable @@ -91,14 +95,6 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_networkconnectivity_v1_DeleteSpokeRequest_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_cloud_networkconnectivity_v1_DeleteSpokeRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_networkconnectivity_v1_DeactivateSpokeRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_networkconnectivity_v1_DeactivateSpokeRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_networkconnectivity_v1_ActivateSpokeRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_networkconnectivity_v1_ActivateSpokeRequest_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_networkconnectivity_v1_LinkedVpnTunnels_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable @@ -131,7 +127,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "havior.proto\032\031google/api/resource.proto\032" + "#google/longrunning/operations.proto\032 go" + "ogle/protobuf/field_mask.proto\032\037google/p" - + "rotobuf/timestamp.proto\"\303\003\n\003Hub\022\021\n\004name\030" + + "rotobuf/timestamp.proto\"\212\004\n\003Hub\022\021\n\004name\030" + "\001 \001(\tB\003\340A\005\0224\n\013create_time\030\002 \001(\0132\032.google" + ".protobuf.TimestampB\003\340A\003\0224\n\013update_time\030" + "\003 \001(\0132\032.google.protobuf.TimestampB\003\340A\003\022D" @@ -139,172 +135,159 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "nectivity.v1.Hub.LabelsEntry\022\023\n\013descript" + "ion\030\005 \001(\t\022\026\n\tunique_id\030\010 \001(\tB\003\340A\003\022>\n\005sta" + "te\030\t \001(\0162*.google.cloud.networkconnectiv" - + "ity.v1.StateB\003\340A\003\032-\n\013LabelsEntry\022\013\n\003key\030" - + "\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001:[\352AX\n&networkco" - + "nnectivity.googleapis.com/Hub\022.projects/" - + "{project}/locations/global/hubs/{hub}\"\276\006" - + "\n\005Spoke\022\021\n\004name\030\001 \001(\tB\003\340A\005\0224\n\013create_tim" - + "e\030\002 \001(\0132\032.google.protobuf.TimestampB\003\340A\003" - + "\0224\n\013update_time\030\003 \001(\0132\032.google.protobuf." - + "TimestampB\003\340A\003\022F\n\006labels\030\004 \003(\01326.google." - + "cloud.networkconnectivity.v1.Spoke.Label" - + "sEntry\022\023\n\013description\030\005 \001(\t\022;\n\003hub\030\006 \001(\t" - + "B.\340A\005\372A(\n&networkconnectivity.googleapis" - + ".com/Hub\022Q\n\022linked_vpn_tunnels\030\021 \001(\01325.g" - + "oogle.cloud.networkconnectivity.v1.Linke" - + "dVpnTunnels\022k\n\037linked_interconnect_attac" - + "hments\030\022 \001(\0132B.google.cloud.networkconne" - + "ctivity.v1.LinkedInterconnectAttachments" - + "\022n\n!linked_router_appliance_instances\030\023 " - + "\001(\0132C.google.cloud.networkconnectivity.v" - + "1.LinkedRouterApplianceInstances\022\026\n\tuniq" - + "ue_id\030\013 \001(\tB\003\340A\003\022>\n\005state\030\017 \001(\0162*.google" - + ".cloud.networkconnectivity.v1.StateB\003\340A\003" - + "\032-\n\013LabelsEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 " - + "\001(\t:\0028\001:e\352Ab\n(networkconnectivity.google" - + "apis.com/Spoke\0226projects/{project}/locat" - + "ions/{location}/spokes/{spoke}\"\225\001\n\017ListH" - + "ubsRequest\0229\n\006parent\030\001 \001(\tB)\340A\002\372A#\n!loca" - + "tions.googleapis.com/Location\022\021\n\tpage_si" - + "ze\030\002 \001(\005\022\022\n\npage_token\030\003 \001(\t\022\016\n\006filter\030\004" - + " \001(\t\022\020\n\010order_by\030\005 \001(\t\"x\n\020ListHubsRespon" - + "se\0226\n\004hubs\030\001 \003(\0132(.google.cloud.networkc" - + "onnectivity.v1.Hub\022\027\n\017next_page_token\030\002 " - + "\001(\t\022\023\n\013unreachable\030\003 \003(\t\"M\n\rGetHubReques" - + "t\022<\n\004name\030\001 \001(\tB.\340A\002\372A(\n&networkconnecti" - + "vity.googleapis.com/Hub\"\267\001\n\020CreateHubReq" - + "uest\0229\n\006parent\030\001 \001(\tB)\340A\002\372A#\n!locations." - + "googleapis.com/Location\022\023\n\006hub_id\030\002 \001(\tB" - + "\003\340A\001\022:\n\003hub\030\003 \001(\0132(.google.cloud.network" - + "connectivity.v1.HubB\003\340A\002\022\027\n\nrequest_id\030\004" - + " \001(\tB\003\340A\001\"\235\001\n\020UpdateHubRequest\0224\n\013update" - + "_mask\030\001 \001(\0132\032.google.protobuf.FieldMaskB" - + "\003\340A\001\022:\n\003hub\030\002 \001(\0132(.google.cloud.network" - + "connectivity.v1.HubB\003\340A\002\022\027\n\nrequest_id\030\003" - + " \001(\tB\003\340A\001\"i\n\020DeleteHubRequest\022<\n\004name\030\001 " - + "\001(\tB.\340A\002\372A(\n&networkconnectivity.googlea" - + "pis.com/Hub\022\027\n\nrequest_id\030\002 \001(\tB\003\340A\001\"\227\001\n" - + "\021ListSpokesRequest\0229\n\006parent\030\001 \001(\tB)\340A\002\372" - + "A#\n!locations.googleapis.com/Location\022\021\n" - + "\tpage_size\030\002 \001(\005\022\022\n\npage_token\030\003 \001(\t\022\016\n\006" - + "filter\030\004 \001(\t\022\020\n\010order_by\030\005 \001(\t\"~\n\022ListSp" - + "okesResponse\022:\n\006spokes\030\001 \003(\0132*.google.cl" - + "oud.networkconnectivity.v1.Spoke\022\027\n\017next" - + "_page_token\030\002 \001(\t\022\023\n\013unreachable\030\003 \003(\t\"Q" - + "\n\017GetSpokeRequest\022>\n\004name\030\001 \001(\tB0\340A\002\372A*\n" - + "(networkconnectivity.googleapis.com/Spok" - + "e\"\277\001\n\022CreateSpokeRequest\0229\n\006parent\030\001 \001(\t" - + "B)\340A\002\372A#\n!locations.googleapis.com/Locat" - + "ion\022\025\n\010spoke_id\030\002 \001(\tB\003\340A\001\022>\n\005spoke\030\003 \001(" - + "\0132*.google.cloud.networkconnectivity.v1." - + "SpokeB\003\340A\002\022\027\n\nrequest_id\030\004 \001(\tB\003\340A\001\"\243\001\n\022" - + "UpdateSpokeRequest\0224\n\013update_mask\030\001 \001(\0132" - + "\032.google.protobuf.FieldMaskB\003\340A\001\022>\n\005spok" - + "e\030\002 \001(\0132*.google.cloud.networkconnectivi" - + "ty.v1.SpokeB\003\340A\002\022\027\n\nrequest_id\030\003 \001(\tB\003\340A" - + "\001\"m\n\022DeleteSpokeRequest\022>\n\004name\030\001 \001(\tB0\340" - + "A\002\372A*\n(networkconnectivity.googleapis.co" - + "m/Spoke\022\027\n\nrequest_id\030\002 \001(\tB\003\340A\001\"q\n\026Deac" - + "tivateSpokeRequest\022>\n\004name\030\001 \001(\tB0\340A\002\372A*" - + "\n(networkconnectivity.googleapis.com/Spo" - + "ke\022\027\n\nrequest_id\030\002 \001(\tB\003\340A\001\"o\n\024ActivateS" - + "pokeRequest\022>\n\004name\030\001 \001(\tB0\340A\002\372A*\n(netwo" - + "rkconnectivity.googleapis.com/Spoke\022\027\n\nr" - + "equest_id\030\002 \001(\tB\003\340A\001\"k\n\020LinkedVpnTunnels" - + "\0223\n\004uris\030\001 \003(\tB%\372A\"\n compute.googleapis." - + "com/VpnTunnel\022\"\n\032site_to_site_data_trans" - + "fer\030\002 \001(\010\"\205\001\n\035LinkedInterconnectAttachme" - + "nts\022@\n\004uris\030\001 \003(\tB2\372A/\n-compute.googleap" - + "is.com/InterconnectAttachment\022\"\n\032site_to" - + "_site_data_transfer\030\002 \001(\010\"\225\001\n\036LinkedRout" - + "erApplianceInstances\022O\n\tinstances\030\001 \003(\0132" - + "<.google.cloud.networkconnectivity.v1.Ro" - + "uterApplianceInstance\022\"\n\032site_to_site_da" - + "ta_transfer\030\002 \001(\010\"l\n\027RouterApplianceInst" - + "ance\022=\n\017virtual_machine\030\001 \001(\tB$\372A!\n\037comp" - + "ute.googleapis.com/Instance\022\022\n\nip_addres" - + "s\030\003 \001(\t*F\n\005State\022\025\n\021STATE_UNSPECIFIED\020\000\022" - + "\014\n\010CREATING\020\001\022\n\n\006ACTIVE\020\002\022\014\n\010DELETING\020\0032" - + "\303\023\n\nHubService\022\267\001\n\010ListHubs\0224.google.clo" - + "ud.networkconnectivity.v1.ListHubsReques" - + "t\0325.google.cloud.networkconnectivity.v1." - + "ListHubsResponse\">\202\323\344\223\002/\022-/v1/{parent=pr" - + "ojects/*/locations/global}/hubs\332A\006parent" - + "\022\244\001\n\006GetHub\0222.google.cloud.networkconnec" - + "tivity.v1.GetHubRequest\032(.google.cloud.n" - + "etworkconnectivity.v1.Hub\"<\202\323\344\223\002/\022-/v1/{" + + "ity.v1.StateB\003\340A\003\022E\n\014routing_vpcs\030\n \003(\0132" + + "/.google.cloud.networkconnectivity.v1.Ro" + + "utingVPC\032-\n\013LabelsEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005" + + "value\030\002 \001(\t:\0028\001:[\352AX\n&networkconnectivit" + + "y.googleapis.com/Hub\022.projects/{project}" + + "/locations/global/hubs/{hub}\">\n\nRoutingV" + + "PC\0220\n\003uri\030\001 \001(\tB#\372A \n\036compute.googleapis" + + ".com/Network\"\276\006\n\005Spoke\022\021\n\004name\030\001 \001(\tB\003\340A" + + "\005\0224\n\013create_time\030\002 \001(\0132\032.google.protobuf" + + ".TimestampB\003\340A\003\0224\n\013update_time\030\003 \001(\0132\032.g" + + "oogle.protobuf.TimestampB\003\340A\003\022F\n\006labels\030" + + "\004 \003(\01326.google.cloud.networkconnectivity" + + ".v1.Spoke.LabelsEntry\022\023\n\013description\030\005 \001" + + "(\t\022;\n\003hub\030\006 \001(\tB.\340A\005\372A(\n&networkconnecti" + + "vity.googleapis.com/Hub\022Q\n\022linked_vpn_tu" + + "nnels\030\021 \001(\01325.google.cloud.networkconnec" + + "tivity.v1.LinkedVpnTunnels\022k\n\037linked_int" + + "erconnect_attachments\030\022 \001(\0132B.google.clo" + + "ud.networkconnectivity.v1.LinkedIntercon" + + "nectAttachments\022n\n!linked_router_applian" + + "ce_instances\030\023 \001(\0132C.google.cloud.networ" + + "kconnectivity.v1.LinkedRouterApplianceIn" + + "stances\022\026\n\tunique_id\030\013 \001(\tB\003\340A\003\022>\n\005state" + + "\030\017 \001(\0162*.google.cloud.networkconnectivit" + + "y.v1.StateB\003\340A\003\032-\n\013LabelsEntry\022\013\n\003key\030\001 " + + "\001(\t\022\r\n\005value\030\002 \001(\t:\0028\001:e\352Ab\n(networkconn" + + "ectivity.googleapis.com/Spoke\0226projects/" + + "{project}/locations/{location}/spokes/{s" + + "poke}\"\225\001\n\017ListHubsRequest\0229\n\006parent\030\001 \001(" + + "\tB)\340A\002\372A#\n!locations.googleapis.com/Loca" + + "tion\022\021\n\tpage_size\030\002 \001(\005\022\022\n\npage_token\030\003 " + + "\001(\t\022\016\n\006filter\030\004 \001(\t\022\020\n\010order_by\030\005 \001(\t\"x\n" + + "\020ListHubsResponse\0226\n\004hubs\030\001 \003(\0132(.google" + + ".cloud.networkconnectivity.v1.Hub\022\027\n\017nex" + + "t_page_token\030\002 \001(\t\022\023\n\013unreachable\030\003 \003(\t\"" + + "M\n\rGetHubRequest\022<\n\004name\030\001 \001(\tB.\340A\002\372A(\n&" + + "networkconnectivity.googleapis.com/Hub\"\267" + + "\001\n\020CreateHubRequest\0229\n\006parent\030\001 \001(\tB)\340A\002" + + "\372A#\n!locations.googleapis.com/Location\022\023" + + "\n\006hub_id\030\002 \001(\tB\003\340A\001\022:\n\003hub\030\003 \001(\0132(.googl" + + "e.cloud.networkconnectivity.v1.HubB\003\340A\002\022" + + "\027\n\nrequest_id\030\004 \001(\tB\003\340A\001\"\235\001\n\020UpdateHubRe" + + "quest\0224\n\013update_mask\030\001 \001(\0132\032.google.prot" + + "obuf.FieldMaskB\003\340A\001\022:\n\003hub\030\002 \001(\0132(.googl" + + "e.cloud.networkconnectivity.v1.HubB\003\340A\002\022" + + "\027\n\nrequest_id\030\003 \001(\tB\003\340A\001\"i\n\020DeleteHubReq" + + "uest\022<\n\004name\030\001 \001(\tB.\340A\002\372A(\n&networkconne" + + "ctivity.googleapis.com/Hub\022\027\n\nrequest_id" + + "\030\002 \001(\tB\003\340A\001\"\227\001\n\021ListSpokesRequest\0229\n\006par" + + "ent\030\001 \001(\tB)\340A\002\372A#\n!locations.googleapis." + + "com/Location\022\021\n\tpage_size\030\002 \001(\005\022\022\n\npage_" + + "token\030\003 \001(\t\022\016\n\006filter\030\004 \001(\t\022\020\n\010order_by\030" + + "\005 \001(\t\"~\n\022ListSpokesResponse\022:\n\006spokes\030\001 " + + "\003(\0132*.google.cloud.networkconnectivity.v" + + "1.Spoke\022\027\n\017next_page_token\030\002 \001(\t\022\023\n\013unre" + + "achable\030\003 \003(\t\"Q\n\017GetSpokeRequest\022>\n\004name" + + "\030\001 \001(\tB0\340A\002\372A*\n(networkconnectivity.goog" + + "leapis.com/Spoke\"\277\001\n\022CreateSpokeRequest\022" + + "9\n\006parent\030\001 \001(\tB)\340A\002\372A#\n!locations.googl" + + "eapis.com/Location\022\025\n\010spoke_id\030\002 \001(\tB\003\340A" + + "\001\022>\n\005spoke\030\003 \001(\0132*.google.cloud.networkc" + + "onnectivity.v1.SpokeB\003\340A\002\022\027\n\nrequest_id\030" + + "\004 \001(\tB\003\340A\001\"\243\001\n\022UpdateSpokeRequest\0224\n\013upd" + + "ate_mask\030\001 \001(\0132\032.google.protobuf.FieldMa" + + "skB\003\340A\001\022>\n\005spoke\030\002 \001(\0132*.google.cloud.ne" + + "tworkconnectivity.v1.SpokeB\003\340A\002\022\027\n\nreque" + + "st_id\030\003 \001(\tB\003\340A\001\"m\n\022DeleteSpokeRequest\022>" + + "\n\004name\030\001 \001(\tB0\340A\002\372A*\n(networkconnectivit" + + "y.googleapis.com/Spoke\022\027\n\nrequest_id\030\002 \001" + + "(\tB\003\340A\001\"k\n\020LinkedVpnTunnels\0223\n\004uris\030\001 \003(" + + "\tB%\372A\"\n compute.googleapis.com/VpnTunnel" + + "\022\"\n\032site_to_site_data_transfer\030\002 \001(\010\"\205\001\n" + + "\035LinkedInterconnectAttachments\022@\n\004uris\030\001" + + " \003(\tB2\372A/\n-compute.googleapis.com/Interc" + + "onnectAttachment\022\"\n\032site_to_site_data_tr" + + "ansfer\030\002 \001(\010\"\225\001\n\036LinkedRouterApplianceIn" + + "stances\022O\n\tinstances\030\001 \003(\0132<.google.clou" + + "d.networkconnectivity.v1.RouterAppliance" + + "Instance\022\"\n\032site_to_site_data_transfer\030\002" + + " \001(\010\"l\n\027RouterApplianceInstance\022=\n\017virtu" + + "al_machine\030\001 \001(\tB$\372A!\n\037compute.googleapi" + + "s.com/Instance\022\022\n\nip_address\030\003 \001(\t*F\n\005St" + + "ate\022\025\n\021STATE_UNSPECIFIED\020\000\022\014\n\010CREATING\020\001" + + "\022\n\n\006ACTIVE\020\002\022\014\n\010DELETING\020\0032\235\020\n\nHubServic" + + "e\022\267\001\n\010ListHubs\0224.google.cloud.networkcon" + + "nectivity.v1.ListHubsRequest\0325.google.cl" + + "oud.networkconnectivity.v1.ListHubsRespo" + + "nse\">\202\323\344\223\002/\022-/v1/{parent=projects/*/loca" + + "tions/global}/hubs\332A\006parent\022\244\001\n\006GetHub\0222" + + ".google.cloud.networkconnectivity.v1.Get" + + "HubRequest\032(.google.cloud.networkconnect" + + "ivity.v1.Hub\"<\202\323\344\223\002/\022-/v1/{name=projects" + + "/*/locations/global/hubs/*}\332A\004name\022\314\001\n\tC" + + "reateHub\0225.google.cloud.networkconnectiv" + + "ity.v1.CreateHubRequest\032\035.google.longrun" + + "ning.Operation\"i\202\323\344\223\0024\"-/v1/{parent=proj" + + "ects/*/locations/global}/hubs:\003hub\332A\021par" + + "ent,hub,hub_id\312A\030\n\003Hub\022\021OperationMetadat" + + "a\022\316\001\n\tUpdateHub\0225.google.cloud.networkco" + + "nnectivity.v1.UpdateHubRequest\032\035.google." + + "longrunning.Operation\"k\202\323\344\223\002821/v1/{hub." + "name=projects/*/locations/global/hubs/*}" - + "\332A\004name\022\314\001\n\tCreateHub\0225.google.cloud.net" - + "workconnectivity.v1.CreateHubRequest\032\035.g" - + "oogle.longrunning.Operation\"i\202\323\344\223\0024\"-/v1" - + "/{parent=projects/*/locations/global}/hu" - + "bs:\003hub\332A\021parent,hub,hub_id\312A\030\n\003Hub\022\021Ope" - + "rationMetadata\022\316\001\n\tUpdateHub\0225.google.cl" - + "oud.networkconnectivity.v1.UpdateHubRequ" - + "est\032\035.google.longrunning.Operation\"k\202\323\344\223" - + "\002821/v1/{hub.name=projects/*/locations/g" - + "lobal/hubs/*}:\003hub\332A\017hub,update_mask\312A\030\n" - + "\003Hub\022\021OperationMetadata\022\314\001\n\tDeleteHub\0225." - + "google.cloud.networkconnectivity.v1.Dele" - + "teHubRequest\032\035.google.longrunning.Operat" - + "ion\"i\202\323\344\223\002/*-/v1/{name=projects/*/locati" - + "ons/global/hubs/*}\332A\004name\312A*\n\025google.pro" - + "tobuf.Empty\022\021OperationMetadata\022\272\001\n\nListS" - + "pokes\0226.google.cloud.networkconnectivity" - + ".v1.ListSpokesRequest\0327.google.cloud.net" - + "workconnectivity.v1.ListSpokesResponse\";" - + "\202\323\344\223\002,\022*/v1/{parent=projects/*/locations" - + "/*}/spokes\332A\006parent\022\247\001\n\010GetSpoke\0224.googl" - + "e.cloud.networkconnectivity.v1.GetSpokeR" - + "equest\032*.google.cloud.networkconnectivit" - + "y.v1.Spoke\"9\202\323\344\223\002,\022*/v1/{name=projects/*" - + "/locations/*/spokes/*}\332A\004name\022\325\001\n\013Create" - + "Spoke\0227.google.cloud.networkconnectivity" - + ".v1.CreateSpokeRequest\032\035.google.longrunn" - + "ing.Operation\"n\202\323\344\223\0023\"*/v1/{parent=proje" - + "cts/*/locations/*}/spokes:\005spoke\332A\025paren" - + "t,spoke,spoke_id\312A\032\n\005Spoke\022\021OperationMet" - + "adata\022\327\001\n\013UpdateSpoke\0227.google.cloud.net" - + "workconnectivity.v1.UpdateSpokeRequest\032\035" - + ".google.longrunning.Operation\"p\202\323\344\223\002920/" - + "v1/{spoke.name=projects/*/locations/*/sp" - + "okes/*}:\005spoke\332A\021spoke,update_mask\312A\032\n\005S" - + "poke\022\021OperationMetadata\022\323\001\n\017DeactivateSp" - + "oke\022;.google.cloud.networkconnectivity.v" - + "1.DeactivateSpokeRequest\032\035.google.longru" - + "nning.Operation\"d\202\323\344\223\002:\"5/v1/{name=proje" - + "cts/*/locations/*/spokes/*}:deactivate:\001" - + "*\332A\004name\312A\032\n\005Spoke\022\021OperationMetadata\022\315\001" - + "\n\rActivateSpoke\0229.google.cloud.networkco" - + "nnectivity.v1.ActivateSpokeRequest\032\035.goo" - + "gle.longrunning.Operation\"b\202\323\344\223\0028\"3/v1/{" - + "name=projects/*/locations/*/spokes/*}:ac" - + "tivate:\001*\332A\004name\312A\032\n\005Spoke\022\021OperationMet" - + "adata\022\315\001\n\013DeleteSpoke\0227.google.cloud.net" - + "workconnectivity.v1.DeleteSpokeRequest\032\035" - + ".google.longrunning.Operation\"f\202\323\344\223\002,**/" - + "v1/{name=projects/*/locations/*/spokes/*" - + "}\332A\004name\312A*\n\025google.protobuf.Empty\022\021Oper" - + "ationMetadata\032V\312A\"networkconnectivity.go" - + "ogleapis.com\322A.https://www.googleapis.co" - + "m/auth/cloud-platformB\221\005\n\'com.google.clo" - + "ud.networkconnectivity.v1B\010HubProtoP\001ZVg" - + "oogle.golang.org/genproto/googleapis/clo" - + "ud/networkconnectivity/v1;networkconnect" - + "ivity\252\002#Google.Cloud.NetworkConnectivity" - + ".V1\312\002#Google\\Cloud\\NetworkConnectivity\\V" - + "1\352\002&Google::Cloud::NetworkConnectivity::" - + "V1\352A`\n compute.googleapis.com/VpnTunnel\022" - + " * A value that controls whether site-to-site data transfer is enabled for - * these resources. If true, routes are propagated between the spoke - * associated with these resources and other spokes in the hub that have data - * transfer enabled. If false, the spoke associated with these resources - * provides connectivity only between the external site and Google Cloud. In - * regions where data transfer is unsupported, you cannot set this field - * to true. + * these resources. This field is set to false by default, but you must set it + * to true. Note that data transfer is available only in supported locations. * * * bool site_to_site_data_transfer = 2; @@ -750,12 +746,8 @@ public Builder addUrisBytes(com.google.protobuf.ByteString value) { * *
      * A value that controls whether site-to-site data transfer is enabled for
-     * these resources. If true, routes are propagated between the spoke
-     * associated with these resources and other spokes in the hub that have data
-     * transfer enabled. If false, the spoke associated with these resources
-     * provides connectivity only between the external site and Google Cloud. In
-     * regions where data transfer is unsupported, you cannot set this field
-     * to true.
+     * these resources. This field is set to false by default, but you must set it
+     * to true. Note that data transfer is available only in supported locations.
      * 
* * bool site_to_site_data_transfer = 2; @@ -771,12 +763,8 @@ public boolean getSiteToSiteDataTransfer() { * *
      * A value that controls whether site-to-site data transfer is enabled for
-     * these resources. If true, routes are propagated between the spoke
-     * associated with these resources and other spokes in the hub that have data
-     * transfer enabled. If false, the spoke associated with these resources
-     * provides connectivity only between the external site and Google Cloud. In
-     * regions where data transfer is unsupported, you cannot set this field
-     * to true.
+     * these resources. This field is set to false by default, but you must set it
+     * to true. Note that data transfer is available only in supported locations.
      * 
* * bool site_to_site_data_transfer = 2; @@ -795,12 +783,8 @@ public Builder setSiteToSiteDataTransfer(boolean value) { * *
      * A value that controls whether site-to-site data transfer is enabled for
-     * these resources. If true, routes are propagated between the spoke
-     * associated with these resources and other spokes in the hub that have data
-     * transfer enabled. If false, the spoke associated with these resources
-     * provides connectivity only between the external site and Google Cloud. In
-     * regions where data transfer is unsupported, you cannot set this field
-     * to true.
+     * these resources. This field is set to false by default, but you must set it
+     * to true. Note that data transfer is available only in supported locations.
      * 
* * bool site_to_site_data_transfer = 2; diff --git a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedInterconnectAttachmentsOrBuilder.java b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedInterconnectAttachmentsOrBuilder.java index cd9d2411..e609e787 100644 --- a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedInterconnectAttachmentsOrBuilder.java +++ b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedInterconnectAttachmentsOrBuilder.java @@ -79,12 +79,8 @@ public interface LinkedInterconnectAttachmentsOrBuilder * *
    * A value that controls whether site-to-site data transfer is enabled for
-   * these resources. If true, routes are propagated between the spoke
-   * associated with these resources and other spokes in the hub that have data
-   * transfer enabled. If false, the spoke associated with these resources
-   * provides connectivity only between the external site and Google Cloud. In
-   * regions where data transfer is unsupported, you cannot set this field
-   * to true.
+   * these resources. This field is set to false by default, but you must set it
+   * to true. Note that data transfer is available only in supported locations.
    * 
* * bool site_to_site_data_transfer = 2; diff --git a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedRouterApplianceInstances.java b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedRouterApplianceInstances.java index 9adc7a80..ed326c17 100644 --- a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedRouterApplianceInstances.java +++ b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedRouterApplianceInstances.java @@ -215,12 +215,8 @@ public com.google.cloud.networkconnectivity.v1.RouterApplianceInstance getInstan * *
    * A value that controls whether site-to-site data transfer is enabled for
-   * these resources. If true, routes are propagated between the spoke
-   * associated with these resources and other spokes in the hub that have data
-   * transfer enabled. If false, the spoke associated with these resources
-   * provides connectivity only between the external site and Google Cloud. In
-   * regions where data transfer is unsupported, you cannot set this field
-   * to true.
+   * these resources. This field is set to false by default, but you must set it
+   * to true. Note that data transfer is available only in supported locations.
    * 
* * bool site_to_site_data_transfer = 2; @@ -1011,12 +1007,8 @@ public Builder removeInstances(int index) { * *
      * A value that controls whether site-to-site data transfer is enabled for
-     * these resources. If true, routes are propagated between the spoke
-     * associated with these resources and other spokes in the hub that have data
-     * transfer enabled. If false, the spoke associated with these resources
-     * provides connectivity only between the external site and Google Cloud. In
-     * regions where data transfer is unsupported, you cannot set this field
-     * to true.
+     * these resources. This field is set to false by default, but you must set it
+     * to true. Note that data transfer is available only in supported locations.
      * 
* * bool site_to_site_data_transfer = 2; @@ -1032,12 +1024,8 @@ public boolean getSiteToSiteDataTransfer() { * *
      * A value that controls whether site-to-site data transfer is enabled for
-     * these resources. If true, routes are propagated between the spoke
-     * associated with these resources and other spokes in the hub that have data
-     * transfer enabled. If false, the spoke associated with these resources
-     * provides connectivity only between the external site and Google Cloud. In
-     * regions where data transfer is unsupported, you cannot set this field
-     * to true.
+     * these resources. This field is set to false by default, but you must set it
+     * to true. Note that data transfer is available only in supported locations.
      * 
* * bool site_to_site_data_transfer = 2; @@ -1056,12 +1044,8 @@ public Builder setSiteToSiteDataTransfer(boolean value) { * *
      * A value that controls whether site-to-site data transfer is enabled for
-     * these resources. If true, routes are propagated between the spoke
-     * associated with these resources and other spokes in the hub that have data
-     * transfer enabled. If false, the spoke associated with these resources
-     * provides connectivity only between the external site and Google Cloud. In
-     * regions where data transfer is unsupported, you cannot set this field
-     * to true.
+     * these resources. This field is set to false by default, but you must set it
+     * to true. Note that data transfer is available only in supported locations.
      * 
* * bool site_to_site_data_transfer = 2; diff --git a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedRouterApplianceInstancesOrBuilder.java b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedRouterApplianceInstancesOrBuilder.java index 07060373..ef614366 100644 --- a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedRouterApplianceInstancesOrBuilder.java +++ b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedRouterApplianceInstancesOrBuilder.java @@ -87,12 +87,8 @@ com.google.cloud.networkconnectivity.v1.RouterApplianceInstanceOrBuilder getInst * *
    * A value that controls whether site-to-site data transfer is enabled for
-   * these resources. If true, routes are propagated between the spoke
-   * associated with these resources and other spokes in the hub that have data
-   * transfer enabled. If false, the spoke associated with these resources
-   * provides connectivity only between the external site and Google Cloud. In
-   * regions where data transfer is unsupported, you cannot set this field
-   * to true.
+   * these resources. This field is set to false by default, but you must set it
+   * to true. Note that data transfer is available only in supported locations.
    * 
* * bool site_to_site_data_transfer = 2; diff --git a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpnTunnels.java b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpnTunnels.java index 5f4fbafe..fcd89349 100644 --- a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpnTunnels.java +++ b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpnTunnels.java @@ -194,12 +194,8 @@ public com.google.protobuf.ByteString getUrisBytes(int index) { * *
    * A value that controls whether site-to-site data transfer is enabled for
-   * these resources. If true, routes are propagated between the spoke
-   * associated with these resources and other spokes in the hub that have data
-   * transfer enabled. If false, the spoke associated with these resources
-   * provides connectivity only between the external site and Google Cloud. In
-   * regions where data transfer is unsupported, you cannot set this field
-   * to true.
+   * these resources. This field is set to false by default, but you must set it
+   * to true. Note that data transfer is available only in supported locations.
    * 
* * bool site_to_site_data_transfer = 2; @@ -742,12 +738,8 @@ public Builder addUrisBytes(com.google.protobuf.ByteString value) { * *
      * A value that controls whether site-to-site data transfer is enabled for
-     * these resources. If true, routes are propagated between the spoke
-     * associated with these resources and other spokes in the hub that have data
-     * transfer enabled. If false, the spoke associated with these resources
-     * provides connectivity only between the external site and Google Cloud. In
-     * regions where data transfer is unsupported, you cannot set this field
-     * to true.
+     * these resources. This field is set to false by default, but you must set it
+     * to true. Note that data transfer is available only in supported locations.
      * 
* * bool site_to_site_data_transfer = 2; @@ -763,12 +755,8 @@ public boolean getSiteToSiteDataTransfer() { * *
      * A value that controls whether site-to-site data transfer is enabled for
-     * these resources. If true, routes are propagated between the spoke
-     * associated with these resources and other spokes in the hub that have data
-     * transfer enabled. If false, the spoke associated with these resources
-     * provides connectivity only between the external site and Google Cloud. In
-     * regions where data transfer is unsupported, you cannot set this field
-     * to true.
+     * these resources. This field is set to false by default, but you must set it
+     * to true. Note that data transfer is available only in supported locations.
      * 
* * bool site_to_site_data_transfer = 2; @@ -787,12 +775,8 @@ public Builder setSiteToSiteDataTransfer(boolean value) { * *
      * A value that controls whether site-to-site data transfer is enabled for
-     * these resources. If true, routes are propagated between the spoke
-     * associated with these resources and other spokes in the hub that have data
-     * transfer enabled. If false, the spoke associated with these resources
-     * provides connectivity only between the external site and Google Cloud. In
-     * regions where data transfer is unsupported, you cannot set this field
-     * to true.
+     * these resources. This field is set to false by default, but you must set it
+     * to true. Note that data transfer is available only in supported locations.
      * 
* * bool site_to_site_data_transfer = 2; diff --git a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpnTunnelsOrBuilder.java b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpnTunnelsOrBuilder.java index 8f66f05c..a7e22138 100644 --- a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpnTunnelsOrBuilder.java +++ b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpnTunnelsOrBuilder.java @@ -79,12 +79,8 @@ public interface LinkedVpnTunnelsOrBuilder * *
    * A value that controls whether site-to-site data transfer is enabled for
-   * these resources. If true, routes are propagated between the spoke
-   * associated with these resources and other spokes in the hub that have data
-   * transfer enabled. If false, the spoke associated with these resources
-   * provides connectivity only between the external site and Google Cloud. In
-   * regions where data transfer is unsupported, you cannot set this field
-   * to true.
+   * these resources. This field is set to false by default, but you must set it
+   * to true. Note that data transfer is available only in supported locations.
    * 
* * bool site_to_site_data_transfer = 2; diff --git a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/OperationMetadata.java b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/OperationMetadata.java index 05c4df9c..06a93211 100644 --- a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/OperationMetadata.java +++ b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/OperationMetadata.java @@ -422,7 +422,7 @@ public com.google.protobuf.ByteString getStatusMessageBytes() { * *
    * Output only. Identifies whether the user has requested cancellation
-   * of the operation. Operations that have successfully been cancelled
+   * of the operation. Operations that have been cancelled successfully
    * have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1,
    * corresponding to `Code.CANCELLED`.
    * 
@@ -1636,7 +1636,7 @@ public Builder setStatusMessageBytes(com.google.protobuf.ByteString value) { * *
      * Output only. Identifies whether the user has requested cancellation
-     * of the operation. Operations that have successfully been cancelled
+     * of the operation. Operations that have been cancelled successfully
      * have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1,
      * corresponding to `Code.CANCELLED`.
      * 
@@ -1654,7 +1654,7 @@ public boolean getRequestedCancellation() { * *
      * Output only. Identifies whether the user has requested cancellation
-     * of the operation. Operations that have successfully been cancelled
+     * of the operation. Operations that have been cancelled successfully
      * have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1,
      * corresponding to `Code.CANCELLED`.
      * 
@@ -1675,7 +1675,7 @@ public Builder setRequestedCancellation(boolean value) { * *
      * Output only. Identifies whether the user has requested cancellation
-     * of the operation. Operations that have successfully been cancelled
+     * of the operation. Operations that have been cancelled successfully
      * have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1,
      * corresponding to `Code.CANCELLED`.
      * 
diff --git a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/OperationMetadataOrBuilder.java b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/OperationMetadataOrBuilder.java index 4b315277..217a088b 100644 --- a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/OperationMetadataOrBuilder.java +++ b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/OperationMetadataOrBuilder.java @@ -179,7 +179,7 @@ public interface OperationMetadataOrBuilder * *
    * Output only. Identifies whether the user has requested cancellation
-   * of the operation. Operations that have successfully been cancelled
+   * of the operation. Operations that have been cancelled successfully
    * have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1,
    * corresponding to `Code.CANCELLED`.
    * 
diff --git a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/RoutingVPC.java b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/RoutingVPC.java new file mode 100644 index 00000000..b16da707 --- /dev/null +++ b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/RoutingVPC.java @@ -0,0 +1,638 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/networkconnectivity/v1/hub.proto + +package com.google.cloud.networkconnectivity.v1; + +/** + * + * + *
+ * RoutingsVPC contains information about a VPC network that is associated with
+ * a hub's spokes.
+ * 
+ * + * Protobuf type {@code google.cloud.networkconnectivity.v1.RoutingVPC} + */ +public final class RoutingVPC extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.networkconnectivity.v1.RoutingVPC) + RoutingVPCOrBuilder { + private static final long serialVersionUID = 0L; + // Use RoutingVPC.newBuilder() to construct. + private RoutingVPC(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private RoutingVPC() { + uri_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new RoutingVPC(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private RoutingVPC( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + uri_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_RoutingVPC_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_RoutingVPC_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.RoutingVPC.class, + com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder.class); + } + + public static final int URI_FIELD_NUMBER = 1; + private volatile java.lang.Object uri_; + /** + * + * + *
+   * The URI of a VPC network.
+   * 
+ * + * string uri = 1 [(.google.api.resource_reference) = { ... } + * + * @return The uri. + */ + @java.lang.Override + public java.lang.String getUri() { + java.lang.Object ref = uri_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uri_ = s; + return s; + } + } + /** + * + * + *
+   * The URI of a VPC network.
+   * 
+ * + * string uri = 1 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for uri. + */ + @java.lang.Override + public com.google.protobuf.ByteString getUriBytes() { + java.lang.Object ref = uri_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getUriBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, uri_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getUriBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, uri_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.networkconnectivity.v1.RoutingVPC)) { + return super.equals(obj); + } + com.google.cloud.networkconnectivity.v1.RoutingVPC other = + (com.google.cloud.networkconnectivity.v1.RoutingVPC) obj; + + if (!getUri().equals(other.getUri())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + URI_FIELD_NUMBER; + hash = (53 * hash) + getUri().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.networkconnectivity.v1.RoutingVPC parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.RoutingVPC parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.RoutingVPC parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.RoutingVPC parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.RoutingVPC parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.RoutingVPC parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.RoutingVPC parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.RoutingVPC parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.RoutingVPC parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.RoutingVPC parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.RoutingVPC parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.RoutingVPC parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.networkconnectivity.v1.RoutingVPC prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * RoutingsVPC contains information about a VPC network that is associated with
+   * a hub's spokes.
+   * 
+ * + * Protobuf type {@code google.cloud.networkconnectivity.v1.RoutingVPC} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.RoutingVPC) + com.google.cloud.networkconnectivity.v1.RoutingVPCOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_RoutingVPC_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_RoutingVPC_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.RoutingVPC.class, + com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder.class); + } + + // Construct using com.google.cloud.networkconnectivity.v1.RoutingVPC.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + uri_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_RoutingVPC_descriptor; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.RoutingVPC getDefaultInstanceForType() { + return com.google.cloud.networkconnectivity.v1.RoutingVPC.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.RoutingVPC build() { + com.google.cloud.networkconnectivity.v1.RoutingVPC result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.RoutingVPC buildPartial() { + com.google.cloud.networkconnectivity.v1.RoutingVPC result = + new com.google.cloud.networkconnectivity.v1.RoutingVPC(this); + result.uri_ = uri_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.networkconnectivity.v1.RoutingVPC) { + return mergeFrom((com.google.cloud.networkconnectivity.v1.RoutingVPC) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.networkconnectivity.v1.RoutingVPC other) { + if (other == com.google.cloud.networkconnectivity.v1.RoutingVPC.getDefaultInstance()) + return this; + if (!other.getUri().isEmpty()) { + uri_ = other.uri_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.networkconnectivity.v1.RoutingVPC parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.networkconnectivity.v1.RoutingVPC) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object uri_ = ""; + /** + * + * + *
+     * The URI of a VPC network.
+     * 
+ * + * string uri = 1 [(.google.api.resource_reference) = { ... } + * + * @return The uri. + */ + public java.lang.String getUri() { + java.lang.Object ref = uri_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uri_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The URI of a VPC network.
+     * 
+ * + * string uri = 1 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for uri. + */ + public com.google.protobuf.ByteString getUriBytes() { + java.lang.Object ref = uri_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The URI of a VPC network.
+     * 
+ * + * string uri = 1 [(.google.api.resource_reference) = { ... } + * + * @param value The uri to set. + * @return This builder for chaining. + */ + public Builder setUri(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + uri_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The URI of a VPC network.
+     * 
+ * + * string uri = 1 [(.google.api.resource_reference) = { ... } + * + * @return This builder for chaining. + */ + public Builder clearUri() { + + uri_ = getDefaultInstance().getUri(); + onChanged(); + return this; + } + /** + * + * + *
+     * The URI of a VPC network.
+     * 
+ * + * string uri = 1 [(.google.api.resource_reference) = { ... } + * + * @param value The bytes for uri to set. + * @return This builder for chaining. + */ + public Builder setUriBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + uri_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.networkconnectivity.v1.RoutingVPC) + } + + // @@protoc_insertion_point(class_scope:google.cloud.networkconnectivity.v1.RoutingVPC) + private static final com.google.cloud.networkconnectivity.v1.RoutingVPC DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.networkconnectivity.v1.RoutingVPC(); + } + + public static com.google.cloud.networkconnectivity.v1.RoutingVPC getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public RoutingVPC parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new RoutingVPC(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.RoutingVPC getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/RoutingVPCOrBuilder.java b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/RoutingVPCOrBuilder.java new file mode 100644 index 00000000..df0029ae --- /dev/null +++ b/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/RoutingVPCOrBuilder.java @@ -0,0 +1,50 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/networkconnectivity/v1/hub.proto + +package com.google.cloud.networkconnectivity.v1; + +public interface RoutingVPCOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.networkconnectivity.v1.RoutingVPC) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The URI of a VPC network.
+   * 
+ * + * string uri = 1 [(.google.api.resource_reference) = { ... } + * + * @return The uri. + */ + java.lang.String getUri(); + /** + * + * + *
+   * The URI of a VPC network.
+   * 
+ * + * string uri = 1 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for uri. + */ + com.google.protobuf.ByteString getUriBytes(); +} diff --git a/proto-google-cloud-networkconnectivity-v1/src/main/proto/google/cloud/networkconnectivity/v1/common.proto b/proto-google-cloud-networkconnectivity-v1/src/main/proto/google/cloud/networkconnectivity/v1/common.proto index 014e23f0..2d999b7e 100644 --- a/proto-google-cloud-networkconnectivity-v1/src/main/proto/google/cloud/networkconnectivity/v1/common.proto +++ b/proto-google-cloud-networkconnectivity-v1/src/main/proto/google/cloud/networkconnectivity/v1/common.proto @@ -46,7 +46,7 @@ message OperationMetadata { string status_message = 5 [(google.api.field_behavior) = OUTPUT_ONLY]; // Output only. Identifies whether the user has requested cancellation - // of the operation. Operations that have successfully been cancelled + // of the operation. Operations that have been cancelled successfully // have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1, // corresponding to `Code.CANCELLED`. bool requested_cancellation = 6 [(google.api.field_behavior) = OUTPUT_ONLY]; diff --git a/proto-google-cloud-networkconnectivity-v1/src/main/proto/google/cloud/networkconnectivity/v1/hub.proto b/proto-google-cloud-networkconnectivity-v1/src/main/proto/google/cloud/networkconnectivity/v1/hub.proto index ac43a231..c9535dc4 100644 --- a/proto-google-cloud-networkconnectivity-v1/src/main/proto/google/cloud/networkconnectivity/v1/hub.proto +++ b/proto-google-cloud-networkconnectivity-v1/src/main/proto/google/cloud/networkconnectivity/v1/hub.proto @@ -151,35 +151,6 @@ service HubService { }; } - // Deactivates the specified spoke. Deactivating keeps the spoke information - // for future re-activation, but disconnects the Google Cloud network from - // non-Google-Cloud network. - rpc DeactivateSpoke(DeactivateSpokeRequest) returns (google.longrunning.Operation) { - option (google.api.http) = { - post: "/v1/{name=projects/*/locations/*/spokes/*}:deactivate" - body: "*" - }; - option (google.api.method_signature) = "name"; - option (google.longrunning.operation_info) = { - response_type: "Spoke" - metadata_type: "OperationMetadata" - }; - } - - // Activates the specified spoke. Activating reconnects the Google Cloud - // network with the non-Google-Cloud network. - rpc ActivateSpoke(ActivateSpokeRequest) returns (google.longrunning.Operation) { - option (google.api.http) = { - post: "/v1/{name=projects/*/locations/*/spokes/*}:activate" - body: "*" - }; - option (google.api.method_signature) = "name"; - option (google.longrunning.operation_info) = { - response_type: "Spoke" - metadata_type: "OperationMetadata" - }; - } - // Deletes the specified spoke. rpc DeleteSpoke(DeleteSpokeRequest) returns (google.longrunning.Operation) { option (google.api.http) = { @@ -228,6 +199,14 @@ message Hub { // Output only. The current lifecycle state of this hub. State state = 9 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // The VPC network associated with this hub's spokes. All of the VPN tunnels, + // VLAN attachments, and router appliance instances referenced by this hub's + // spokes must belong to this VPC network. + // + // This field is read-only. Network Connectivity Center automatically + // populates it based on the set of spokes attached to the hub. + repeated RoutingVPC routing_vpcs = 10; } // The State enum represents the lifecycle stage of a Network Connectivity @@ -246,6 +225,15 @@ enum State { DELETING = 3; } +// RoutingsVPC contains information about a VPC network that is associated with +// a hub's spokes. +message RoutingVPC { + // The URI of a VPC network. + string uri = 1 [(google.api.resource_reference) = { + type: "compute.googleapis.com/Network" + }]; +} + // A spoke represents a connection between your Google Cloud network resources // and a non-Google-Cloud network. // @@ -578,60 +566,6 @@ message DeleteSpokeRequest { string request_id = 2 [(google.api.field_behavior) = OPTIONAL]; } -// The request for [HubService.DeactivateSpoke][google.cloud.networkconnectivity.v1.HubService.DeactivateSpoke]. -message DeactivateSpokeRequest { - // Required. The name of the spoke to deactivate. - string name = 1 [ - (google.api.field_behavior) = REQUIRED, - (google.api.resource_reference) = { - type: "networkconnectivity.googleapis.com/Spoke" - } - ]; - - // Optional. A unique request ID (optional). If you specify this ID, you can use it - // in cases when you need to retry your request. When you need to retry, this - // ID lets the server know that it can ignore the request if it has already - // been completed. The server guarantees that for at least 60 minutes after - // the first request. - // - // For example, consider a situation where you make an initial request and - // the request times out. If you make the request again with the same request - // ID, the server can check to see whether the original operation - // was received. If it was, the server ignores the second request. This - // behavior prevents clients from mistakenly creating duplicate commitments. - // - // The request ID must be a valid UUID, with the exception that zero UUID is - // not supported (00000000-0000-0000-0000-000000000000). - string request_id = 2 [(google.api.field_behavior) = OPTIONAL]; -} - -// The request for [HubService.ActivateSpoke][google.cloud.networkconnectivity.v1.HubService.ActivateSpoke]. -message ActivateSpokeRequest { - // Required. The name of the spoke to activate. - string name = 1 [ - (google.api.field_behavior) = REQUIRED, - (google.api.resource_reference) = { - type: "networkconnectivity.googleapis.com/Spoke" - } - ]; - - // Optional. A unique request ID (optional). If you specify this ID, you can use it - // in cases when you need to retry your request. When you need to retry, this - // ID lets the server know that it can ignore the request if it has already - // been completed. The server guarantees that for at least 60 minutes after - // the first request. - // - // For example, consider a situation where you make an initial request and - // the request times out. If you make the request again with the same request - // ID, the server can check to see whether the original operation - // was received. If it was, the server ignores the second request. This - // behavior prevents clients from mistakenly creating duplicate commitments. - // - // The request ID must be a valid UUID, with the exception that zero UUID is - // not supported (00000000-0000-0000-0000-000000000000). - string request_id = 2 [(google.api.field_behavior) = OPTIONAL]; -} - // A collection of Cloud VPN tunnel resources. These resources should be // redundant HA VPN tunnels that all advertise the same prefixes to Google // Cloud. Alternatively, in a passive/active configuration, all tunnels @@ -643,12 +577,8 @@ message LinkedVpnTunnels { }]; // A value that controls whether site-to-site data transfer is enabled for - // these resources. If true, routes are propagated between the spoke - // associated with these resources and other spokes in the hub that have data - // transfer enabled. If false, the spoke associated with these resources - // provides connectivity only between the external site and Google Cloud. In - // regions where data transfer is unsupported, you cannot set this field - // to true. + // these resources. This field is set to false by default, but you must set it + // to true. Note that data transfer is available only in supported locations. bool site_to_site_data_transfer = 2; } @@ -663,12 +593,8 @@ message LinkedInterconnectAttachments { }]; // A value that controls whether site-to-site data transfer is enabled for - // these resources. If true, routes are propagated between the spoke - // associated with these resources and other spokes in the hub that have data - // transfer enabled. If false, the spoke associated with these resources - // provides connectivity only between the external site and Google Cloud. In - // regions where data transfer is unsupported, you cannot set this field - // to true. + // these resources. This field is set to false by default, but you must set it + // to true. Note that data transfer is available only in supported locations. bool site_to_site_data_transfer = 2; } @@ -680,12 +606,8 @@ message LinkedRouterApplianceInstances { repeated RouterApplianceInstance instances = 1; // A value that controls whether site-to-site data transfer is enabled for - // these resources. If true, routes are propagated between the spoke - // associated with these resources and other spokes in the hub that have data - // transfer enabled. If false, the spoke associated with these resources - // provides connectivity only between the external site and Google Cloud. In - // regions where data transfer is unsupported, you cannot set this field - // to true. + // these resources. This field is set to false by default, but you must set it + // to true. Note that data transfer is available only in supported locations. bool site_to_site_data_transfer = 2; }