Skip to content

Commit 9933cf9

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit 2ffcae8 of spec repo
1 parent b62c997 commit 9933cf9

File tree

3 files changed

+46
-5
lines changed

3 files changed

+46
-5
lines changed

.generator/schemas/v2/openapi.yaml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23536,6 +23536,13 @@ components:
2353623536
product for this service account. Note: This requires resource_collection_enabled
2353723537
to be set to true.'
2353823538
type: boolean
23539+
is_global_location_enabled:
23540+
default: true
23541+
description: When enabled, Datadog collects metrics where location is explicitly
23542+
stated as "global" or where location information cannot be deduced from
23543+
GCP labels.
23544+
example: true
23545+
type: boolean
2353923546
is_per_project_quota_enabled:
2354023547
default: false
2354123548
description: When enabled, Datadog applies the `X-Goog-User-Project` header,
@@ -23577,6 +23584,18 @@ components:
2357723584
items:
2357823585
$ref: '#/components/schemas/GCPMonitoredResourceConfig'
2357923586
type: array
23587+
region_filter_configs:
23588+
description: Configurations for GCP location filtering, such as region,
23589+
multi-region, or zone. Only monitored resources that match the specified
23590+
regions are imported into Datadog. By default, Datadog collects from all
23591+
locations.
23592+
example:
23593+
- nam4
23594+
- europe-north1
23595+
items:
23596+
description: Region Filter Configs
23597+
type: string
23598+
type: array
2358023599
resource_collection_enabled:
2358123600
description: When enabled, Datadog scans for all resources in your GCP environment.
2358223601
type: boolean

features/v2/gcp_integration.feature

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,14 +34,14 @@ Feature: GCP Integration
3434
@generated @skip @team:DataDog/gcp-integrations
3535
Scenario: Create a new entry for your service account returns "Bad Request" response
3636
Given new "CreateGCPSTSAccount" request
37-
And body with value {"data": {"attributes": {"account_tags": [], "client_email": "datadog-service-account@test-project.iam.gserviceaccount.com", "cloud_run_revision_filters": ["$KEY:$VALUE"], "host_filters": ["$KEY:$VALUE"], "is_per_project_quota_enabled": true, "is_resource_change_collection_enabled": true, "is_security_command_center_enabled": true, "metric_namespace_configs": [{"disabled": true, "id": "aiplatform"}, {"filters": ["snapshot.*", "!*_by_region"], "id": "pubsub"}], "monitored_resource_configs": [{"filters": ["$KEY:$VALUE"], "type": "gce_instance"}]}, "type": "gcp_service_account"}}
37+
And body with value {"data": {"attributes": {"account_tags": [], "client_email": "datadog-service-account@test-project.iam.gserviceaccount.com", "cloud_run_revision_filters": ["$KEY:$VALUE"], "host_filters": ["$KEY:$VALUE"], "is_global_location_enabled": true, "is_per_project_quota_enabled": true, "is_resource_change_collection_enabled": true, "is_security_command_center_enabled": true, "metric_namespace_configs": [{"disabled": true, "id": "aiplatform"}, {"filters": ["snapshot.*", "!*_by_region"], "id": "pubsub"}], "monitored_resource_configs": [{"filters": ["$KEY:$VALUE"], "type": "gce_instance"}], "region_filter_configs": ["nam4", "europe-north1"]}, "type": "gcp_service_account"}}
3838
When the request is sent
3939
Then the response status is 400 Bad Request
4040

4141
@generated @skip @team:DataDog/gcp-integrations
4242
Scenario: Create a new entry for your service account returns "Conflict" response
4343
Given new "CreateGCPSTSAccount" request
44-
And body with value {"data": {"attributes": {"account_tags": [], "client_email": "datadog-service-account@test-project.iam.gserviceaccount.com", "cloud_run_revision_filters": ["$KEY:$VALUE"], "host_filters": ["$KEY:$VALUE"], "is_per_project_quota_enabled": true, "is_resource_change_collection_enabled": true, "is_security_command_center_enabled": true, "metric_namespace_configs": [{"disabled": true, "id": "aiplatform"}, {"filters": ["snapshot.*", "!*_by_region"], "id": "pubsub"}], "monitored_resource_configs": [{"filters": ["$KEY:$VALUE"], "type": "gce_instance"}]}, "type": "gcp_service_account"}}
44+
And body with value {"data": {"attributes": {"account_tags": [], "client_email": "datadog-service-account@test-project.iam.gserviceaccount.com", "cloud_run_revision_filters": ["$KEY:$VALUE"], "host_filters": ["$KEY:$VALUE"], "is_global_location_enabled": true, "is_per_project_quota_enabled": true, "is_resource_change_collection_enabled": true, "is_security_command_center_enabled": true, "metric_namespace_configs": [{"disabled": true, "id": "aiplatform"}, {"filters": ["snapshot.*", "!*_by_region"], "id": "pubsub"}], "monitored_resource_configs": [{"filters": ["$KEY:$VALUE"], "type": "gce_instance"}], "region_filter_configs": ["nam4", "europe-north1"]}, "type": "gcp_service_account"}}
4545
When the request is sent
4646
Then the response status is 409 Conflict
4747

@@ -151,15 +151,15 @@ Feature: GCP Integration
151151
Scenario: Update STS Service Account returns "Bad Request" response
152152
Given new "UpdateGCPSTSAccount" request
153153
And request contains "account_id" parameter from "REPLACE.ME"
154-
And body with value {"data": {"attributes": {"account_tags": [], "client_email": "datadog-service-account@test-project.iam.gserviceaccount.com", "cloud_run_revision_filters": ["$KEY:$VALUE"], "host_filters": ["$KEY:$VALUE"], "is_per_project_quota_enabled": true, "is_resource_change_collection_enabled": true, "is_security_command_center_enabled": true, "metric_namespace_configs": [{"disabled": true, "id": "aiplatform"}, {"filters": ["snapshot.*", "!*_by_region"], "id": "pubsub"}], "monitored_resource_configs": [{"filters": ["$KEY:$VALUE"], "type": "gce_instance"}]}, "id": "d291291f-12c2-22g4-j290-123456678897", "type": "gcp_service_account"}}
154+
And body with value {"data": {"attributes": {"account_tags": [], "client_email": "datadog-service-account@test-project.iam.gserviceaccount.com", "cloud_run_revision_filters": ["$KEY:$VALUE"], "host_filters": ["$KEY:$VALUE"], "is_global_location_enabled": true, "is_per_project_quota_enabled": true, "is_resource_change_collection_enabled": true, "is_security_command_center_enabled": true, "metric_namespace_configs": [{"disabled": true, "id": "aiplatform"}, {"filters": ["snapshot.*", "!*_by_region"], "id": "pubsub"}], "monitored_resource_configs": [{"filters": ["$KEY:$VALUE"], "type": "gce_instance"}], "region_filter_configs": ["nam4", "europe-north1"]}, "id": "d291291f-12c2-22g4-j290-123456678897", "type": "gcp_service_account"}}
155155
When the request is sent
156156
Then the response status is 400 Bad Request
157157

158158
@generated @skip @team:DataDog/gcp-integrations
159159
Scenario: Update STS Service Account returns "Not Found" response
160160
Given new "UpdateGCPSTSAccount" request
161161
And request contains "account_id" parameter from "REPLACE.ME"
162-
And body with value {"data": {"attributes": {"account_tags": [], "client_email": "datadog-service-account@test-project.iam.gserviceaccount.com", "cloud_run_revision_filters": ["$KEY:$VALUE"], "host_filters": ["$KEY:$VALUE"], "is_per_project_quota_enabled": true, "is_resource_change_collection_enabled": true, "is_security_command_center_enabled": true, "metric_namespace_configs": [{"disabled": true, "id": "aiplatform"}, {"filters": ["snapshot.*", "!*_by_region"], "id": "pubsub"}], "monitored_resource_configs": [{"filters": ["$KEY:$VALUE"], "type": "gce_instance"}]}, "id": "d291291f-12c2-22g4-j290-123456678897", "type": "gcp_service_account"}}
162+
And body with value {"data": {"attributes": {"account_tags": [], "client_email": "datadog-service-account@test-project.iam.gserviceaccount.com", "cloud_run_revision_filters": ["$KEY:$VALUE"], "host_filters": ["$KEY:$VALUE"], "is_global_location_enabled": true, "is_per_project_quota_enabled": true, "is_resource_change_collection_enabled": true, "is_security_command_center_enabled": true, "metric_namespace_configs": [{"disabled": true, "id": "aiplatform"}, {"filters": ["snapshot.*", "!*_by_region"], "id": "pubsub"}], "monitored_resource_configs": [{"filters": ["$KEY:$VALUE"], "type": "gce_instance"}], "region_filter_configs": ["nam4", "europe-north1"]}, "id": "d291291f-12c2-22g4-j290-123456678897", "type": "gcp_service_account"}}
163163
When the request is sent
164164
Then the response status is 404 Not Found
165165

lib/datadog_api_client/v2/models/gcpsts_service_account_attributes.rb

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,9 @@ class GCPSTSServiceAccountAttributes
4343
# When enabled, Datadog will activate the Cloud Security Monitoring product for this service account. Note: This requires resource_collection_enabled to be set to true.
4444
attr_accessor :is_cspm_enabled
4545

46+
# When enabled, Datadog collects metrics where location is explicitly stated as "global" or where location information cannot be deduced from GCP labels.
47+
attr_accessor :is_global_location_enabled
48+
4649
# When enabled, Datadog applies the `X-Goog-User-Project` header, attributing Google Cloud billing and quota usage to the project being monitored rather than the default service account project.
4750
attr_accessor :is_per_project_quota_enabled
4851

@@ -58,6 +61,9 @@ class GCPSTSServiceAccountAttributes
5861
# Configurations for GCP monitored resources.
5962
attr_accessor :monitored_resource_configs
6063

64+
# Configurations for GCP location filtering, such as region, multi-region, or zone. Only monitored resources that match the specified regions are imported into Datadog. By default, Datadog collects from all locations.
65+
attr_accessor :region_filter_configs
66+
6167
# When enabled, Datadog scans for all resources in your GCP environment.
6268
attr_accessor :resource_collection_enabled
6369

@@ -73,11 +79,13 @@ def self.attribute_map
7379
:'cloud_run_revision_filters' => :'cloud_run_revision_filters',
7480
:'host_filters' => :'host_filters',
7581
:'is_cspm_enabled' => :'is_cspm_enabled',
82+
:'is_global_location_enabled' => :'is_global_location_enabled',
7683
:'is_per_project_quota_enabled' => :'is_per_project_quota_enabled',
7784
:'is_resource_change_collection_enabled' => :'is_resource_change_collection_enabled',
7885
:'is_security_command_center_enabled' => :'is_security_command_center_enabled',
7986
:'metric_namespace_configs' => :'metric_namespace_configs',
8087
:'monitored_resource_configs' => :'monitored_resource_configs',
88+
:'region_filter_configs' => :'region_filter_configs',
8189
:'resource_collection_enabled' => :'resource_collection_enabled'
8290
}
8391
end
@@ -92,11 +100,13 @@ def self.openapi_types
92100
:'cloud_run_revision_filters' => :'Array<String>',
93101
:'host_filters' => :'Array<String>',
94102
:'is_cspm_enabled' => :'Boolean',
103+
:'is_global_location_enabled' => :'Boolean',
95104
:'is_per_project_quota_enabled' => :'Boolean',
96105
:'is_resource_change_collection_enabled' => :'Boolean',
97106
:'is_security_command_center_enabled' => :'Boolean',
98107
:'metric_namespace_configs' => :'Array<GCPMetricNamespaceConfig>',
99108
:'monitored_resource_configs' => :'Array<GCPMonitoredResourceConfig>',
109+
:'region_filter_configs' => :'Array<String>',
100110
:'resource_collection_enabled' => :'Boolean'
101111
}
102112
end
@@ -149,6 +159,10 @@ def initialize(attributes = {})
149159
self.is_cspm_enabled = attributes[:'is_cspm_enabled']
150160
end
151161

162+
if attributes.key?(:'is_global_location_enabled')
163+
self.is_global_location_enabled = attributes[:'is_global_location_enabled']
164+
end
165+
152166
if attributes.key?(:'is_per_project_quota_enabled')
153167
self.is_per_project_quota_enabled = attributes[:'is_per_project_quota_enabled']
154168
end
@@ -173,6 +187,12 @@ def initialize(attributes = {})
173187
end
174188
end
175189

190+
if attributes.key?(:'region_filter_configs')
191+
if (value = attributes[:'region_filter_configs']).is_a?(Array)
192+
self.region_filter_configs = value
193+
end
194+
end
195+
176196
if attributes.key?(:'resource_collection_enabled')
177197
self.resource_collection_enabled = attributes[:'resource_collection_enabled']
178198
end
@@ -210,11 +230,13 @@ def ==(o)
210230
cloud_run_revision_filters == o.cloud_run_revision_filters &&
211231
host_filters == o.host_filters &&
212232
is_cspm_enabled == o.is_cspm_enabled &&
233+
is_global_location_enabled == o.is_global_location_enabled &&
213234
is_per_project_quota_enabled == o.is_per_project_quota_enabled &&
214235
is_resource_change_collection_enabled == o.is_resource_change_collection_enabled &&
215236
is_security_command_center_enabled == o.is_security_command_center_enabled &&
216237
metric_namespace_configs == o.metric_namespace_configs &&
217238
monitored_resource_configs == o.monitored_resource_configs &&
239+
region_filter_configs == o.region_filter_configs &&
218240
resource_collection_enabled == o.resource_collection_enabled &&
219241
additional_properties == o.additional_properties
220242
end
@@ -223,7 +245,7 @@ def ==(o)
223245
# @return [Integer] Hash code
224246
# @!visibility private
225247
def hash
226-
[account_tags, automute, client_email, cloud_run_revision_filters, host_filters, is_cspm_enabled, is_per_project_quota_enabled, is_resource_change_collection_enabled, is_security_command_center_enabled, metric_namespace_configs, monitored_resource_configs, resource_collection_enabled, additional_properties].hash
248+
[account_tags, automute, client_email, cloud_run_revision_filters, host_filters, is_cspm_enabled, is_global_location_enabled, is_per_project_quota_enabled, is_resource_change_collection_enabled, is_security_command_center_enabled, metric_namespace_configs, monitored_resource_configs, region_filter_configs, resource_collection_enabled, additional_properties].hash
227249
end
228250
end
229251
end

0 commit comments

Comments
 (0)