From 55a10e9f06714dfc998b320aca710461f3b4d810 Mon Sep 17 00:00:00 2001 From: "ci.datadog-api-spec" Date: Wed, 4 Aug 2021 18:58:09 +0000 Subject: [PATCH] Regenerate client from commit dafdffa of spec repo --- .apigentools-info | 8 +- api/v1/datadog/api/openapi.yaml | 126 +++++++++++++----------- api/v1/datadog/docs/MonitorOptions.md | 38 ++++++- api/v1/datadog/model_monitor_options.go | 52 +++++++++- 4 files changed, 163 insertions(+), 61 deletions(-) diff --git a/.apigentools-info b/.apigentools-info index 1afc062a4d4..f80bd5dd1f0 100644 --- a/.apigentools-info +++ b/.apigentools-info @@ -4,13 +4,13 @@ "spec_versions": { "v1": { "apigentools_version": "1.4.1.dev11", - "regenerated": "2021-08-04 16:37:23.957844", - "spec_repo_commit": "c6e36ca" + "regenerated": "2021-08-04 18:57:37.836661", + "spec_repo_commit": "dafdffa" }, "v2": { "apigentools_version": "1.4.1.dev11", - "regenerated": "2021-08-04 16:37:54.999270", - "spec_repo_commit": "c6e36ca" + "regenerated": "2021-08-04 18:58:07.961612", + "spec_repo_commit": "dafdffa" } } } \ No newline at end of file diff --git a/api/v1/datadog/api/openapi.yaml b/api/v1/datadog/api/openapi.yaml index c5b6c2f47fe..d9b17006a83 100644 --- a/api/v1/datadog/api/openapi.yaml +++ b/api/v1/datadog/api/openapi.yaml @@ -15543,9 +15543,9 @@ components: deleted: 2000-01-23T04:56:07.000+00:00 name: name options: - no_data_timeframe: 2 + no_data_timeframe: 7 silenced: - key: 9 + key: 3 synthetics_check_id: synthetics_check_id notify_no_data: false enable_logs_sample: true @@ -15557,15 +15557,16 @@ components: groupby_simple_monitor: true notify_audit: false min_location_failed: 5 - new_host_delay: 5 - renotify_interval: 7 + new_host_delay: 2 + renotify_interval: 9 thresholds: - critical: 3.616076749251911 - warning: 1.2315135367772556 - warning_recovery: 1.0246457001441578 - ok: 4.145608029883936 - critical_recovery: 2.027123023002322 - unknown: 7.386281948385884 + critical: 2.027123023002322 + warning: 1.0246457001441578 + warning_recovery: 1.4894159098541704 + ok: 7.386281948385884 + critical_recovery: 4.145608029883936 + unknown: 1.2315135367772556 + new_group_delay: 5 min_failure_duration: 1055 threshold_windows: trigger_window: trigger_window @@ -15576,18 +15577,18 @@ components: - null - null escalation_message: none - timeout_h: 1 + timeout_h: 6 locked: true modified: 2000-01-23T04:56:07.000+00:00 id: 0 state: groups: key: - last_triggered_ts: 5 - last_notified_ts: 1 + last_triggered_ts: 9 + last_notified_ts: 4 name: name - last_resolved_ts: 4 - last_nodata_ts: 7 + last_resolved_ts: 5 + last_nodata_ts: 1 properties: created: description: Timestamp of the monitor creation. @@ -15766,9 +15767,9 @@ components: MonitorOptions: description: List of options associated with your monitor. example: - no_data_timeframe: 2 + no_data_timeframe: 7 silenced: - key: 9 + key: 3 synthetics_check_id: synthetics_check_id notify_no_data: false enable_logs_sample: true @@ -15780,15 +15781,16 @@ components: groupby_simple_monitor: true notify_audit: false min_location_failed: 5 - new_host_delay: 5 - renotify_interval: 7 + new_host_delay: 2 + renotify_interval: 9 thresholds: - critical: 3.616076749251911 - warning: 1.2315135367772556 - warning_recovery: 1.0246457001441578 - ok: 4.145608029883936 - critical_recovery: 2.027123023002322 - unknown: 7.386281948385884 + critical: 2.027123023002322 + warning: 1.0246457001441578 + warning_recovery: 1.4894159098541704 + ok: 7.386281948385884 + critical_recovery: 4.145608029883936 + unknown: 1.2315135367772556 + new_group_delay: 5 min_failure_duration: 1055 threshold_windows: trigger_window: trigger_window @@ -15799,7 +15801,7 @@ components: - null - null escalation_message: none - timeout_h: 1 + timeout_h: 6 locked: true properties: aggregation: @@ -15865,12 +15867,25 @@ components: format: int64 nullable: true type: integer + new_group_delay: + description: |- + Time (in seconds) to skip evaluations for new groups. + + For example, this option can be used to skip evaluations for new hosts while they initialize. + + Must be a non negative integer. + format: int64 + nullable: true + type: integer new_host_delay: default: 300 + deprecated: true description: |- Time (in seconds) to allow a host to boot and applications to fully start before starting the evaluation of monitor results. Should be a non negative integer. + + Use new_group_delay instead. format: int64 nullable: true type: integer @@ -16135,11 +16150,11 @@ components: example: groups: key: - last_triggered_ts: 5 - last_notified_ts: 1 + last_triggered_ts: 9 + last_notified_ts: 4 name: name - last_resolved_ts: 4 - last_nodata_ts: 7 + last_resolved_ts: 5 + last_nodata_ts: 1 properties: groups: additionalProperties: @@ -16153,11 +16168,11 @@ components: MonitorStateGroup: description: Monitor state for a single group. example: - last_triggered_ts: 5 - last_notified_ts: 1 + last_triggered_ts: 9 + last_notified_ts: 4 name: name - last_resolved_ts: 4 - last_nodata_ts: 7 + last_resolved_ts: 5 + last_nodata_ts: 1 properties: last_nodata_ts: description: Latest timestamp the monitor was in NO_DATA state. @@ -16259,12 +16274,12 @@ components: MonitorThresholds: description: List of the different monitor threshold available. example: - critical: 3.616076749251911 - warning: 1.2315135367772556 - warning_recovery: 1.0246457001441578 - ok: 4.145608029883936 - critical_recovery: 2.027123023002322 - unknown: 7.386281948385884 + critical: 2.027123023002322 + warning: 1.0246457001441578 + warning_recovery: 1.4894159098541704 + ok: 7.386281948385884 + critical_recovery: 4.145608029883936 + unknown: 1.2315135367772556 properties: critical: description: The monitor `CRITICAL` threshold. @@ -16350,9 +16365,9 @@ components: deleted: 2000-01-23T04:56:07.000+00:00 name: name options: - no_data_timeframe: 2 + no_data_timeframe: 7 silenced: - key: 9 + key: 3 synthetics_check_id: synthetics_check_id notify_no_data: false enable_logs_sample: true @@ -16364,15 +16379,16 @@ components: groupby_simple_monitor: true notify_audit: false min_location_failed: 5 - new_host_delay: 5 - renotify_interval: 7 + new_host_delay: 2 + renotify_interval: 9 thresholds: - critical: 3.616076749251911 - warning: 1.2315135367772556 - warning_recovery: 1.0246457001441578 - ok: 4.145608029883936 - critical_recovery: 2.027123023002322 - unknown: 7.386281948385884 + critical: 2.027123023002322 + warning: 1.0246457001441578 + warning_recovery: 1.4894159098541704 + ok: 7.386281948385884 + critical_recovery: 4.145608029883936 + unknown: 1.2315135367772556 + new_group_delay: 5 min_failure_duration: 1055 threshold_windows: trigger_window: trigger_window @@ -16383,18 +16399,18 @@ components: - null - null escalation_message: none - timeout_h: 1 + timeout_h: 6 locked: true modified: 2000-01-23T04:56:07.000+00:00 id: 0 state: groups: key: - last_triggered_ts: 5 - last_notified_ts: 1 + last_triggered_ts: 9 + last_notified_ts: 4 name: name - last_resolved_ts: 4 - last_nodata_ts: 7 + last_resolved_ts: 5 + last_nodata_ts: 1 properties: created: description: Timestamp of the monitor creation. diff --git a/api/v1/datadog/docs/MonitorOptions.md b/api/v1/datadog/docs/MonitorOptions.md index 36dc7b7bdc8..3b567ad7ac6 100644 --- a/api/v1/datadog/docs/MonitorOptions.md +++ b/api/v1/datadog/docs/MonitorOptions.md @@ -14,7 +14,8 @@ Name | Type | Description | Notes **Locked** | Pointer to **bool** | Whether or not the monitor is locked (only editable by creator and admins). | [optional] **MinFailureDuration** | Pointer to **NullableInt64** | How long the test should be in failure before alerting (integer, number of seconds, max 7200). | [optional] [default to 0] **MinLocationFailed** | Pointer to **NullableInt64** | The minimum number of locations in failure at the same time during at least one moment in the `min_failure_duration` period (`min_location_failed` and `min_failure_duration` are part of the advanced alerting rules - integer, >= 1). | [optional] [default to 1] -**NewHostDelay** | Pointer to **NullableInt64** | Time (in seconds) to allow a host to boot and applications to fully start before starting the evaluation of monitor results. Should be a non negative integer. | [optional] [default to 300] +**NewGroupDelay** | Pointer to **NullableInt64** | Time (in seconds) to skip evaluations for new groups. For example, this option can be used to skip evaluations for new hosts while they initialize. Must be a non negative integer. | [optional] +**NewHostDelay** | Pointer to **NullableInt64** | Time (in seconds) to allow a host to boot and applications to fully start before starting the evaluation of monitor results. Should be a non negative integer. Use new_group_delay instead. | [optional] [default to 300] **NoDataTimeframe** | Pointer to **NullableInt64** | The number of minutes before a monitor notifies after data stops reporting. Datadog recommends at least 2x the monitor timeframe for metric alerts or 2 minutes for service checks. If omitted, 2x the evaluation timeframe is used for metric alerts, and 24 hours is used for service checks. | [optional] **NotifyAudit** | Pointer to **bool** | A Boolean indicating whether tagged users is notified on changes to this monitor. | [optional] [default to false] **NotifyNoData** | Pointer to **bool** | A Boolean indicating whether this monitor notifies when data stops reporting. | [optional] [default to false] @@ -325,6 +326,41 @@ HasMinLocationFailed returns a boolean if a field has been set. `func (o *MonitorOptions) UnsetMinLocationFailed()` UnsetMinLocationFailed ensures that no value is present for MinLocationFailed, not even an explicit nil +### GetNewGroupDelay + +`func (o *MonitorOptions) GetNewGroupDelay() int64` + +GetNewGroupDelay returns the NewGroupDelay field if non-nil, zero value otherwise. + +### GetNewGroupDelayOk + +`func (o *MonitorOptions) GetNewGroupDelayOk() (*int64, bool)` + +GetNewGroupDelayOk returns a tuple with the NewGroupDelay field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetNewGroupDelay + +`func (o *MonitorOptions) SetNewGroupDelay(v int64)` + +SetNewGroupDelay sets NewGroupDelay field to given value. + +### HasNewGroupDelay + +`func (o *MonitorOptions) HasNewGroupDelay() bool` + +HasNewGroupDelay returns a boolean if a field has been set. + +### SetNewGroupDelayNil + +`func (o *MonitorOptions) SetNewGroupDelayNil(b bool)` + + SetNewGroupDelayNil sets the value for NewGroupDelay to be an explicit nil + +### UnsetNewGroupDelay +`func (o *MonitorOptions) UnsetNewGroupDelay()` + +UnsetNewGroupDelay ensures that no value is present for NewGroupDelay, not even an explicit nil ### GetNewHostDelay `func (o *MonitorOptions) GetNewHostDelay() int64` diff --git a/api/v1/datadog/model_monitor_options.go b/api/v1/datadog/model_monitor_options.go index 470fd949638..c12a0b65e6c 100644 --- a/api/v1/datadog/model_monitor_options.go +++ b/api/v1/datadog/model_monitor_options.go @@ -33,7 +33,9 @@ type MonitorOptions struct { MinFailureDuration NullableInt64 `json:"min_failure_duration,omitempty"` // The minimum number of locations in failure at the same time during at least one moment in the `min_failure_duration` period (`min_location_failed` and `min_failure_duration` are part of the advanced alerting rules - integer, >= 1). MinLocationFailed NullableInt64 `json:"min_location_failed,omitempty"` - // Time (in seconds) to allow a host to boot and applications to fully start before starting the evaluation of monitor results. Should be a non negative integer. + // Time (in seconds) to skip evaluations for new groups. For example, this option can be used to skip evaluations for new hosts while they initialize. Must be a non negative integer. + NewGroupDelay NullableInt64 `json:"new_group_delay,omitempty"` + // Time (in seconds) to allow a host to boot and applications to fully start before starting the evaluation of monitor results. Should be a non negative integer. Use new_group_delay instead. NewHostDelay NullableInt64 `json:"new_host_delay,omitempty"` // The number of minutes before a monitor notifies after data stops reporting. Datadog recommends at least 2x the monitor timeframe for metric alerts or 2 minutes for service checks. If omitted, 2x the evaluation timeframe is used for metric alerts, and 24 hours is used for service checks. NoDataTimeframe NullableInt64 `json:"no_data_timeframe,omitempty"` @@ -455,6 +457,49 @@ func (o *MonitorOptions) UnsetMinLocationFailed() { o.MinLocationFailed.Unset() } +// GetNewGroupDelay returns the NewGroupDelay field value if set, zero value otherwise (both if not set or set to explicit null). +func (o *MonitorOptions) GetNewGroupDelay() int64 { + if o == nil || o.NewGroupDelay.Get() == nil { + var ret int64 + return ret + } + return *o.NewGroupDelay.Get() +} + +// GetNewGroupDelayOk returns a tuple with the NewGroupDelay field value if set, nil otherwise +// and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned +func (o *MonitorOptions) GetNewGroupDelayOk() (*int64, bool) { + if o == nil { + return nil, false + } + return o.NewGroupDelay.Get(), o.NewGroupDelay.IsSet() +} + +// HasNewGroupDelay returns a boolean if a field has been set. +func (o *MonitorOptions) HasNewGroupDelay() bool { + if o != nil && o.NewGroupDelay.IsSet() { + return true + } + + return false +} + +// SetNewGroupDelay gets a reference to the given NullableInt64 and assigns it to the NewGroupDelay field. +func (o *MonitorOptions) SetNewGroupDelay(v int64) { + o.NewGroupDelay.Set(&v) +} + +// SetNewGroupDelayNil sets the value for NewGroupDelay to be an explicit nil +func (o *MonitorOptions) SetNewGroupDelayNil() { + o.NewGroupDelay.Set(nil) +} + +// UnsetNewGroupDelay ensures that no value is present for NewGroupDelay, not even an explicit nil +func (o *MonitorOptions) UnsetNewGroupDelay() { + o.NewGroupDelay.Unset() +} + // GetNewHostDelay returns the NewHostDelay field value if set, zero value otherwise (both if not set or set to explicit null). func (o *MonitorOptions) GetNewHostDelay() int64 { if o == nil || o.NewHostDelay.Get() == nil { @@ -897,6 +942,9 @@ func (o MonitorOptions) MarshalJSON() ([]byte, error) { if o.MinLocationFailed.IsSet() { toSerialize["min_location_failed"] = o.MinLocationFailed.Get() } + if o.NewGroupDelay.IsSet() { + toSerialize["new_group_delay"] = o.NewGroupDelay.Get() + } if o.NewHostDelay.IsSet() { toSerialize["new_host_delay"] = o.NewHostDelay.Get() } @@ -946,6 +994,7 @@ func (o *MonitorOptions) UnmarshalJSON(bytes []byte) (err error) { Locked *bool `json:"locked,omitempty"` MinFailureDuration NullableInt64 `json:"min_failure_duration,omitempty"` MinLocationFailed NullableInt64 `json:"min_location_failed,omitempty"` + NewGroupDelay NullableInt64 `json:"new_group_delay,omitempty"` NewHostDelay NullableInt64 `json:"new_host_delay,omitempty"` NoDataTimeframe NullableInt64 `json:"no_data_timeframe,omitempty"` NotifyAudit *bool `json:"notify_audit,omitempty"` @@ -977,6 +1026,7 @@ func (o *MonitorOptions) UnmarshalJSON(bytes []byte) (err error) { o.Locked = all.Locked o.MinFailureDuration = all.MinFailureDuration o.MinLocationFailed = all.MinLocationFailed + o.NewGroupDelay = all.NewGroupDelay o.NewHostDelay = all.NewHostDelay o.NoDataTimeframe = all.NoDataTimeframe o.NotifyAudit = all.NotifyAudit