Skip to content
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
23 changes: 18 additions & 5 deletions .generator/schemas/v1/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7973,6 +7973,7 @@ components:
- spans
- database_queries
- network
- network_path
example: rum
type: string
x-enum-varnames:
Expand All @@ -7985,6 +7986,7 @@ components:
- SPANS
- DATABASE_QUERIES
- NETWORK
- NETWORK_PATH
MonitorFormulaAndFunctionQueryDefinition:
description: A formula and function query.
oneOf:
Expand Down Expand Up @@ -8830,6 +8832,7 @@ components:
- network-performance alert
- cost alert
- data-quality alert
- network-path alert
example: query alert
type: string
x-enum-varnames:
Expand All @@ -8853,6 +8856,7 @@ components:
- NETWORK_PERFORMANCE_ALERT
- COST_ALERT
- DATA_QUALITY_ALERT
- NETWORK_PATH_ALERT
MonitorUpdateRequest:
description: Object describing a monitor update request.
properties:
Expand Down Expand Up @@ -31643,10 +31647,11 @@ paths:
alert`\n- watchdog: `event-v2 alert`\n- event-v2: `event-v2 alert`\n- audit:
`audit alert`\n- error-tracking: `error-tracking alert`\n- database-monitoring:
`database-monitoring alert`\n- network-performance: `network-performance alert`\n-
cloud cost: `cost alert`\n\n**Notes**:\n- Synthetic monitors are created through
the Synthetics API. See the [Synthetics API](https://docs.datadoghq.com/api/latest/synthetics/)
documentation for more information.\n- Log monitors require an unscoped App
Key.\n\n#### Query Types\n\n##### Metric Alert Query\n\nExample: `time_aggr(time_window):space_aggr:metric{tags}
cloud cost: `cost alert`\n- network-path: `network-path alert`\n\n**Notes**:\n-
Synthetic monitors are created through the Synthetics API. See the [Synthetics
API](https://docs.datadoghq.com/api/latest/synthetics/) documentation for
more information.\n- Log monitors require an unscoped App Key.\n\n#### Query
Types\n\n##### Metric Alert Query\n\nExample: `time_aggr(time_window):space_aggr:metric{tags}
[by {key}] operator #`\n\n- `time_aggr`: avg, sum, max, min, change, or pct_change\n-
`time_window`: `last_#m` (with `#` between 1 and 10080 depending on the monitor
type) or `last_#h`(with `#` between 1 and 168 depending on the monitor type)
Expand Down Expand Up @@ -31776,7 +31781,15 @@ paths:
\ - for `threshold` supports `<`, `<=`, `>`, `>=`, `==`, or `!=`\n -
for `change` supports `>`, `<`\n - for `anomaly` supports `>=`\n - for
`forecast` supports `>`\n- `#` an integer or decimal number used to set the
threshold."
threshold.\n\n**Network Path Alert Query**\n\nExample: `network-path(query).index(index_name).rollup(rollup_method[,
measure]).last(time_window) operator #`\n\n- `query` The search query - following
the [Log search syntax](https://docs.datadoghq.com/logs/search_syntax/).\n-
`index_name` The data type to monitor on - supports `netpath-path` and `netpath-hop`.\n-
`rollup_method` The stats roll-up method - supports `count`, `avg`, and `cardinality`.\n-
`measure` For `avg` and cardinality `rollup_method` - specify the measure
or the facet name you want to use.\n- `time_window` #m (between 1 and 2880),
#h (between 1 and 48).\n- `operator` `<`, `<=`, `>`, `>=`, `==`, or `!=`.\n-
`#` an integer or decimal number used to set the threshold."
operationId: CreateMonitor
requestBody:
content:
Expand Down
22 changes: 22 additions & 0 deletions src/main/java/com/datadog/api/client/v1/api/MonitorsApi.java
Original file line number Diff line number Diff line change
Expand Up @@ -253,6 +253,7 @@ public CompletableFuture<Monitor> createMonitorAsync(Monitor body) {
* <li>database-monitoring: <code>database-monitoring alert</code>
* <li>network-performance: <code>network-performance alert</code>
* <li>cloud cost: <code>cost alert</code>
* <li>network-path: <code>network-path alert</code>
* </ul>
*
* <p><strong>Notes</strong>: - Synthetic monitors are created through the Synthetics API. See the
Expand Down Expand Up @@ -565,6 +566,27 @@ public CompletableFuture<Monitor> createMonitorAsync(Monitor body) {
* <li><code>#</code> an integer or decimal number used to set the threshold.
* </ul>
*
* <p><strong>Network Path Alert Query</strong>
*
* <p>Example: <code>
* network-path(query).index(index_name).rollup(rollup_method[, measure]).last(time_window) operator #
* </code>
*
* <ul>
* <li><code>query</code> The search query - following the <a
* href="https://docs.datadoghq.com/logs/search_syntax/">Log search syntax</a>.
* <li><code>index_name</code> The data type to monitor on - supports <code>netpath-path</code>
* and <code>netpath-hop</code>.
* <li><code>rollup_method</code> The stats roll-up method - supports <code>count</code>, <code>
* avg</code>, and <code>cardinality</code>.
* <li><code>measure</code> For <code>avg</code> and cardinality <code>rollup_method</code> -
* specify the measure or the facet name you want to use.
* <li><code>time_window</code> #m (between 1 and 2880), #h (between 1 and 48).
* <li><code>operator</code> <code>&lt;</code>, <code>&lt;=</code>, <code>&gt;</code>, <code>
* &gt;=</code>, <code>==</code>, or <code>!=</code>.
* <li><code>#</code> an integer or decimal number used to set the threshold.
* </ul>
*
* @param body Create a monitor request body. (required)
* @return ApiResponse&lt;Monitor&gt;
* @throws ApiException if fails to make API call
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,8 @@ public class MonitorFormulaAndFunctionEventsDataSource extends ModelEnum<String>
"logs",
"spans",
"database_queries",
"network"));
"network",
"network_path"));

public static final MonitorFormulaAndFunctionEventsDataSource RUM =
new MonitorFormulaAndFunctionEventsDataSource("rum");
Expand All @@ -56,6 +57,8 @@ public class MonitorFormulaAndFunctionEventsDataSource extends ModelEnum<String>
new MonitorFormulaAndFunctionEventsDataSource("database_queries");
public static final MonitorFormulaAndFunctionEventsDataSource NETWORK =
new MonitorFormulaAndFunctionEventsDataSource("network");
public static final MonitorFormulaAndFunctionEventsDataSource NETWORK_PATH =
new MonitorFormulaAndFunctionEventsDataSource("network_path");

MonitorFormulaAndFunctionEventsDataSource(String value) {
super(value, allowedValues);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,8 @@ public class MonitorType extends ModelEnum<String> {
"database-monitoring alert",
"network-performance alert",
"cost alert",
"data-quality alert"));
"data-quality alert",
"network-path alert"));

public static final MonitorType COMPOSITE = new MonitorType("composite");
public static final MonitorType EVENT_ALERT = new MonitorType("event alert");
Expand All @@ -71,6 +72,7 @@ public class MonitorType extends ModelEnum<String> {
new MonitorType("network-performance alert");
public static final MonitorType COST_ALERT = new MonitorType("cost alert");
public static final MonitorType DATA_QUALITY_ALERT = new MonitorType("data-quality alert");
public static final MonitorType NETWORK_PATH_ALERT = new MonitorType("network-path alert");

MonitorType(String value) {
super(value, allowedValues);
Expand Down
Loading