From 2e6f81451c265e6bb2cc2446c8435623690a45ec Mon Sep 17 00:00:00 2001 From: "ci.datadog-api-spec" Date: Fri, 12 Mar 2021 10:37:46 +0000 Subject: [PATCH] Regenerate client from commit 95807f2 of spec repo --- .apigentools-info | 8 +- data/v1/openapi.yaml | 77 ++++++++++++++++--- docs/v1/SLOHistoryResponseData.md | 6 +- docs/v1/SLOHistorySLIData.md | 16 +++- .../v1/models/slo_history_metrics.rb | 2 +- .../v1/models/slo_history_response_data.rb | 33 +++++++- .../v1/models/slo_history_sli_data.rb | 64 +++++++++++++-- 7 files changed, 177 insertions(+), 29 deletions(-) diff --git a/.apigentools-info b/.apigentools-info index 7caeeecf3227..0317300b31cf 100644 --- a/.apigentools-info +++ b/.apigentools-info @@ -4,13 +4,13 @@ "spec_versions": { "v1": { "apigentools_version": "1.4.1.dev6", - "regenerated": "2021-03-11 10:10:29.523513", - "spec_repo_commit": "193aff7" + "regenerated": "2021-03-12 10:37:31.735704", + "spec_repo_commit": "95807f2" }, "v2": { "apigentools_version": "1.4.1.dev6", - "regenerated": "2021-03-11 10:10:43.586975", - "spec_repo_commit": "193aff7" + "regenerated": "2021-03-12 10:37:44.418418", + "spec_repo_commit": "95807f2" } } } \ No newline at end of file diff --git a/data/v1/openapi.yaml b/data/v1/openapi.yaml index 5be9f143d546..326aebcb48b2 100644 --- a/data/v1/openapi.yaml +++ b/data/v1/openapi.yaml @@ -5389,6 +5389,13 @@ components: error as value. type: object type: object + SLOErrorBudgetRemainingData: + additionalProperties: + description: Remaining error budget. + format: double + type: number + description: A mapping of threshold `timeframe` to the remaining error budget. + type: object SLOErrorTimeframe: description: 'The timeframe of the threshold associated with this error @@ -5405,7 +5412,10 @@ components: - NINETY_DAYS - ALL SLOHistoryMetrics: - description: A `metric` based SLO history response. + description: 'A `metric` based SLO history response. + + + This is not included in responses for `monitor` based SLOs.' properties: denominator: $ref: '#/components/schemas/SLOHistoryMetricsSeries' @@ -5555,8 +5565,34 @@ components: description: The `from` timestamp in epoch seconds. format: int64 type: integer + group_by: + description: 'For `metric` based SLOs where the query includes a group-by + clause, this represents the list of grouping parameters. + + + This is not included in responses for `monitor` based SLOs.' + items: + description: A grouping parameter. + type: string + type: array groups: - $ref: '#/components/schemas/SLOHistorySLIData' + description: 'For grouped SLOs, this represents SLI data for specific + groups. + + + This is not included in the responses for `metric` based SLOs.' + items: + $ref: '#/components/schemas/SLOHistorySLIData' + type: array + monitors: + description: 'For multi-monitor SLOs, this represents SLI data for specific + monitors. + + + This is not included in the responses for `metric` based SLOs.' + items: + $ref: '#/components/schemas/SLOHistorySLIData' + type: array overall: $ref: '#/components/schemas/SLOHistorySLIData' series: @@ -5591,13 +5627,22 @@ components: type: object SLOHistorySLIData: description: 'An object that holds an SLI value and its associated data. It - can represent + can represent an SLO''s overall SLI value. - an SLO''s overall SLI value or the SLI value for a specific monitor (in multi-monitor - SLOs) - - or group (in grouped SLOs). The uptime history is included for monitor SLOs.' + This can also represent the SLI value for a specific monitor in multi-monitor + SLOs, or a group in grouped SLOs.' properties: + error_budget_remaining: + $ref: '#/components/schemas/SLOErrorBudgetRemainingData' + errors: + description: A list of errors while querying the history data for the service + level objective. + items: + $ref: '#/components/schemas/SLOHistoryResponseError' + type: array + group: + description: For groups in a grouped SLO, this is the group name. + type: string history: description: For `monitor` based SLOs, this includes the aggregated history uptime time series. @@ -5612,9 +5657,17 @@ components: minItems: 2 type: array type: array + monitor_modified: + description: For `monitor` based SLOs, this is the last modified timestamp + in epoch seconds of the monitor. + format: int64 + type: integer + monitor_type: + description: For `monitor` based SLOs, this describes the type of monitor. + type: string name: - description: For groups in a grouped SLO this is the group name. For monitors - in a multi-monitor SLO this is the monitor name. + description: For groups in a grouped SLO, this is the group name. For monitors + in a multi-monitor SLO, this is the monitor name. type: string precision: additionalProperties: @@ -5625,8 +5678,8 @@ components: regardless of the from && to timestamp. type: object preview: - description: 'For `monitor` based SLOs when `true` this indicates that a - replay is in progress to give an accurate uptime + description: 'For `monitor` based SLOs, when `true` this indicates that + a replay is in progress to give an accurate uptime calculation.' type: boolean @@ -5642,7 +5695,7 @@ components: type: number uptime: deprecated: true - description: Deprecated. Use `sli_value` instead. + description: Use `sli_value` instead. format: double type: number type: object diff --git a/docs/v1/SLOHistoryResponseData.md b/docs/v1/SLOHistoryResponseData.md index 603062966063..2b2f32faa9d8 100644 --- a/docs/v1/SLOHistoryResponseData.md +++ b/docs/v1/SLOHistoryResponseData.md @@ -5,7 +5,9 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | | **from_ts** | **Integer** | The `from` timestamp in epoch seconds. | [optional] | -| **groups** | [**SLOHistorySLIData**](SLOHistorySLIData.md) | | [optional] | +| **group_by** | **Array<String>** | For `metric` based SLOs where the query includes a group-by clause, this represents the list of grouping parameters. This is not included in responses for `monitor` based SLOs. | [optional] | +| **groups** | [**Array<SLOHistorySLIData>**](SLOHistorySLIData.md) | For grouped SLOs, this represents SLI data for specific groups. This is not included in the responses for `metric` based SLOs. | [optional] | +| **monitors** | [**Array<SLOHistorySLIData>**](SLOHistorySLIData.md) | For multi-monitor SLOs, this represents SLI data for specific monitors. This is not included in the responses for `metric` based SLOs. | [optional] | | **overall** | [**SLOHistorySLIData**](SLOHistorySLIData.md) | | [optional] | | **series** | [**SLOHistoryMetrics**](SLOHistoryMetrics.md) | | [optional] | | **thresholds** | [**Hash<String, SLOThreshold>**](SLOThreshold.md) | mapping of string timeframe to the SLO threshold. | [optional] | @@ -20,7 +22,9 @@ require 'datadog_api_client/v1' instance = DatadogAPIClient::V1::SLOHistoryResponseData.new( from_ts: null, + group_by: null, groups: null, + monitors: null, overall: null, series: null, thresholds: null, diff --git a/docs/v1/SLOHistorySLIData.md b/docs/v1/SLOHistorySLIData.md index be4763448066..7daae46ad24a 100644 --- a/docs/v1/SLOHistorySLIData.md +++ b/docs/v1/SLOHistorySLIData.md @@ -4,13 +4,18 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | +| **error_budget_remaining** | **Hash<String, Float>** | A mapping of threshold `timeframe` to the remaining error budget. | [optional] | +| **errors** | [**Array<SLOHistoryResponseError>**](SLOHistoryResponseError.md) | A list of errors while querying the history data for the service level objective. | [optional] | +| **group** | **String** | For groups in a grouped SLO, this is the group name. | [optional] | | **history** | **Array<Array<Float>>** | For `monitor` based SLOs, this includes the aggregated history uptime time series. | [optional] | -| **name** | **String** | For groups in a grouped SLO this is the group name. For monitors in a multi-monitor SLO this is the monitor name. | [optional] | +| **monitor_modified** | **Integer** | For `monitor` based SLOs, this is the last modified timestamp in epoch seconds of the monitor. | [optional] | +| **monitor_type** | **String** | For `monitor` based SLOs, this describes the type of monitor. | [optional] | +| **name** | **String** | For groups in a grouped SLO, this is the group name. For monitors in a multi-monitor SLO, this is the monitor name. | [optional] | | **precision** | **Hash<String, Float>** | A mapping of threshold `timeframe` to number of accurate decimals, regardless of the from && to timestamp. | [optional] | -| **preview** | **Boolean** | For `monitor` based SLOs when `true` this indicates that a replay is in progress to give an accurate uptime calculation. | [optional] | +| **preview** | **Boolean** | For `monitor` based SLOs, when `true` this indicates that a replay is in progress to give an accurate uptime calculation. | [optional] | | **sli_value** | **Float** | The current SLI value of the SLO over the history window. | [optional] | | **span_precision** | **Float** | The amount of decimal places the SLI value is accurate to for the given from `&&` to timestamp. | [optional] | -| **uptime** | **Float** | Deprecated. Use `sli_value` instead. | [optional] | +| **uptime** | **Float** | Use `sli_value` instead. | [optional] | ## Example @@ -18,7 +23,12 @@ require 'datadog_api_client/v1' instance = DatadogAPIClient::V1::SLOHistorySLIData.new( + error_budget_remaining: null, + errors: null, + group: null, history: null, + monitor_modified: null, + monitor_type: null, name: null, precision: null, preview: null, diff --git a/lib/datadog_api_client/v1/models/slo_history_metrics.rb b/lib/datadog_api_client/v1/models/slo_history_metrics.rb index 220889021934..2488d86db7e4 100644 --- a/lib/datadog_api_client/v1/models/slo_history_metrics.rb +++ b/lib/datadog_api_client/v1/models/slo_history_metrics.rb @@ -17,7 +17,7 @@ require 'time' module DatadogAPIClient::V1 - # A `metric` based SLO history response. + # A `metric` based SLO history response. This is not included in responses for `monitor` based SLOs. class SLOHistoryMetrics attr_accessor :denominator diff --git a/lib/datadog_api_client/v1/models/slo_history_response_data.rb b/lib/datadog_api_client/v1/models/slo_history_response_data.rb index f441d942f79b..3a0e7276b197 100644 --- a/lib/datadog_api_client/v1/models/slo_history_response_data.rb +++ b/lib/datadog_api_client/v1/models/slo_history_response_data.rb @@ -22,8 +22,15 @@ class SLOHistoryResponseData # The `from` timestamp in epoch seconds. attr_accessor :from_ts + # For `metric` based SLOs where the query includes a group-by clause, this represents the list of grouping parameters. This is not included in responses for `monitor` based SLOs. + attr_accessor :group_by + + # For grouped SLOs, this represents SLI data for specific groups. This is not included in the responses for `metric` based SLOs. attr_accessor :groups + # For multi-monitor SLOs, this represents SLI data for specific monitors. This is not included in the responses for `metric` based SLOs. + attr_accessor :monitors + attr_accessor :overall attr_accessor :series @@ -42,7 +49,9 @@ class SLOHistoryResponseData def self.attribute_map { :'from_ts' => :'from_ts', + :'group_by' => :'group_by', :'groups' => :'groups', + :'monitors' => :'monitors', :'overall' => :'overall', :'series' => :'series', :'thresholds' => :'thresholds', @@ -61,7 +70,9 @@ def self.acceptable_attributes def self.openapi_types { :'from_ts' => :'Integer', - :'groups' => :'SLOHistorySLIData', + :'group_by' => :'Array', + :'groups' => :'Array', + :'monitors' => :'Array', :'overall' => :'SLOHistorySLIData', :'series' => :'SLOHistoryMetrics', :'thresholds' => :'Hash', @@ -96,8 +107,22 @@ def initialize(attributes = {}) self.from_ts = attributes[:'from_ts'] end + if attributes.key?(:'group_by') + if (value = attributes[:'group_by']).is_a?(Array) + self.group_by = value + end + end + if attributes.key?(:'groups') - self.groups = attributes[:'groups'] + if (value = attributes[:'groups']).is_a?(Array) + self.groups = value + end + end + + if attributes.key?(:'monitors') + if (value = attributes[:'monitors']).is_a?(Array) + self.monitors = value + end end if attributes.key?(:'overall') @@ -146,7 +171,9 @@ def ==(o) return true if self.equal?(o) self.class == o.class && from_ts == o.from_ts && + group_by == o.group_by && groups == o.groups && + monitors == o.monitors && overall == o.overall && series == o.series && thresholds == o.thresholds && @@ -164,7 +191,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Integer] Hash code def hash - [from_ts, groups, overall, series, thresholds, to_ts, type, type_id].hash + [from_ts, group_by, groups, monitors, overall, series, thresholds, to_ts, type, type_id].hash end # Builds the object from hash diff --git a/lib/datadog_api_client/v1/models/slo_history_sli_data.rb b/lib/datadog_api_client/v1/models/slo_history_sli_data.rb index d0bc104c90e5..003438ebe4da 100644 --- a/lib/datadog_api_client/v1/models/slo_history_sli_data.rb +++ b/lib/datadog_api_client/v1/models/slo_history_sli_data.rb @@ -17,18 +17,33 @@ require 'time' module DatadogAPIClient::V1 - # An object that holds an SLI value and its associated data. It can represent an SLO's overall SLI value or the SLI value for a specific monitor (in multi-monitor SLOs) or group (in grouped SLOs). The uptime history is included for monitor SLOs. + # An object that holds an SLI value and its associated data. It can represent an SLO's overall SLI value. This can also represent the SLI value for a specific monitor in multi-monitor SLOs, or a group in grouped SLOs. class SLOHistorySLIData + # A mapping of threshold `timeframe` to the remaining error budget. + attr_accessor :error_budget_remaining + + # A list of errors while querying the history data for the service level objective. + attr_accessor :errors + + # For groups in a grouped SLO, this is the group name. + attr_accessor :group + # For `monitor` based SLOs, this includes the aggregated history uptime time series. attr_accessor :history - # For groups in a grouped SLO this is the group name. For monitors in a multi-monitor SLO this is the monitor name. + # For `monitor` based SLOs, this is the last modified timestamp in epoch seconds of the monitor. + attr_accessor :monitor_modified + + # For `monitor` based SLOs, this describes the type of monitor. + attr_accessor :monitor_type + + # For groups in a grouped SLO, this is the group name. For monitors in a multi-monitor SLO, this is the monitor name. attr_accessor :name # A mapping of threshold `timeframe` to number of accurate decimals, regardless of the from && to timestamp. attr_accessor :precision - # For `monitor` based SLOs when `true` this indicates that a replay is in progress to give an accurate uptime calculation. + # For `monitor` based SLOs, when `true` this indicates that a replay is in progress to give an accurate uptime calculation. attr_accessor :preview # The current SLI value of the SLO over the history window. @@ -37,13 +52,18 @@ class SLOHistorySLIData # The amount of decimal places the SLI value is accurate to for the given from `&&` to timestamp. attr_accessor :span_precision - # Deprecated. Use `sli_value` instead. + # Use `sli_value` instead. attr_accessor :uptime # Attribute mapping from ruby-style variable name to JSON key. def self.attribute_map { + :'error_budget_remaining' => :'error_budget_remaining', + :'errors' => :'errors', + :'group' => :'group', :'history' => :'history', + :'monitor_modified' => :'monitor_modified', + :'monitor_type' => :'monitor_type', :'name' => :'name', :'precision' => :'precision', :'preview' => :'preview', @@ -61,7 +81,12 @@ def self.acceptable_attributes # Attribute type mapping. def self.openapi_types { + :'error_budget_remaining' => :'Hash', + :'errors' => :'Array', + :'group' => :'String', :'history' => :'Array>', + :'monitor_modified' => :'Integer', + :'monitor_type' => :'String', :'name' => :'String', :'precision' => :'Hash', :'preview' => :'Boolean', @@ -92,12 +117,36 @@ def initialize(attributes = {}) h[k.to_sym] = v } + if attributes.key?(:'error_budget_remaining') + if (value = attributes[:'error_budget_remaining']).is_a?(Hash) + self.error_budget_remaining = value + end + end + + if attributes.key?(:'errors') + if (value = attributes[:'errors']).is_a?(Array) + self.errors = value + end + end + + if attributes.key?(:'group') + self.group = attributes[:'group'] + end + if attributes.key?(:'history') if (value = attributes[:'history']).is_a?(Array) self.history = value end end + if attributes.key?(:'monitor_modified') + self.monitor_modified = attributes[:'monitor_modified'] + end + + if attributes.key?(:'monitor_type') + self.monitor_type = attributes[:'monitor_type'] + end + if attributes.key?(:'name') self.name = attributes[:'name'] end @@ -143,7 +192,12 @@ def valid? def ==(o) return true if self.equal?(o) self.class == o.class && + error_budget_remaining == o.error_budget_remaining && + errors == o.errors && + group == o.group && history == o.history && + monitor_modified == o.monitor_modified && + monitor_type == o.monitor_type && name == o.name && precision == o.precision && preview == o.preview && @@ -161,7 +215,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Integer] Hash code def hash - [history, name, precision, preview, sli_value, span_precision, uptime].hash + [error_budget_remaining, errors, group, history, monitor_modified, monitor_type, name, precision, preview, sli_value, span_precision, uptime].hash end # Builds the object from hash