Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add datasource to job definition for security monitoring #2293

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .apigentools-info
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
"spec_versions": {
"v1": {
"apigentools_version": "1.6.6",
"regenerated": "2025-03-14 07:51:10.767732",
"spec_repo_commit": "899883be"
"regenerated": "2025-03-17 14:53:14.761487",
"spec_repo_commit": "f73f9d61"
},
"v2": {
"apigentools_version": "1.6.6",
"regenerated": "2025-03-14 07:51:10.783055",
"spec_repo_commit": "899883be"
"regenerated": "2025-03-17 14:53:14.777295",
"spec_repo_commit": "f73f9d61"
}
}
}
2 changes: 2 additions & 0 deletions .generator/schemas/v2/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14746,6 +14746,8 @@ components:
properties:
aggregation:
$ref: '#/components/schemas/SecurityMonitoringRuleQueryAggregation'
dataSource:
$ref: '#/components/schemas/SecurityMonitoringStandardDataSource'
distinctFields:
description: Field for which the cardinality is measured. Sent as an array.
items:
Expand Down
12 changes: 11 additions & 1 deletion lib/datadog_api_client/v2/models/historical_job_query.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ class HistoricalJobQuery
# The aggregation type.
attr_accessor :aggregation

# Source of events, either logs or audit trail.
attr_accessor :data_source

# Field for which the cardinality is measured. Sent as an array.
attr_accessor :distinct_fields

Expand All @@ -49,6 +52,7 @@ class HistoricalJobQuery
def self.attribute_map
{
:'aggregation' => :'aggregation',
:'data_source' => :'dataSource',
:'distinct_fields' => :'distinctFields',
:'group_by_fields' => :'groupByFields',
:'has_optional_group_by_fields' => :'hasOptionalGroupByFields',
Expand All @@ -63,6 +67,7 @@ def self.attribute_map
def self.openapi_types
{
:'aggregation' => :'SecurityMonitoringRuleQueryAggregation',
:'data_source' => :'SecurityMonitoringStandardDataSource',
:'distinct_fields' => :'Array<String>',
:'group_by_fields' => :'Array<String>',
:'has_optional_group_by_fields' => :'Boolean',
Expand Down Expand Up @@ -94,6 +99,10 @@ def initialize(attributes = {})
self.aggregation = attributes[:'aggregation']
end

if attributes.key?(:'data_source')
self.data_source = attributes[:'data_source']
end

if attributes.key?(:'distinct_fields')
if (value = attributes[:'distinct_fields']).is_a?(Array)
self.distinct_fields = value
Expand Down Expand Up @@ -152,6 +161,7 @@ def ==(o)
return true if self.equal?(o)
self.class == o.class &&
aggregation == o.aggregation &&
data_source == o.data_source &&
distinct_fields == o.distinct_fields &&
group_by_fields == o.group_by_fields &&
has_optional_group_by_fields == o.has_optional_group_by_fields &&
Expand All @@ -165,7 +175,7 @@ def ==(o)
# @return [Integer] Hash code
# @!visibility private
def hash
[aggregation, distinct_fields, group_by_fields, has_optional_group_by_fields, metrics, name, query, additional_properties].hash
[aggregation, data_source, distinct_fields, group_by_fields, has_optional_group_by_fields, metrics, name, query, additional_properties].hash
end
end
end
Loading