Skip to content

Commit 3fea5c0

Browse files
api-clients-generation-pipeline[bot]ci.datadog-api-spec
andauthored
Deprecate metric field of Security Monitoring Rules (#878)
Co-authored-by: ci.datadog-api-spec <[email protected]>
1 parent bd1b033 commit 3fea5c0

File tree

28 files changed

+180
-178
lines changed

28 files changed

+180
-178
lines changed

.apigentools-info

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44
"spec_versions": {
55
"v1": {
66
"apigentools_version": "1.6.4",
7-
"regenerated": "2022-10-14 14:06:55.801928",
8-
"spec_repo_commit": "7eb6ca7a"
7+
"regenerated": "2022-10-20 09:07:36.996734",
8+
"spec_repo_commit": "148c906a"
99
},
1010
"v2": {
1111
"apigentools_version": "1.6.4",
12-
"regenerated": "2022-10-14 14:06:55.819509",
13-
"spec_repo_commit": "7eb6ca7a"
12+
"regenerated": "2022-10-20 09:07:37.009574",
13+
"spec_repo_commit": "148c906a"
1414
}
1515
}
1616
}

.generator/schemas/v2/openapi.yaml

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8174,8 +8174,7 @@ components:
81748174
maximum: 9
81758175
type: integer
81768176
metrics:
8177-
description: Group of target fields to aggregate over when using the new
8178-
value aggregations.
8177+
description: Group of target fields to aggregate over.
81798178
items:
81808179
description: Field.
81818180
type: string
@@ -8278,8 +8277,7 @@ components:
82788277
example: d3f-ru1-e1d
82798278
type: string
82808279
metrics:
8281-
description: Group of target fields to aggregate over when using the new
8282-
value aggregations.
8280+
description: Group of target fields to aggregate over.
82838281
items:
82848282
description: Field.
82858283
type: string
@@ -8533,13 +8531,17 @@ components:
85338531
type: string
85348532
type: array
85358533
metric:
8536-
description: 'The target field to aggregate over when using the sum or max
8534+
deprecated: true
8535+
description: '(Deprecated) The target field to aggregate over when using
8536+
the sum or max
85378537

8538-
aggregations.'
8538+
aggregations. `metrics` field should be used instead.'
85398539
type: string
85408540
metrics:
8541-
description: Group of target fields to aggregate over when using the new
8542-
value aggregations.
8541+
description: Group of target fields to aggregate over when using the sum,
8542+
max, geo data, or new value aggregations. The sum, max, and geo data aggregations
8543+
only accept one value in this list, whereas the new value aggregation
8544+
accepts up to five values.
85438545
items:
85448546
description: Field.
85458547
type: string
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
"2022-09-27T13:06:48.381Z"
1+
"2022-10-19T13:36:33.262Z"

cassettes/v2/Security-Monitoring_1187227211/Create-a-detection-rule-returns-Bad-Request-response_1398536295/recording.har

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@
44
"creator": {
55
"comment": "persister:fs",
66
"name": "Polly.JS",
7-
"version": "5.1.0"
7+
"version": "6.0.5"
88
},
99
"entries": [
1010
{
11-
"_id": "710c4def7bae181d3c01f89a98f7f31e",
11+
"_id": "8515ec7a4796004b97e56fe68002292f",
1212
"_order": 0,
1313
"cache": {},
1414
"request": {
@@ -32,7 +32,7 @@
3232
"postData": {
3333
"mimeType": "application/json",
3434
"params": [],
35-
"text": "{\"cases\":[{\"status\":\"info\"}],\"isEnabled\":true,\"message\":\"Test rule\",\"name\":\"Test-Create_a_detection_rule_returns_Bad_Request_response-1664284008\",\"options\":{},\"queries\":[{\"query\":\"\"}],\"tags\":[]}"
35+
"text": "{\"cases\":[{\"status\":\"info\"}],\"isEnabled\":true,\"message\":\"Test rule\",\"name\":\"Test-Create_a_detection_rule_returns_Bad_Request_response-1666186593\",\"options\":{},\"queries\":[{\"query\":\"\"}],\"tags\":[]}"
3636
},
3737
"queryString": [],
3838
"url": "https://api.datadoghq.com/api/v2/security_monitoring/rules"
@@ -57,8 +57,8 @@
5757
"status": 400,
5858
"statusText": "Bad Request"
5959
},
60-
"startedDateTime": "2022-09-27T13:06:48.387Z",
61-
"time": 497
60+
"startedDateTime": "2022-10-19T13:36:33.276Z",
61+
"time": 373
6262
}
6363
],
6464
"pages": [],
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
"2022-09-27T13:06:48.898Z"
1+
"2022-10-19T13:36:33.666Z"

cassettes/v2/Security-Monitoring_1187227211/Create-a-detection-rule-returns-OK-response_1993092739/recording.har

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@
44
"creator": {
55
"comment": "persister:fs",
66
"name": "Polly.JS",
7-
"version": "5.1.0"
7+
"version": "6.0.5"
88
},
99
"entries": [
1010
{
11-
"_id": "d4eed9faa240134545b6b3a49670f60a",
11+
"_id": "806b0fd171813bdccd33dbb88df00187",
1212
"_order": 0,
1313
"cache": {},
1414
"request": {
@@ -32,7 +32,7 @@
3232
"postData": {
3333
"mimeType": "application/json",
3434
"params": [],
35-
"text": "{\"cases\":[{\"condition\":\"a > 0\",\"name\":\"\",\"notifications\":[],\"status\":\"info\"}],\"filters\":[],\"isEnabled\":true,\"message\":\"Test rule\",\"name\":\"Test-Create_a_detection_rule_returns_OK_response-1664284008\",\"options\":{\"evaluationWindow\":900,\"keepAlive\":3600,\"maxSignalDuration\":86400},\"queries\":[{\"aggregation\":\"count\",\"distinctFields\":[],\"groupByFields\":[],\"metric\":\"\",\"query\":\"@test:true\"}],\"tags\":[],\"type\":\"log_detection\"}"
35+
"text": "{\"cases\":[{\"condition\":\"a > 0\",\"name\":\"\",\"notifications\":[],\"status\":\"info\"}],\"filters\":[],\"isEnabled\":true,\"message\":\"Test rule\",\"name\":\"Test-Create_a_detection_rule_returns_OK_response-1666186593\",\"options\":{\"evaluationWindow\":900,\"keepAlive\":3600,\"maxSignalDuration\":86400},\"queries\":[{\"aggregation\":\"count\",\"distinctFields\":[],\"groupByFields\":[],\"metric\":\"\",\"query\":\"@test:true\"}],\"tags\":[],\"type\":\"log_detection\"}"
3636
},
3737
"queryString": [],
3838
"url": "https://api.datadoghq.com/api/v2/security_monitoring/rules"
@@ -42,7 +42,7 @@
4242
"content": {
4343
"mimeType": "application/json",
4444
"size": 592,
45-
"text": "{\"creationAuthorId\":1445416,\"tags\":[],\"isEnabled\":true,\"hasExtendedTitle\":false,\"message\":\"Test rule\",\"options\":{\"detectionMethod\":\"threshold\",\"evaluationWindow\":900,\"maxSignalDuration\":86400,\"keepAlive\":3600},\"version\":1,\"createdAt\":1664284009174,\"filters\":[],\"queries\":[{\"query\":\"@test:true\",\"groupByFields\":[],\"aggregation\":\"count\",\"name\":\"\",\"distinctFields\":[]}],\"isDeleted\":false,\"cases\":[{\"status\":\"info\",\"notifications\":[],\"name\":\"\",\"condition\":\"a > 0\"}],\"type\":\"log_detection\",\"id\":\"dam-cha-bya\",\"isDefault\":false,\"name\":\"Test-Create_a_detection_rule_returns_OK_response-1664284008\"}\n"
45+
"text": "{\"creationAuthorId\":1445416,\"tags\":[],\"isEnabled\":true,\"hasExtendedTitle\":false,\"message\":\"Test rule\",\"options\":{\"detectionMethod\":\"threshold\",\"evaluationWindow\":900,\"maxSignalDuration\":86400,\"keepAlive\":3600},\"version\":1,\"createdAt\":1666186594041,\"filters\":[],\"queries\":[{\"query\":\"@test:true\",\"groupByFields\":[],\"aggregation\":\"count\",\"name\":\"\",\"distinctFields\":[]}],\"isDeleted\":false,\"cases\":[{\"status\":\"info\",\"notifications\":[],\"name\":\"\",\"condition\":\"a > 0\"}],\"type\":\"log_detection\",\"id\":\"2zr-mrk-aq9\",\"isDefault\":false,\"name\":\"Test-Create_a_detection_rule_returns_OK_response-1666186593\"}\n"
4646
},
4747
"cookies": [],
4848
"headers": [
@@ -57,11 +57,11 @@
5757
"status": 200,
5858
"statusText": "OK"
5959
},
60-
"startedDateTime": "2022-09-27T13:06:48.903Z",
61-
"time": 994
60+
"startedDateTime": "2022-10-19T13:36:33.674Z",
61+
"time": 373
6262
},
6363
{
64-
"_id": "e20ed2aa241f7d4638f367cf16240ac3",
64+
"_id": "2c65d173e98d81c47628d133a3ae13f4",
6565
"_order": 0,
6666
"cache": {},
6767
"request": {
@@ -78,7 +78,7 @@
7878
"httpVersion": "HTTP/1.1",
7979
"method": "DELETE",
8080
"queryString": [],
81-
"url": "https://api.datadoghq.com/api/v2/security_monitoring/rules/dam-cha-bya"
81+
"url": "https://api.datadoghq.com/api/v2/security_monitoring/rules/2zr-mrk-aq9"
8282
},
8383
"response": {
8484
"bodySize": 0,
@@ -88,14 +88,14 @@
8888
},
8989
"cookies": [],
9090
"headers": [],
91-
"headersSize": 575,
91+
"headersSize": 574,
9292
"httpVersion": "HTTP/1.1",
9393
"redirectURL": "",
9494
"status": 204,
9595
"statusText": "No Content"
9696
},
97-
"startedDateTime": "2022-09-27T13:06:49.908Z",
98-
"time": 519
97+
"startedDateTime": "2022-10-19T13:36:34.058Z",
98+
"time": 378
9999
}
100100
],
101101
"pages": [],
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
"2022-09-27T13:06:50.436Z"
1+
"2022-10-19T13:36:34.442Z"

cassettes/v2/Security-Monitoring_1187227211/Create-a-detection-rule-with-type-impossible_travel-returns-OK-response_4217150877/recording.har

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@
44
"creator": {
55
"comment": "persister:fs",
66
"name": "Polly.JS",
7-
"version": "6.0.4"
7+
"version": "6.0.5"
88
},
99
"entries": [
1010
{
11-
"_id": "56a579bbb44076b012d8c2f7cccdec7a",
11+
"_id": "c387e0e8dc48af7a1b76451277d091f8",
1212
"_order": 0,
1313
"cache": {},
1414
"request": {
@@ -32,7 +32,7 @@
3232
"postData": {
3333
"mimeType": "application/json",
3434
"params": [],
35-
"text": "{\"cases\":[{\"name\":\"\",\"notifications\":[],\"status\":\"info\"}],\"filters\":[],\"hasExtendedTitle\":true,\"isEnabled\":true,\"message\":\"test\",\"name\":\"Test-Create_a_detection_rule_with_type_impossible_travel_returns_OK_response-1664284010\",\"options\":{\"detectionMethod\":\"impossible_travel\",\"evaluationWindow\":900,\"impossibleTravelOptions\":{\"baselineUserLocations\":false},\"keepAlive\":3600,\"maxSignalDuration\":86400},\"queries\":[{\"aggregation\":\"geo_data\",\"distinctFields\":[],\"groupByFields\":[\"@usr.id\"],\"metric\":\"@network.client.geoip\",\"query\":\"*\"}],\"tags\":[],\"type\":\"log_detection\"}"
35+
"text": "{\"cases\":[{\"name\":\"\",\"notifications\":[],\"status\":\"info\"}],\"filters\":[],\"hasExtendedTitle\":true,\"isEnabled\":true,\"message\":\"test\",\"name\":\"Test-Create_a_detection_rule_with_type_impossible_travel_returns_OK_response-1666186594\",\"options\":{\"detectionMethod\":\"impossible_travel\",\"evaluationWindow\":900,\"impossibleTravelOptions\":{\"baselineUserLocations\":false},\"keepAlive\":3600,\"maxSignalDuration\":86400},\"queries\":[{\"aggregation\":\"geo_data\",\"distinctFields\":[],\"groupByFields\":[\"@usr.id\"],\"metric\":\"@network.client.geoip\",\"query\":\"*\"}],\"tags\":[],\"type\":\"log_detection\"}"
3636
},
3737
"queryString": [],
3838
"url": "https://api.datadoghq.com/api/v2/security_monitoring/rules"
@@ -42,7 +42,7 @@
4242
"content": {
4343
"mimeType": "application/json",
4444
"size": 732,
45-
"text": "{\"creationAuthorId\":1445416,\"tags\":[],\"isEnabled\":true,\"hasExtendedTitle\":true,\"message\":\"test\",\"options\":{\"impossibleTravelOptions\":{\"baselineUserLocations\":false},\"detectionMethod\":\"impossible_travel\",\"evaluationWindow\":900,\"maxSignalDuration\":86400,\"keepAlive\":3600},\"version\":1,\"createdAt\":1664284010816,\"filters\":[],\"queries\":[{\"distinctFields\":[],\"name\":\"\",\"metric\":\"@network.client.geoip\",\"aggregation\":\"geo_data\",\"metrics\":[\"@network.client.geoip\"],\"groupByFields\":[\"@usr.id\"],\"query\":\"*\"}],\"isDeleted\":false,\"cases\":[{\"status\":\"info\",\"notifications\":[],\"name\":\"\"}],\"type\":\"log_detection\",\"id\":\"iat-ydc-4mz\",\"isDefault\":false,\"name\":\"Test-Create_a_detection_rule_with_type_impossible_travel_returns_OK_response-1664284010\"}\n"
45+
"text": "{\"creationAuthorId\":1445416,\"tags\":[],\"isEnabled\":true,\"hasExtendedTitle\":true,\"message\":\"test\",\"options\":{\"impossibleTravelOptions\":{\"baselineUserLocations\":false},\"detectionMethod\":\"impossible_travel\",\"evaluationWindow\":900,\"maxSignalDuration\":86400,\"keepAlive\":3600},\"version\":1,\"createdAt\":1666186594819,\"filters\":[],\"queries\":[{\"distinctFields\":[],\"name\":\"\",\"metric\":\"@network.client.geoip\",\"aggregation\":\"geo_data\",\"metrics\":[\"@network.client.geoip\"],\"groupByFields\":[\"@usr.id\"],\"query\":\"*\"}],\"isDeleted\":false,\"cases\":[{\"status\":\"info\",\"notifications\":[],\"name\":\"\"}],\"type\":\"log_detection\",\"id\":\"hrr-a7c-wzl\",\"isDefault\":false,\"name\":\"Test-Create_a_detection_rule_with_type_impossible_travel_returns_OK_response-1666186594\"}\n"
4646
},
4747
"cookies": [],
4848
"headers": [
@@ -51,17 +51,17 @@
5151
"value": "application/json"
5252
}
5353
],
54-
"headersSize": 628,
54+
"headersSize": 627,
5555
"httpVersion": "HTTP/1.1",
5656
"redirectURL": "",
5757
"status": 200,
5858
"statusText": "OK"
5959
},
60-
"startedDateTime": "2022-09-27T13:06:50.441Z",
61-
"time": 471
60+
"startedDateTime": "2022-10-19T13:36:34.450Z",
61+
"time": 753
6262
},
6363
{
64-
"_id": "854892c36376e75851c5a3c3097fd540",
64+
"_id": "011f0a2abe39c1e2984399a10af77a64",
6565
"_order": 0,
6666
"cache": {},
6767
"request": {
@@ -78,7 +78,7 @@
7878
"httpVersion": "HTTP/1.1",
7979
"method": "DELETE",
8080
"queryString": [],
81-
"url": "https://api.datadoghq.com/api/v2/security_monitoring/rules/iat-ydc-4mz"
81+
"url": "https://api.datadoghq.com/api/v2/security_monitoring/rules/hrr-a7c-wzl"
8282
},
8383
"response": {
8484
"bodySize": 0,
@@ -94,8 +94,8 @@
9494
"status": 204,
9595
"statusText": "No Content"
9696
},
97-
"startedDateTime": "2022-09-27T13:06:50.921Z",
98-
"time": 468
97+
"startedDateTime": "2022-10-19T13:36:35.218Z",
98+
"time": 380
9999
}
100100
],
101101
"pages": [],
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
"2022-09-27T13:06:51.398Z"
1+
"2022-10-19T13:36:35.608Z"

0 commit comments

Comments
 (0)