Skip to content

Commit c18942b

Browse files
feat: [networkmanagement] expose the new vpcflowlogs api proto (#5606)
* feat: expose the new vpcflowlogs api proto PiperOrigin-RevId: 660275659 Source-Link: googleapis/googleapis@d894629 Source-Link: googleapis/googleapis-gen@688b56a Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLW5ldHdvcmttYW5hZ2VtZW50Ly5Pd2xCb3QueWFtbCIsImgiOiI2ODhiNTZhN2ExZTRlNmY3M2UzZTA2MTc3OTQxNTMwOGNiODc5NTVhIn0= * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --------- Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com> Co-authored-by: Daniel Bankhead <[email protected]>
1 parent 700a937 commit c18942b

22 files changed

Lines changed: 9634 additions & 2 deletions

packages/google-cloud-networkmanagement/README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,11 @@ Samples are in the [`samples/`](https://github.com/googleapis/google-cloud-node/
9999
| Reachability_service.list_connectivity_tests | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-networkmanagement/samples/generated/v1beta1/reachability_service.list_connectivity_tests.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-networkmanagement/samples/generated/v1beta1/reachability_service.list_connectivity_tests.js,packages/google-cloud-networkmanagement/samples/README.md) |
100100
| Reachability_service.rerun_connectivity_test | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-networkmanagement/samples/generated/v1beta1/reachability_service.rerun_connectivity_test.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-networkmanagement/samples/generated/v1beta1/reachability_service.rerun_connectivity_test.js,packages/google-cloud-networkmanagement/samples/README.md) |
101101
| Reachability_service.update_connectivity_test | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-networkmanagement/samples/generated/v1beta1/reachability_service.update_connectivity_test.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-networkmanagement/samples/generated/v1beta1/reachability_service.update_connectivity_test.js,packages/google-cloud-networkmanagement/samples/README.md) |
102+
| Vpc_flow_logs_service.create_vpc_flow_logs_config | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-networkmanagement/samples/generated/v1beta1/vpc_flow_logs_service.create_vpc_flow_logs_config.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-networkmanagement/samples/generated/v1beta1/vpc_flow_logs_service.create_vpc_flow_logs_config.js,packages/google-cloud-networkmanagement/samples/README.md) |
103+
| Vpc_flow_logs_service.delete_vpc_flow_logs_config | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-networkmanagement/samples/generated/v1beta1/vpc_flow_logs_service.delete_vpc_flow_logs_config.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-networkmanagement/samples/generated/v1beta1/vpc_flow_logs_service.delete_vpc_flow_logs_config.js,packages/google-cloud-networkmanagement/samples/README.md) |
104+
| Vpc_flow_logs_service.get_vpc_flow_logs_config | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-networkmanagement/samples/generated/v1beta1/vpc_flow_logs_service.get_vpc_flow_logs_config.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-networkmanagement/samples/generated/v1beta1/vpc_flow_logs_service.get_vpc_flow_logs_config.js,packages/google-cloud-networkmanagement/samples/README.md) |
105+
| Vpc_flow_logs_service.list_vpc_flow_logs_configs | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-networkmanagement/samples/generated/v1beta1/vpc_flow_logs_service.list_vpc_flow_logs_configs.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-networkmanagement/samples/generated/v1beta1/vpc_flow_logs_service.list_vpc_flow_logs_configs.js,packages/google-cloud-networkmanagement/samples/README.md) |
106+
| Vpc_flow_logs_service.update_vpc_flow_logs_config | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-networkmanagement/samples/generated/v1beta1/vpc_flow_logs_service.update_vpc_flow_logs_config.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-networkmanagement/samples/generated/v1beta1/vpc_flow_logs_service.update_vpc_flow_logs_config.js,packages/google-cloud-networkmanagement/samples/README.md) |
102107
| Quickstart | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-networkmanagement/samples/quickstart.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-networkmanagement/samples/quickstart.js,packages/google-cloud-networkmanagement/samples/README.md) |
103108

104109

Lines changed: 228 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,228 @@
1+
// Copyright 2024 Google LLC
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
syntax = "proto3";
16+
17+
package google.cloud.networkmanagement.v1beta1;
18+
19+
import "google/api/annotations.proto";
20+
import "google/api/client.proto";
21+
import "google/api/field_behavior.proto";
22+
import "google/api/resource.proto";
23+
import "google/cloud/networkmanagement/v1beta1/reachability.proto";
24+
import "google/cloud/networkmanagement/v1beta1/vpc_flow_logs_config.proto";
25+
import "google/longrunning/operations.proto";
26+
import "google/protobuf/empty.proto";
27+
import "google/protobuf/field_mask.proto";
28+
29+
option csharp_namespace = "Google.Cloud.NetworkManagement.V1Beta1";
30+
option go_package = "cloud.google.com/go/networkmanagement/apiv1beta1/networkmanagementpb;networkmanagementpb";
31+
option java_multiple_files = true;
32+
option java_outer_classname = "VpcFlowLogsProto";
33+
option java_package = "com.google.cloud.networkmanagement.v1beta1";
34+
option php_namespace = "Google\\Cloud\\NetworkManagement\\V1beta1";
35+
option ruby_package = "Google::Cloud::NetworkManagement::V1beta1";
36+
37+
// The VPC Flow Logs service in the Google Cloud Network Management API provides
38+
// configurations that generate Flow Logs. The service and the configuration
39+
// resources created using this service are global.
40+
service VpcFlowLogsService {
41+
option (google.api.default_host) = "networkmanagement.googleapis.com";
42+
option (google.api.oauth_scopes) =
43+
"https://www.googleapis.com/auth/cloud-platform";
44+
45+
// Lists all `VpcFlowLogsConfigs` in a given project.
46+
rpc ListVpcFlowLogsConfigs(ListVpcFlowLogsConfigsRequest)
47+
returns (ListVpcFlowLogsConfigsResponse) {
48+
option (google.api.http) = {
49+
get: "/v1beta1/{parent=projects/*/locations/*}/vpcFlowLogsConfigs"
50+
};
51+
option (google.api.method_signature) = "parent";
52+
}
53+
54+
// Gets the details of a specific `VpcFlowLogsConfig`.
55+
rpc GetVpcFlowLogsConfig(GetVpcFlowLogsConfigRequest)
56+
returns (VpcFlowLogsConfig) {
57+
option (google.api.http) = {
58+
get: "/v1beta1/{name=projects/*/locations/*/vpcFlowLogsConfigs/*}"
59+
};
60+
option (google.api.method_signature) = "name";
61+
}
62+
63+
// Creates a new `VpcFlowLogsConfig`.
64+
// If a configuration with the exact same settings already exists (even if the
65+
// ID is different), the creation fails.
66+
// Notes:
67+
// 1. Creating a configuration with state=DISABLED will fail.
68+
// 2. The following fields are not considrered as `settings` for the purpose
69+
// of the check mentioned above, therefore - creating another configuration
70+
// with the same fields but different values for the following fields will
71+
// fail as well:
72+
// - name
73+
// - create_time
74+
// - update_time
75+
// - labels
76+
// - description
77+
rpc CreateVpcFlowLogsConfig(CreateVpcFlowLogsConfigRequest)
78+
returns (google.longrunning.Operation) {
79+
option (google.api.http) = {
80+
post: "/v1beta1/{parent=projects/*/locations/*}/vpcFlowLogsConfigs"
81+
body: "vpc_flow_logs_config"
82+
};
83+
option (google.api.method_signature) =
84+
"parent,vpc_flow_logs_config,vpc_flow_logs_config_id";
85+
option (google.longrunning.operation_info) = {
86+
response_type: "VpcFlowLogsConfig"
87+
metadata_type: "google.cloud.networkmanagement.v1beta1.OperationMetadata"
88+
};
89+
}
90+
91+
// Updates an existing `VpcFlowLogsConfig`.
92+
// If a configuration with the exact same settings already exists (even if the
93+
// ID is different), the creation fails.
94+
// Notes:
95+
// 1. The following fields are not considrered as `settings` for the purpose
96+
// of the check mentioned above, therefore - updating another configuration
97+
// with the same fields but different values for the following fields will
98+
// fail as well:
99+
// - name
100+
// - create_time
101+
// - update_time
102+
// - labels
103+
// - description
104+
rpc UpdateVpcFlowLogsConfig(UpdateVpcFlowLogsConfigRequest)
105+
returns (google.longrunning.Operation) {
106+
option (google.api.http) = {
107+
patch: "/v1beta1/{vpc_flow_logs_config.name=projects/*/locations/*/vpcFlowLogsConfigs/*}"
108+
body: "vpc_flow_logs_config"
109+
};
110+
option (google.api.method_signature) = "vpc_flow_logs_config,update_mask";
111+
option (google.longrunning.operation_info) = {
112+
response_type: "VpcFlowLogsConfig"
113+
metadata_type: "google.cloud.networkmanagement.v1beta1.OperationMetadata"
114+
};
115+
}
116+
117+
// Deletes a specific `VpcFlowLogsConfig`.
118+
rpc DeleteVpcFlowLogsConfig(DeleteVpcFlowLogsConfigRequest)
119+
returns (google.longrunning.Operation) {
120+
option (google.api.http) = {
121+
delete: "/v1beta1/{name=projects/*/locations/*/vpcFlowLogsConfigs/*}"
122+
};
123+
option (google.api.method_signature) = "name";
124+
option (google.longrunning.operation_info) = {
125+
response_type: "google.protobuf.Empty"
126+
metadata_type: "google.cloud.networkmanagement.v1beta1.OperationMetadata"
127+
};
128+
}
129+
}
130+
131+
// Request for the `ListVpcFlowLogsConfigs` method.
132+
message ListVpcFlowLogsConfigsRequest {
133+
// Required. The parent resource of the VpcFlowLogsConfig:
134+
// `projects/{project_id}/locations/global`
135+
string parent = 1 [
136+
(google.api.field_behavior) = REQUIRED,
137+
(google.api.resource_reference) = {
138+
child_type: "networkmanagement.googleapis.com/VpcFlowLogsConfig"
139+
}
140+
];
141+
142+
// Optional. Number of `VpcFlowLogsConfigs` to return.
143+
int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL];
144+
145+
// Optional. Page token from an earlier query, as returned in
146+
// `next_page_token`.
147+
string page_token = 3 [(google.api.field_behavior) = OPTIONAL];
148+
149+
// Optional. Lists the `VpcFlowLogsConfigs` that match the filter expression.
150+
// A filter expression must use the supported [CEL logic operators]
151+
// (https://cloud.google.com/vpc/docs/about-flow-logs-records#supported_cel_logic_operators).
152+
string filter = 4 [(google.api.field_behavior) = OPTIONAL];
153+
154+
// Optional. Field to use to sort the list.
155+
string order_by = 5 [(google.api.field_behavior) = OPTIONAL];
156+
}
157+
158+
// Response for the `ListVpcFlowLogsConfigs` method.
159+
message ListVpcFlowLogsConfigsResponse {
160+
// List of VPC Flow Log configurations.
161+
repeated VpcFlowLogsConfig vpc_flow_logs_configs = 1;
162+
163+
// Page token to fetch the next set of configurations.
164+
string next_page_token = 2;
165+
166+
// Locations that could not be reached (when querying all locations with `-`).
167+
repeated string unreachable = 3;
168+
}
169+
170+
// Request for the `GetVpcFlowLogsConfig` method.
171+
message GetVpcFlowLogsConfigRequest {
172+
// Required. `VpcFlowLogsConfig` resource name using the form:
173+
// `projects/{project_id}/locations/global/vpcFlowLogsConfigs/{vpc_flow_logs_config}`
174+
string name = 1 [
175+
(google.api.field_behavior) = REQUIRED,
176+
(google.api.resource_reference) = {
177+
type: "networkmanagement.googleapis.com/VpcFlowLogsConfig"
178+
}
179+
];
180+
}
181+
182+
// Request for the `CreateVpcFlowLogsConfig` method.
183+
message CreateVpcFlowLogsConfigRequest {
184+
// Required. The parent resource of the VPC Flow Logs configuration to create:
185+
// `projects/{project_id}/locations/global`
186+
string parent = 1 [
187+
(google.api.field_behavior) = REQUIRED,
188+
(google.api.resource_reference) = {
189+
child_type: "networkmanagement.googleapis.com/VpcFlowLogsConfig"
190+
}
191+
];
192+
193+
// Required. ID of the `VpcFlowLogsConfig`.
194+
string vpc_flow_logs_config_id = 2 [
195+
(google.api.field_behavior) = REQUIRED,
196+
(google.api.resource_reference) = {
197+
type: "networkmanagement.googleapis.com/VpcFlowLogsConfig"
198+
}
199+
];
200+
201+
// Required. A `VpcFlowLogsConfig` resource
202+
VpcFlowLogsConfig vpc_flow_logs_config = 3
203+
[(google.api.field_behavior) = REQUIRED];
204+
}
205+
206+
// Request for the `UpdateVpcFlowLogsConfig` method.
207+
message UpdateVpcFlowLogsConfigRequest {
208+
// Required. Mask of fields to update. At least one path must be supplied in
209+
// this field.
210+
google.protobuf.FieldMask update_mask = 1
211+
[(google.api.field_behavior) = REQUIRED];
212+
213+
// Required. Only fields specified in update_mask are updated.
214+
VpcFlowLogsConfig vpc_flow_logs_config = 2
215+
[(google.api.field_behavior) = REQUIRED];
216+
}
217+
218+
// Request for the `DeleteVpcFlowLogsConfig` method.
219+
message DeleteVpcFlowLogsConfigRequest {
220+
// Required. `VpcFlowLogsConfig` resource name using the form:
221+
// `projects/{project_id}/locations/global/vpcFlowLogsConfigs/{vpc_flow_logs_config}`
222+
string name = 1 [
223+
(google.api.field_behavior) = REQUIRED,
224+
(google.api.resource_reference) = {
225+
type: "networkmanagement.googleapis.com/VpcFlowLogsConfig"
226+
}
227+
];
228+
}
Lines changed: 152 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,152 @@
1+
// Copyright 2024 Google LLC
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
syntax = "proto3";
16+
17+
package google.cloud.networkmanagement.v1beta1;
18+
19+
import "google/api/field_behavior.proto";
20+
import "google/api/resource.proto";
21+
import "google/protobuf/timestamp.proto";
22+
23+
option csharp_namespace = "Google.Cloud.NetworkManagement.V1Beta1";
24+
option go_package = "cloud.google.com/go/networkmanagement/apiv1beta1/networkmanagementpb;networkmanagementpb";
25+
option java_multiple_files = true;
26+
option java_outer_classname = "VpcFlowLogsConfigProto";
27+
option java_package = "com.google.cloud.networkmanagement.v1beta1";
28+
option php_namespace = "Google\\Cloud\\NetworkManagement\\V1beta1";
29+
option ruby_package = "Google::Cloud::NetworkManagement::V1beta1";
30+
31+
// A configuration to generate VPC Flow Logs.
32+
message VpcFlowLogsConfig {
33+
option (google.api.resource) = {
34+
type: "networkmanagement.googleapis.com/VpcFlowLogsConfig"
35+
pattern: "projects/{project}/locations/{location}/vpcFlowLogsConfigs/{vpc_flow_logs_config}"
36+
plural: "vpcFlowLogsConfigs"
37+
singular: "vpcFlowLogsConfig"
38+
};
39+
40+
// Determines whether this configuration will be generating logs.
41+
// Setting state=DISABLED will pause the log generation for this config.
42+
enum State {
43+
// If not specified, will default to ENABLED.
44+
STATE_UNSPECIFIED = 0;
45+
46+
// When ENABLED, this configuration will generate logs.
47+
ENABLED = 1;
48+
49+
// When DISABLED, this configuration will not generate logs.
50+
DISABLED = 2;
51+
}
52+
53+
// Toggles the aggregation interval for collecting flow logs by 5-tuple.
54+
enum AggregationInterval {
55+
// If not specified, will default to INTERVAL_5_SEC.
56+
AGGREGATION_INTERVAL_UNSPECIFIED = 0;
57+
58+
// Aggregate logs in 5s intervals.
59+
INTERVAL_5_SEC = 1;
60+
61+
// Aggregate logs in 30s intervals.
62+
INTERVAL_30_SEC = 2;
63+
64+
// Aggregate logs in 1m intervals.
65+
INTERVAL_1_MIN = 3;
66+
67+
// Aggregate logs in 5m intervals.
68+
INTERVAL_5_MIN = 4;
69+
70+
// Aggregate logs in 10m intervals.
71+
INTERVAL_10_MIN = 5;
72+
73+
// Aggregate logs in 15m intervals.
74+
INTERVAL_15_MIN = 6;
75+
}
76+
77+
// Configures which log fields would be included.
78+
enum Metadata {
79+
// If not specified, will default to INCLUDE_ALL_METADATA.
80+
METADATA_UNSPECIFIED = 0;
81+
82+
// Include all metadata fields.
83+
INCLUDE_ALL_METADATA = 1;
84+
85+
// Exclude all metadata fields.
86+
EXCLUDE_ALL_METADATA = 2;
87+
88+
// Include only custom fields (specified in metadata_fields).
89+
CUSTOM_METADATA = 3;
90+
}
91+
92+
// Identifier. Unique name of the configuration using the form:
93+
// `projects/{project_id}/locations/global/vpcFlowLogsConfigs/{vpc_flow_logs_config_id}`
94+
string name = 1 [(google.api.field_behavior) = IDENTIFIER];
95+
96+
// Optional. The user-supplied description of the VPC Flow Logs configuration.
97+
// Maximum of 512 characters.
98+
optional string description = 2 [(google.api.field_behavior) = OPTIONAL];
99+
100+
// Optional. The state of the VPC Flow Log configuration. Default value is
101+
// ENABLED. When creating a new configuration, it must be enabled.
102+
optional State state = 3 [(google.api.field_behavior) = OPTIONAL];
103+
104+
// Optional. The aggregation interval for the logs. Default value is
105+
// INTERVAL_5_SEC.
106+
optional AggregationInterval aggregation_interval = 4
107+
[(google.api.field_behavior) = OPTIONAL];
108+
109+
// Optional. The value of the field must be in (0, 1]. The sampling rate of
110+
// VPC Flow Logs where 1.0 means all collected logs are reported. Setting the
111+
// sampling rate to 0.0 is not allowed. If you want to disable VPC Flow Logs,
112+
// use the state field instead. Default value is 1.0.
113+
optional float flow_sampling = 5 [(google.api.field_behavior) = OPTIONAL];
114+
115+
// Optional. Configures whether all, none or a subset of metadata fields
116+
// should be added to the reported VPC flow logs. Default value is
117+
// INCLUDE_ALL_METADATA.
118+
optional Metadata metadata = 6 [(google.api.field_behavior) = OPTIONAL];
119+
120+
// Optional. Custom metadata fields to include in the reported VPC flow logs.
121+
// Can only be specified if "metadata" was set to CUSTOM_METADATA.
122+
repeated string metadata_fields = 7 [(google.api.field_behavior) = OPTIONAL];
123+
124+
// Optional. Export filter used to define which VPC Flow Logs should be
125+
// logged.
126+
optional string filter_expr = 8 [(google.api.field_behavior) = OPTIONAL];
127+
128+
// Reference to the resource of the config scope. That is, the scope from
129+
// which traffic is logged. The target resource must belong to the same
130+
// project as the configuration.
131+
oneof target_resource {
132+
// Traffic will be logged from the Interconnect Attachment.
133+
// Format:
134+
// projects/{project_id}/regions/{region}/interconnectAttachments/{name}
135+
string interconnect_attachment = 102;
136+
137+
// Traffic will be logged from the VPN Tunnel.
138+
// Format: projects/{project_id}/regions/{region}/vpnTunnels/{name}
139+
string vpn_tunnel = 103;
140+
}
141+
142+
// Optional. Resource labels to represent user-provided metadata.
143+
map<string, string> labels = 11 [(google.api.field_behavior) = OPTIONAL];
144+
145+
// Output only. The time the config was created.
146+
google.protobuf.Timestamp create_time = 9
147+
[(google.api.field_behavior) = OUTPUT_ONLY];
148+
149+
// Output only. The time the config was updated.
150+
google.protobuf.Timestamp update_time = 10
151+
[(google.api.field_behavior) = OUTPUT_ONLY];
152+
}

0 commit comments

Comments
 (0)