Skip to content

Commit d06d94e

Browse files
Google APIscopybara-github
authored andcommitted
fix!: Remove ActivateSpoke and DeactivateSpoke methods
BREAKING_CHANGE: 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 PiperOrigin-RevId: 392500501
1 parent a5b180f commit d06d94e

2 files changed

Lines changed: 24 additions & 102 deletions

File tree

google/cloud/networkconnectivity/v1/common.proto

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ message OperationMetadata {
4646
string status_message = 5 [(google.api.field_behavior) = OUTPUT_ONLY];
4747

4848
// Output only. Identifies whether the user has requested cancellation
49-
// of the operation. Operations that have successfully been cancelled
49+
// of the operation. Operations that have been cancelled successfully
5050
// have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1,
5151
// corresponding to `Code.CANCELLED`.
5252
bool requested_cancellation = 6 [(google.api.field_behavior) = OUTPUT_ONLY];

google/cloud/networkconnectivity/v1/hub.proto

Lines changed: 23 additions & 101 deletions
Original file line numberDiff line numberDiff line change
@@ -151,35 +151,6 @@ service HubService {
151151
};
152152
}
153153

154-
// Deactivates the specified spoke. Deactivating keeps the spoke information
155-
// for future re-activation, but disconnects the Google Cloud network from
156-
// non-Google-Cloud network.
157-
rpc DeactivateSpoke(DeactivateSpokeRequest) returns (google.longrunning.Operation) {
158-
option (google.api.http) = {
159-
post: "/v1/{name=projects/*/locations/*/spokes/*}:deactivate"
160-
body: "*"
161-
};
162-
option (google.api.method_signature) = "name";
163-
option (google.longrunning.operation_info) = {
164-
response_type: "Spoke"
165-
metadata_type: "OperationMetadata"
166-
};
167-
}
168-
169-
// Activates the specified spoke. Activating reconnects the Google Cloud
170-
// network with the non-Google-Cloud network.
171-
rpc ActivateSpoke(ActivateSpokeRequest) returns (google.longrunning.Operation) {
172-
option (google.api.http) = {
173-
post: "/v1/{name=projects/*/locations/*/spokes/*}:activate"
174-
body: "*"
175-
};
176-
option (google.api.method_signature) = "name";
177-
option (google.longrunning.operation_info) = {
178-
response_type: "Spoke"
179-
metadata_type: "OperationMetadata"
180-
};
181-
}
182-
183154
// Deletes the specified spoke.
184155
rpc DeleteSpoke(DeleteSpokeRequest) returns (google.longrunning.Operation) {
185156
option (google.api.http) = {
@@ -228,6 +199,14 @@ message Hub {
228199

229200
// Output only. The current lifecycle state of this hub.
230201
State state = 9 [(google.api.field_behavior) = OUTPUT_ONLY];
202+
203+
// The VPC network associated with this hub's spokes. All of the VPN tunnels,
204+
// VLAN attachments, and router appliance instances referenced by this hub's
205+
// spokes must belong to this VPC network.
206+
//
207+
// This field is read-only. Network Connectivity Center automatically
208+
// populates it based on the set of spokes attached to the hub.
209+
repeated RoutingVPC routing_vpcs = 10;
231210
}
232211

233212
// The State enum represents the lifecycle stage of a Network Connectivity
@@ -246,6 +225,15 @@ enum State {
246225
DELETING = 3;
247226
}
248227

228+
// RoutingsVPC contains information about a VPC network that is associated with
229+
// a hub's spokes.
230+
message RoutingVPC {
231+
// The URI of a VPC network.
232+
string uri = 1 [(google.api.resource_reference) = {
233+
type: "compute.googleapis.com/Network"
234+
}];
235+
}
236+
249237
// A spoke represents a connection between your Google Cloud network resources
250238
// and a non-Google-Cloud network.
251239
//
@@ -578,60 +566,6 @@ message DeleteSpokeRequest {
578566
string request_id = 2 [(google.api.field_behavior) = OPTIONAL];
579567
}
580568

581-
// The request for [HubService.DeactivateSpoke][google.cloud.networkconnectivity.v1.HubService.DeactivateSpoke].
582-
message DeactivateSpokeRequest {
583-
// Required. The name of the spoke to deactivate.
584-
string name = 1 [
585-
(google.api.field_behavior) = REQUIRED,
586-
(google.api.resource_reference) = {
587-
type: "networkconnectivity.googleapis.com/Spoke"
588-
}
589-
];
590-
591-
// Optional. A unique request ID (optional). If you specify this ID, you can use it
592-
// in cases when you need to retry your request. When you need to retry, this
593-
// ID lets the server know that it can ignore the request if it has already
594-
// been completed. The server guarantees that for at least 60 minutes after
595-
// the first request.
596-
//
597-
// For example, consider a situation where you make an initial request and
598-
// the request times out. If you make the request again with the same request
599-
// ID, the server can check to see whether the original operation
600-
// was received. If it was, the server ignores the second request. This
601-
// behavior prevents clients from mistakenly creating duplicate commitments.
602-
//
603-
// The request ID must be a valid UUID, with the exception that zero UUID is
604-
// not supported (00000000-0000-0000-0000-000000000000).
605-
string request_id = 2 [(google.api.field_behavior) = OPTIONAL];
606-
}
607-
608-
// The request for [HubService.ActivateSpoke][google.cloud.networkconnectivity.v1.HubService.ActivateSpoke].
609-
message ActivateSpokeRequest {
610-
// Required. The name of the spoke to activate.
611-
string name = 1 [
612-
(google.api.field_behavior) = REQUIRED,
613-
(google.api.resource_reference) = {
614-
type: "networkconnectivity.googleapis.com/Spoke"
615-
}
616-
];
617-
618-
// Optional. A unique request ID (optional). If you specify this ID, you can use it
619-
// in cases when you need to retry your request. When you need to retry, this
620-
// ID lets the server know that it can ignore the request if it has already
621-
// been completed. The server guarantees that for at least 60 minutes after
622-
// the first request.
623-
//
624-
// For example, consider a situation where you make an initial request and
625-
// the request times out. If you make the request again with the same request
626-
// ID, the server can check to see whether the original operation
627-
// was received. If it was, the server ignores the second request. This
628-
// behavior prevents clients from mistakenly creating duplicate commitments.
629-
//
630-
// The request ID must be a valid UUID, with the exception that zero UUID is
631-
// not supported (00000000-0000-0000-0000-000000000000).
632-
string request_id = 2 [(google.api.field_behavior) = OPTIONAL];
633-
}
634-
635569
// A collection of Cloud VPN tunnel resources. These resources should be
636570
// redundant HA VPN tunnels that all advertise the same prefixes to Google
637571
// Cloud. Alternatively, in a passive/active configuration, all tunnels
@@ -643,12 +577,8 @@ message LinkedVpnTunnels {
643577
}];
644578

645579
// A value that controls whether site-to-site data transfer is enabled for
646-
// these resources. If true, routes are propagated between the spoke
647-
// associated with these resources and other spokes in the hub that have data
648-
// transfer enabled. If false, the spoke associated with these resources
649-
// provides connectivity only between the external site and Google Cloud. In
650-
// regions where data transfer is unsupported, you cannot set this field
651-
// to true.
580+
// these resources. This field is set to false by default, but you must set it
581+
// to true. Note that data transfer is available only in supported locations.
652582
bool site_to_site_data_transfer = 2;
653583
}
654584

@@ -663,12 +593,8 @@ message LinkedInterconnectAttachments {
663593
}];
664594

665595
// A value that controls whether site-to-site data transfer is enabled for
666-
// these resources. If true, routes are propagated between the spoke
667-
// associated with these resources and other spokes in the hub that have data
668-
// transfer enabled. If false, the spoke associated with these resources
669-
// provides connectivity only between the external site and Google Cloud. In
670-
// regions where data transfer is unsupported, you cannot set this field
671-
// to true.
596+
// these resources. This field is set to false by default, but you must set it
597+
// to true. Note that data transfer is available only in supported locations.
672598
bool site_to_site_data_transfer = 2;
673599
}
674600

@@ -680,12 +606,8 @@ message LinkedRouterApplianceInstances {
680606
repeated RouterApplianceInstance instances = 1;
681607

682608
// A value that controls whether site-to-site data transfer is enabled for
683-
// these resources. If true, routes are propagated between the spoke
684-
// associated with these resources and other spokes in the hub that have data
685-
// transfer enabled. If false, the spoke associated with these resources
686-
// provides connectivity only between the external site and Google Cloud. In
687-
// regions where data transfer is unsupported, you cannot set this field
688-
// to true.
609+
// these resources. This field is set to false by default, but you must set it
610+
// to true. Note that data transfer is available only in supported locations.
689611
bool site_to_site_data_transfer = 2;
690612
}
691613

0 commit comments

Comments
 (0)