datadog_api_client 2.57.0 → 2.58.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.generator/schemas/v1/openapi.yaml +2 -0
- data/.generator/schemas/v2/openapi.yaml +748 -397
- data/CHANGELOG.md +21 -0
- data/examples/v1/monitors/CreateMonitor_1348801712.rb +23 -0
- data/examples/v2/ci-visibility-github-accounts/ListCIAppGitHubAccounts.rb +5 -0
- data/examples/v2/ci-visibility-github-accounts/UpdateCIAppGitHubAccount.rb +20 -0
- data/examples/v2/dora-metrics/PatchDORADeploymentByVersion.rb +24 -0
- data/examples/v2/governance-console/UpdateGovernanceControl.rb +0 -1
- data/examples/v2/status-pages/PatchMaintenanceUpdate.rb +15 -0
- data/lib/datadog_api_client/configuration.rb +1 -3
- data/lib/datadog_api_client/inflector.rb +33 -14
- data/lib/datadog_api_client/v1/models/monitor_type.rb +1 -0
- data/lib/datadog_api_client/v2/api/ci_visibility_git_hub_accounts_api.rb +160 -0
- data/lib/datadog_api_client/v2/api/dora_metrics_api.rb +73 -0
- data/lib/datadog_api_client/v2/api/status_pages_api.rb +83 -1
- data/lib/datadog_api_client/v2/models/agent_trigger.rb +105 -0
- data/lib/datadog_api_client/v2/models/agent_trigger_wrapper.rb +135 -0
- data/lib/datadog_api_client/v2/models/api_trigger_wrapper.rb +1 -1
- data/lib/datadog_api_client/v2/models/app_trigger_wrapper.rb +1 -1
- data/lib/datadog_api_client/v2/models/case_trigger_wrapper.rb +1 -1
- data/lib/datadog_api_client/v2/models/change_event_trigger_wrapper.rb +1 -1
- data/lib/datadog_api_client/v2/models/ci_app_git_hub_account_attributes.rb +147 -0
- data/lib/datadog_api_client/v2/models/{rum_rate_limit_config_data.rb → ci_app_git_hub_account_data.rb} +10 -8
- data/lib/datadog_api_client/v2/models/ci_app_git_hub_account_repository.rb +115 -0
- data/lib/datadog_api_client/v2/models/{rum_rate_limit_config_response.rb → ci_app_git_hub_account_response.rb} +5 -5
- data/lib/datadog_api_client/v2/models/{rum_rate_limit_quota_reached_action.rb → ci_app_git_hub_account_type.rb} +4 -4
- data/lib/datadog_api_client/v2/models/{rum_rate_limit_config_update_request.rb → ci_app_git_hub_account_update_request.rb} +5 -5
- data/lib/datadog_api_client/v2/models/ci_app_git_hub_account_update_request_attributes.rb +159 -0
- data/lib/datadog_api_client/v2/models/ci_app_git_hub_account_update_request_data.rb +146 -0
- data/lib/datadog_api_client/v2/models/ci_app_git_hub_account_update_request_repository.rb +148 -0
- data/lib/datadog_api_client/v2/models/{rum_rate_limit_adaptive_config.rb → ci_app_git_hub_accounts_response.rb} +19 -25
- data/lib/datadog_api_client/v2/models/completion_condition.rb +4 -29
- data/lib/datadog_api_client/v2/models/completion_gate.rb +4 -29
- data/lib/datadog_api_client/v2/models/create_degradation_request.rb +13 -3
- data/lib/datadog_api_client/v2/models/create_status_page_request_data_attributes.rb +1 -11
- data/lib/datadog_api_client/v2/models/create_table_request_data_attributes_schema.rb +9 -1
- data/lib/datadog_api_client/v2/models/create_upload_request_data_attributes.rb +5 -1
- data/lib/datadog_api_client/v2/models/dashboard_trigger_wrapper.rb +1 -1
- data/lib/datadog_api_client/v2/models/database_monitoring_trigger_wrapper.rb +1 -1
- data/lib/datadog_api_client/v2/models/datastore_trigger_wrapper.rb +1 -1
- data/lib/datadog_api_client/v2/models/degradation_request_meta.rb +105 -0
- data/lib/datadog_api_client/v2/models/deployment_gates_fdd_rule_options.rb +13 -1
- data/lib/datadog_api_client/v2/models/deployment_rule_options_faulty_deployment_detection.rb +13 -1
- data/lib/datadog_api_client/v2/models/dora_deployment_patch_by_version_remediation.rb +63 -0
- data/lib/datadog_api_client/v2/models/dora_deployment_patch_by_version_remediation_by_id.rb +119 -0
- data/lib/datadog_api_client/v2/models/dora_deployment_patch_by_version_remediation_by_version.rb +119 -0
- data/lib/datadog_api_client/v2/models/dora_deployment_patch_by_version_request.rb +123 -0
- data/lib/datadog_api_client/v2/models/dora_deployment_patch_by_version_request_attributes.rb +196 -0
- data/lib/datadog_api_client/v2/models/dora_deployment_patch_by_version_request_data.rb +144 -0
- data/lib/datadog_api_client/v2/models/dora_deployment_patch_remediation.rb +15 -5
- data/lib/datadog_api_client/v2/models/dora_deployment_patch_request_attributes.rb +1 -1
- data/lib/datadog_api_client/v2/models/error_handler.rb +4 -29
- data/lib/datadog_api_client/v2/models/fleet_agent_info_details_v2.rb +1 -49
- data/lib/datadog_api_client/v2/models/form_trigger_wrapper.rb +1 -1
- data/lib/datadog_api_client/v2/models/github_webhook_trigger_wrapper.rb +1 -1
- data/lib/datadog_api_client/v2/models/governance_control_attributes.rb +1 -22
- data/lib/datadog_api_client/v2/models/governance_control_parameter_definition.rb +10 -13
- data/lib/datadog_api_client/v2/models/governance_control_update_attributes.rb +1 -11
- data/lib/datadog_api_client/v2/models/incident_trigger_wrapper.rb +1 -1
- data/lib/datadog_api_client/v2/models/input_schema_parameters.rb +4 -0
- data/lib/datadog_api_client/v2/models/maintenance_update.rb +105 -0
- data/lib/datadog_api_client/v2/models/maintenance_update_data.rb +164 -0
- data/lib/datadog_api_client/v2/models/maintenance_update_data_attributes.rb +167 -0
- data/lib/datadog_api_client/v2/models/{rum_rate_limit_config_type.rb → maintenance_update_data_attributes_status.rb} +6 -3
- data/lib/datadog_api_client/v2/models/maintenance_update_data_relationships.rb +125 -0
- data/lib/datadog_api_client/v2/models/maintenance_update_data_relationships_maintenance.rb +123 -0
- data/lib/datadog_api_client/v2/models/maintenance_update_data_relationships_maintenance_data.rb +144 -0
- data/lib/datadog_api_client/v2/models/{rum_rate_limit_config_update_attributes.rb → maintenance_update_data_relationships_user.rb} +17 -38
- data/lib/datadog_api_client/v2/models/maintenance_update_data_relationships_user_data.rb +144 -0
- data/lib/datadog_api_client/v2/models/monitor_trigger_wrapper.rb +1 -1
- data/lib/datadog_api_client/v2/models/notebook_trigger_wrapper.rb +1 -1
- data/lib/datadog_api_client/v2/models/on_call_trigger_wrapper.rb +1 -1
- data/lib/datadog_api_client/v2/models/outbound_edge.rb +8 -0
- data/lib/datadog_api_client/v2/models/parameter.rb +4 -0
- data/lib/datadog_api_client/v2/models/patch_degradation_request.rb +13 -3
- data/lib/datadog_api_client/v2/models/patch_maintenance_request_data_attributes.rb +11 -1
- data/lib/datadog_api_client/v2/models/patch_maintenance_update_request.rb +105 -0
- data/lib/datadog_api_client/v2/models/{rum_rate_limit_config_update_data.rb → patch_maintenance_update_request_data.rb} +9 -21
- data/lib/datadog_api_client/v2/models/patch_maintenance_update_request_data_attributes.rb +105 -0
- data/lib/datadog_api_client/v2/models/{rum_rate_limit_scope_type.rb → patch_maintenance_update_request_data_type.rb} +3 -3
- data/lib/datadog_api_client/v2/models/patch_status_page_request_data_attributes.rb +1 -11
- data/lib/datadog_api_client/v2/models/patch_table_request_data_attributes_schema.rb +9 -1
- data/lib/datadog_api_client/v2/models/readiness_gate.rb +4 -29
- data/lib/datadog_api_client/v2/models/retry_strategy.rb +12 -26
- data/lib/datadog_api_client/v2/models/retry_strategy_linear.rb +18 -29
- data/lib/datadog_api_client/v2/models/schedule_trigger_wrapper.rb +1 -1
- data/lib/datadog_api_client/v2/models/security_trigger_wrapper.rb +1 -1
- data/lib/datadog_api_client/v2/models/self_service_trigger_wrapper.rb +1 -1
- data/lib/datadog_api_client/v2/models/slack_trigger_wrapper.rb +1 -1
- data/lib/datadog_api_client/v2/models/software_catalog_trigger_wrapper.rb +1 -1
- data/lib/datadog_api_client/v2/models/spec.rb +1 -1
- data/lib/datadog_api_client/v2/models/step.rb +11 -2
- data/lib/datadog_api_client/v2/models/step_display.rb +2 -1
- data/lib/datadog_api_client/v2/models/table_result_v2_data_attributes_schema.rb +9 -1
- data/lib/datadog_api_client/v2/models/trigger.rb +1 -0
- data/lib/datadog_api_client/v2/models/workflow_data_attributes.rb +1 -1
- data/lib/datadog_api_client/v2/models/workflow_data_update_attributes.rb +1 -1
- data/lib/datadog_api_client/v2/models/workflow_list_item_attributes.rb +1 -1
- data/lib/datadog_api_client/v2/models/workflow_trigger_wrapper.rb +2 -2
- data/lib/datadog_api_client/version.rb +1 -1
- metadata +39 -18
- data/examples/v2/rum-rate-limit/DeleteRumRateLimitConfig.rb +0 -8
- data/examples/v2/rum-rate-limit/GetRumRateLimitConfig.rb +0 -8
- data/examples/v2/rum-rate-limit/UpdateRumRateLimitConfig.rb +0 -28
- data/lib/datadog_api_client/v2/api/rum_rate_limit_api.rb +0 -277
- data/lib/datadog_api_client/v2/models/rum_rate_limit_config_attributes.rb +0 -185
- data/lib/datadog_api_client/v2/models/rum_rate_limit_custom_config.rb +0 -223
- data/lib/datadog_api_client/v2/models/rum_rate_limit_mode.rb +0 -28
- data/lib/datadog_api_client/v2/models/rum_rate_limit_window_type.rb +0 -26
data/lib/datadog_api_client/v2/models/dora_deployment_patch_by_version_remediation_by_version.rb
ADDED
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Datadog API V2 Collection
|
|
3
|
+
|
|
4
|
+
#Collection of all Datadog Public endpoints.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1.0
|
|
7
|
+
Contact: support@datadoghq.com
|
|
8
|
+
Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator
|
|
9
|
+
|
|
10
|
+
Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
|
|
11
|
+
This product includes software developed at Datadog (https://www.datadoghq.com/).
|
|
12
|
+
Copyright 2020-Present Datadog, Inc.
|
|
13
|
+
|
|
14
|
+
=end
|
|
15
|
+
|
|
16
|
+
require 'date'
|
|
17
|
+
require 'time'
|
|
18
|
+
|
|
19
|
+
module DatadogAPIClient::V2
|
|
20
|
+
# Remediation details identified by the version of the remediation deployment, matched against the same service and environment as the failed deployment.
|
|
21
|
+
class DORADeploymentPatchByVersionRemediationByVersion
|
|
22
|
+
include BaseGenericModel
|
|
23
|
+
|
|
24
|
+
# The type of remediation action taken. Required when the failed deployment must be linked to a remediation deployment.
|
|
25
|
+
attr_reader :type
|
|
26
|
+
|
|
27
|
+
# The version of the remediation deployment.
|
|
28
|
+
attr_reader :version
|
|
29
|
+
|
|
30
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
31
|
+
# @!visibility private
|
|
32
|
+
def self.attribute_map
|
|
33
|
+
{
|
|
34
|
+
:'type' => :'type',
|
|
35
|
+
:'version' => :'version'
|
|
36
|
+
}
|
|
37
|
+
end
|
|
38
|
+
|
|
39
|
+
# Attribute type mapping.
|
|
40
|
+
# @!visibility private
|
|
41
|
+
def self.openapi_types
|
|
42
|
+
{
|
|
43
|
+
:'type' => :'DORADeploymentPatchRemediationType',
|
|
44
|
+
:'version' => :'String'
|
|
45
|
+
}
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
# Initializes the object
|
|
49
|
+
# @param attributes [Hash] Model attributes in the form of hash
|
|
50
|
+
# @!visibility private
|
|
51
|
+
def initialize(attributes = {})
|
|
52
|
+
if (!attributes.is_a?(Hash))
|
|
53
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::DORADeploymentPatchByVersionRemediationByVersion` initialize method"
|
|
54
|
+
end
|
|
55
|
+
|
|
56
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
57
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
58
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
|
59
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V2::DORADeploymentPatchByVersionRemediationByVersion`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
|
60
|
+
end
|
|
61
|
+
h[k.to_sym] = v
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
if attributes.key?(:'type')
|
|
65
|
+
self.type = attributes[:'type']
|
|
66
|
+
end
|
|
67
|
+
|
|
68
|
+
if attributes.key?(:'version')
|
|
69
|
+
self.version = attributes[:'version']
|
|
70
|
+
end
|
|
71
|
+
end
|
|
72
|
+
|
|
73
|
+
# Check to see if the all the properties in the model are valid
|
|
74
|
+
# @return true if the model is valid
|
|
75
|
+
# @!visibility private
|
|
76
|
+
def valid?
|
|
77
|
+
return false if @type.nil?
|
|
78
|
+
return false if @version.nil?
|
|
79
|
+
true
|
|
80
|
+
end
|
|
81
|
+
|
|
82
|
+
# Custom attribute writer method with validation
|
|
83
|
+
# @param type [Object] Object to be assigned
|
|
84
|
+
# @!visibility private
|
|
85
|
+
def type=(type)
|
|
86
|
+
if type.nil?
|
|
87
|
+
fail ArgumentError, 'invalid value for "type", type cannot be nil.'
|
|
88
|
+
end
|
|
89
|
+
@type = type
|
|
90
|
+
end
|
|
91
|
+
|
|
92
|
+
# Custom attribute writer method with validation
|
|
93
|
+
# @param version [Object] Object to be assigned
|
|
94
|
+
# @!visibility private
|
|
95
|
+
def version=(version)
|
|
96
|
+
if version.nil?
|
|
97
|
+
fail ArgumentError, 'invalid value for "version", version cannot be nil.'
|
|
98
|
+
end
|
|
99
|
+
@version = version
|
|
100
|
+
end
|
|
101
|
+
|
|
102
|
+
# Checks equality by comparing each attribute.
|
|
103
|
+
# @param o [Object] Object to be compared
|
|
104
|
+
# @!visibility private
|
|
105
|
+
def ==(o)
|
|
106
|
+
return true if self.equal?(o)
|
|
107
|
+
self.class == o.class &&
|
|
108
|
+
type == o.type &&
|
|
109
|
+
version == o.version
|
|
110
|
+
end
|
|
111
|
+
|
|
112
|
+
# Calculates hash code according to all attributes.
|
|
113
|
+
# @return [Integer] Hash code
|
|
114
|
+
# @!visibility private
|
|
115
|
+
def hash
|
|
116
|
+
[type, version].hash
|
|
117
|
+
end
|
|
118
|
+
end
|
|
119
|
+
end
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Datadog API V2 Collection
|
|
3
|
+
|
|
4
|
+
#Collection of all Datadog Public endpoints.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1.0
|
|
7
|
+
Contact: support@datadoghq.com
|
|
8
|
+
Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator
|
|
9
|
+
|
|
10
|
+
Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
|
|
11
|
+
This product includes software developed at Datadog (https://www.datadoghq.com/).
|
|
12
|
+
Copyright 2020-Present Datadog, Inc.
|
|
13
|
+
|
|
14
|
+
=end
|
|
15
|
+
|
|
16
|
+
require 'date'
|
|
17
|
+
require 'time'
|
|
18
|
+
|
|
19
|
+
module DatadogAPIClient::V2
|
|
20
|
+
# Request to patch a DORA deployment event identified by service, environment, and version.
|
|
21
|
+
class DORADeploymentPatchByVersionRequest
|
|
22
|
+
include BaseGenericModel
|
|
23
|
+
|
|
24
|
+
# The JSON:API data for patching a deployment identified by service, environment, and version.
|
|
25
|
+
attr_reader :data
|
|
26
|
+
|
|
27
|
+
attr_accessor :additional_properties
|
|
28
|
+
|
|
29
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
30
|
+
# @!visibility private
|
|
31
|
+
def self.attribute_map
|
|
32
|
+
{
|
|
33
|
+
:'data' => :'data'
|
|
34
|
+
}
|
|
35
|
+
end
|
|
36
|
+
|
|
37
|
+
# Attribute type mapping.
|
|
38
|
+
# @!visibility private
|
|
39
|
+
def self.openapi_types
|
|
40
|
+
{
|
|
41
|
+
:'data' => :'DORADeploymentPatchByVersionRequestData'
|
|
42
|
+
}
|
|
43
|
+
end
|
|
44
|
+
|
|
45
|
+
# Initializes the object
|
|
46
|
+
# @param attributes [Hash] Model attributes in the form of hash
|
|
47
|
+
# @!visibility private
|
|
48
|
+
def initialize(attributes = {})
|
|
49
|
+
if (!attributes.is_a?(Hash))
|
|
50
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::DORADeploymentPatchByVersionRequest` initialize method"
|
|
51
|
+
end
|
|
52
|
+
|
|
53
|
+
self.additional_properties = {}
|
|
54
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
55
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
56
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
|
57
|
+
self.additional_properties[k.to_sym] = v
|
|
58
|
+
else
|
|
59
|
+
h[k.to_sym] = v
|
|
60
|
+
end
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
if attributes.key?(:'data')
|
|
64
|
+
self.data = attributes[:'data']
|
|
65
|
+
end
|
|
66
|
+
end
|
|
67
|
+
|
|
68
|
+
# Check to see if the all the properties in the model are valid
|
|
69
|
+
# @return true if the model is valid
|
|
70
|
+
# @!visibility private
|
|
71
|
+
def valid?
|
|
72
|
+
return false if @data.nil?
|
|
73
|
+
true
|
|
74
|
+
end
|
|
75
|
+
|
|
76
|
+
# Custom attribute writer method with validation
|
|
77
|
+
# @param data [Object] Object to be assigned
|
|
78
|
+
# @!visibility private
|
|
79
|
+
def data=(data)
|
|
80
|
+
if data.nil?
|
|
81
|
+
fail ArgumentError, 'invalid value for "data", data cannot be nil.'
|
|
82
|
+
end
|
|
83
|
+
@data = data
|
|
84
|
+
end
|
|
85
|
+
|
|
86
|
+
# Returns the object in the form of hash, with additionalProperties support.
|
|
87
|
+
# @return [Hash] Returns the object in the form of hash
|
|
88
|
+
# @!visibility private
|
|
89
|
+
def to_hash
|
|
90
|
+
hash = {}
|
|
91
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
92
|
+
value = self.send(attr)
|
|
93
|
+
if value.nil?
|
|
94
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
95
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
96
|
+
end
|
|
97
|
+
|
|
98
|
+
hash[param] = _to_hash(value)
|
|
99
|
+
end
|
|
100
|
+
self.additional_properties.each_pair do |attr, value|
|
|
101
|
+
hash[attr] = value
|
|
102
|
+
end
|
|
103
|
+
hash
|
|
104
|
+
end
|
|
105
|
+
|
|
106
|
+
# Checks equality by comparing each attribute.
|
|
107
|
+
# @param o [Object] Object to be compared
|
|
108
|
+
# @!visibility private
|
|
109
|
+
def ==(o)
|
|
110
|
+
return true if self.equal?(o)
|
|
111
|
+
self.class == o.class &&
|
|
112
|
+
data == o.data &&
|
|
113
|
+
additional_properties == o.additional_properties
|
|
114
|
+
end
|
|
115
|
+
|
|
116
|
+
# Calculates hash code according to all attributes.
|
|
117
|
+
# @return [Integer] Hash code
|
|
118
|
+
# @!visibility private
|
|
119
|
+
def hash
|
|
120
|
+
[data, additional_properties].hash
|
|
121
|
+
end
|
|
122
|
+
end
|
|
123
|
+
end
|
|
@@ -0,0 +1,196 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Datadog API V2 Collection
|
|
3
|
+
|
|
4
|
+
#Collection of all Datadog Public endpoints.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1.0
|
|
7
|
+
Contact: support@datadoghq.com
|
|
8
|
+
Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator
|
|
9
|
+
|
|
10
|
+
Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
|
|
11
|
+
This product includes software developed at Datadog (https://www.datadoghq.com/).
|
|
12
|
+
Copyright 2020-Present Datadog, Inc.
|
|
13
|
+
|
|
14
|
+
=end
|
|
15
|
+
|
|
16
|
+
require 'date'
|
|
17
|
+
require 'time'
|
|
18
|
+
|
|
19
|
+
module DatadogAPIClient::V2
|
|
20
|
+
# Attributes for patching a DORA deployment event identified by service, environment, and version.
|
|
21
|
+
class DORADeploymentPatchByVersionRequestAttributes
|
|
22
|
+
include BaseGenericModel
|
|
23
|
+
|
|
24
|
+
# Indicates whether the deployment resulted in a change failure.
|
|
25
|
+
attr_reader :change_failure
|
|
26
|
+
|
|
27
|
+
# The environment the deployment was performed in.
|
|
28
|
+
attr_reader :env
|
|
29
|
+
|
|
30
|
+
# Remediation details for the deployment. Optional, but required to calculate failed deployment recovery time. Specify either `id` or `version` to identify the remediation deployment, but not both.
|
|
31
|
+
attr_accessor :remediation
|
|
32
|
+
|
|
33
|
+
# The name of the service that was deployed.
|
|
34
|
+
attr_reader :service
|
|
35
|
+
|
|
36
|
+
# The version deployed. This can be seen in the Service Catalog or in the APM Deployment Tracking.
|
|
37
|
+
attr_reader :version
|
|
38
|
+
|
|
39
|
+
attr_accessor :additional_properties
|
|
40
|
+
|
|
41
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
42
|
+
# @!visibility private
|
|
43
|
+
def self.attribute_map
|
|
44
|
+
{
|
|
45
|
+
:'change_failure' => :'change_failure',
|
|
46
|
+
:'env' => :'env',
|
|
47
|
+
:'remediation' => :'remediation',
|
|
48
|
+
:'service' => :'service',
|
|
49
|
+
:'version' => :'version'
|
|
50
|
+
}
|
|
51
|
+
end
|
|
52
|
+
|
|
53
|
+
# Attribute type mapping.
|
|
54
|
+
# @!visibility private
|
|
55
|
+
def self.openapi_types
|
|
56
|
+
{
|
|
57
|
+
:'change_failure' => :'Boolean',
|
|
58
|
+
:'env' => :'String',
|
|
59
|
+
:'remediation' => :'DORADeploymentPatchByVersionRemediation',
|
|
60
|
+
:'service' => :'String',
|
|
61
|
+
:'version' => :'String'
|
|
62
|
+
}
|
|
63
|
+
end
|
|
64
|
+
|
|
65
|
+
# Initializes the object
|
|
66
|
+
# @param attributes [Hash] Model attributes in the form of hash
|
|
67
|
+
# @!visibility private
|
|
68
|
+
def initialize(attributes = {})
|
|
69
|
+
if (!attributes.is_a?(Hash))
|
|
70
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::DORADeploymentPatchByVersionRequestAttributes` initialize method"
|
|
71
|
+
end
|
|
72
|
+
|
|
73
|
+
self.additional_properties = {}
|
|
74
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
75
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
76
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
|
77
|
+
self.additional_properties[k.to_sym] = v
|
|
78
|
+
else
|
|
79
|
+
h[k.to_sym] = v
|
|
80
|
+
end
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
if attributes.key?(:'change_failure')
|
|
84
|
+
self.change_failure = attributes[:'change_failure']
|
|
85
|
+
end
|
|
86
|
+
|
|
87
|
+
if attributes.key?(:'env')
|
|
88
|
+
self.env = attributes[:'env']
|
|
89
|
+
end
|
|
90
|
+
|
|
91
|
+
if attributes.key?(:'remediation')
|
|
92
|
+
self.remediation = attributes[:'remediation']
|
|
93
|
+
end
|
|
94
|
+
|
|
95
|
+
if attributes.key?(:'service')
|
|
96
|
+
self.service = attributes[:'service']
|
|
97
|
+
end
|
|
98
|
+
|
|
99
|
+
if attributes.key?(:'version')
|
|
100
|
+
self.version = attributes[:'version']
|
|
101
|
+
end
|
|
102
|
+
end
|
|
103
|
+
|
|
104
|
+
# Check to see if the all the properties in the model are valid
|
|
105
|
+
# @return true if the model is valid
|
|
106
|
+
# @!visibility private
|
|
107
|
+
def valid?
|
|
108
|
+
return false if @change_failure.nil?
|
|
109
|
+
return false if @env.nil?
|
|
110
|
+
return false if @service.nil?
|
|
111
|
+
return false if @version.nil?
|
|
112
|
+
true
|
|
113
|
+
end
|
|
114
|
+
|
|
115
|
+
# Custom attribute writer method with validation
|
|
116
|
+
# @param change_failure [Object] Object to be assigned
|
|
117
|
+
# @!visibility private
|
|
118
|
+
def change_failure=(change_failure)
|
|
119
|
+
if change_failure.nil?
|
|
120
|
+
fail ArgumentError, 'invalid value for "change_failure", change_failure cannot be nil.'
|
|
121
|
+
end
|
|
122
|
+
@change_failure = change_failure
|
|
123
|
+
end
|
|
124
|
+
|
|
125
|
+
# Custom attribute writer method with validation
|
|
126
|
+
# @param env [Object] Object to be assigned
|
|
127
|
+
# @!visibility private
|
|
128
|
+
def env=(env)
|
|
129
|
+
if env.nil?
|
|
130
|
+
fail ArgumentError, 'invalid value for "env", env cannot be nil.'
|
|
131
|
+
end
|
|
132
|
+
@env = env
|
|
133
|
+
end
|
|
134
|
+
|
|
135
|
+
# Custom attribute writer method with validation
|
|
136
|
+
# @param service [Object] Object to be assigned
|
|
137
|
+
# @!visibility private
|
|
138
|
+
def service=(service)
|
|
139
|
+
if service.nil?
|
|
140
|
+
fail ArgumentError, 'invalid value for "service", service cannot be nil.'
|
|
141
|
+
end
|
|
142
|
+
@service = service
|
|
143
|
+
end
|
|
144
|
+
|
|
145
|
+
# Custom attribute writer method with validation
|
|
146
|
+
# @param version [Object] Object to be assigned
|
|
147
|
+
# @!visibility private
|
|
148
|
+
def version=(version)
|
|
149
|
+
if version.nil?
|
|
150
|
+
fail ArgumentError, 'invalid value for "version", version cannot be nil.'
|
|
151
|
+
end
|
|
152
|
+
@version = version
|
|
153
|
+
end
|
|
154
|
+
|
|
155
|
+
# Returns the object in the form of hash, with additionalProperties support.
|
|
156
|
+
# @return [Hash] Returns the object in the form of hash
|
|
157
|
+
# @!visibility private
|
|
158
|
+
def to_hash
|
|
159
|
+
hash = {}
|
|
160
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
161
|
+
value = self.send(attr)
|
|
162
|
+
if value.nil?
|
|
163
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
164
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
165
|
+
end
|
|
166
|
+
|
|
167
|
+
hash[param] = _to_hash(value)
|
|
168
|
+
end
|
|
169
|
+
self.additional_properties.each_pair do |attr, value|
|
|
170
|
+
hash[attr] = value
|
|
171
|
+
end
|
|
172
|
+
hash
|
|
173
|
+
end
|
|
174
|
+
|
|
175
|
+
# Checks equality by comparing each attribute.
|
|
176
|
+
# @param o [Object] Object to be compared
|
|
177
|
+
# @!visibility private
|
|
178
|
+
def ==(o)
|
|
179
|
+
return true if self.equal?(o)
|
|
180
|
+
self.class == o.class &&
|
|
181
|
+
change_failure == o.change_failure &&
|
|
182
|
+
env == o.env &&
|
|
183
|
+
remediation == o.remediation &&
|
|
184
|
+
service == o.service &&
|
|
185
|
+
version == o.version &&
|
|
186
|
+
additional_properties == o.additional_properties
|
|
187
|
+
end
|
|
188
|
+
|
|
189
|
+
# Calculates hash code according to all attributes.
|
|
190
|
+
# @return [Integer] Hash code
|
|
191
|
+
# @!visibility private
|
|
192
|
+
def hash
|
|
193
|
+
[change_failure, env, remediation, service, version, additional_properties].hash
|
|
194
|
+
end
|
|
195
|
+
end
|
|
196
|
+
end
|
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Datadog API V2 Collection
|
|
3
|
+
|
|
4
|
+
#Collection of all Datadog Public endpoints.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1.0
|
|
7
|
+
Contact: support@datadoghq.com
|
|
8
|
+
Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator
|
|
9
|
+
|
|
10
|
+
Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
|
|
11
|
+
This product includes software developed at Datadog (https://www.datadoghq.com/).
|
|
12
|
+
Copyright 2020-Present Datadog, Inc.
|
|
13
|
+
|
|
14
|
+
=end
|
|
15
|
+
|
|
16
|
+
require 'date'
|
|
17
|
+
require 'time'
|
|
18
|
+
|
|
19
|
+
module DatadogAPIClient::V2
|
|
20
|
+
# The JSON:API data for patching a deployment identified by service, environment, and version.
|
|
21
|
+
class DORADeploymentPatchByVersionRequestData
|
|
22
|
+
include BaseGenericModel
|
|
23
|
+
|
|
24
|
+
# Attributes for patching a DORA deployment event identified by service, environment, and version.
|
|
25
|
+
attr_reader :attributes
|
|
26
|
+
|
|
27
|
+
# JSON:API type for DORA deployment patch request.
|
|
28
|
+
attr_reader :type
|
|
29
|
+
|
|
30
|
+
attr_accessor :additional_properties
|
|
31
|
+
|
|
32
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
33
|
+
# @!visibility private
|
|
34
|
+
def self.attribute_map
|
|
35
|
+
{
|
|
36
|
+
:'attributes' => :'attributes',
|
|
37
|
+
:'type' => :'type'
|
|
38
|
+
}
|
|
39
|
+
end
|
|
40
|
+
|
|
41
|
+
# Attribute type mapping.
|
|
42
|
+
# @!visibility private
|
|
43
|
+
def self.openapi_types
|
|
44
|
+
{
|
|
45
|
+
:'attributes' => :'DORADeploymentPatchByVersionRequestAttributes',
|
|
46
|
+
:'type' => :'DORADeploymentPatchRequestDataType'
|
|
47
|
+
}
|
|
48
|
+
end
|
|
49
|
+
|
|
50
|
+
# Initializes the object
|
|
51
|
+
# @param attributes [Hash] Model attributes in the form of hash
|
|
52
|
+
# @!visibility private
|
|
53
|
+
def initialize(attributes = {})
|
|
54
|
+
if (!attributes.is_a?(Hash))
|
|
55
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::DORADeploymentPatchByVersionRequestData` initialize method"
|
|
56
|
+
end
|
|
57
|
+
|
|
58
|
+
self.additional_properties = {}
|
|
59
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
60
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
61
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
|
62
|
+
self.additional_properties[k.to_sym] = v
|
|
63
|
+
else
|
|
64
|
+
h[k.to_sym] = v
|
|
65
|
+
end
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
if attributes.key?(:'attributes')
|
|
69
|
+
self.attributes = attributes[:'attributes']
|
|
70
|
+
end
|
|
71
|
+
|
|
72
|
+
if attributes.key?(:'type')
|
|
73
|
+
self.type = attributes[:'type']
|
|
74
|
+
end
|
|
75
|
+
end
|
|
76
|
+
|
|
77
|
+
# Check to see if the all the properties in the model are valid
|
|
78
|
+
# @return true if the model is valid
|
|
79
|
+
# @!visibility private
|
|
80
|
+
def valid?
|
|
81
|
+
return false if @attributes.nil?
|
|
82
|
+
return false if @type.nil?
|
|
83
|
+
true
|
|
84
|
+
end
|
|
85
|
+
|
|
86
|
+
# Custom attribute writer method with validation
|
|
87
|
+
# @param attributes [Object] Object to be assigned
|
|
88
|
+
# @!visibility private
|
|
89
|
+
def attributes=(attributes)
|
|
90
|
+
if attributes.nil?
|
|
91
|
+
fail ArgumentError, 'invalid value for "attributes", attributes cannot be nil.'
|
|
92
|
+
end
|
|
93
|
+
@attributes = attributes
|
|
94
|
+
end
|
|
95
|
+
|
|
96
|
+
# Custom attribute writer method with validation
|
|
97
|
+
# @param type [Object] Object to be assigned
|
|
98
|
+
# @!visibility private
|
|
99
|
+
def type=(type)
|
|
100
|
+
if type.nil?
|
|
101
|
+
fail ArgumentError, 'invalid value for "type", type cannot be nil.'
|
|
102
|
+
end
|
|
103
|
+
@type = type
|
|
104
|
+
end
|
|
105
|
+
|
|
106
|
+
# Returns the object in the form of hash, with additionalProperties support.
|
|
107
|
+
# @return [Hash] Returns the object in the form of hash
|
|
108
|
+
# @!visibility private
|
|
109
|
+
def to_hash
|
|
110
|
+
hash = {}
|
|
111
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
112
|
+
value = self.send(attr)
|
|
113
|
+
if value.nil?
|
|
114
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
115
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
116
|
+
end
|
|
117
|
+
|
|
118
|
+
hash[param] = _to_hash(value)
|
|
119
|
+
end
|
|
120
|
+
self.additional_properties.each_pair do |attr, value|
|
|
121
|
+
hash[attr] = value
|
|
122
|
+
end
|
|
123
|
+
hash
|
|
124
|
+
end
|
|
125
|
+
|
|
126
|
+
# Checks equality by comparing each attribute.
|
|
127
|
+
# @param o [Object] Object to be compared
|
|
128
|
+
# @!visibility private
|
|
129
|
+
def ==(o)
|
|
130
|
+
return true if self.equal?(o)
|
|
131
|
+
self.class == o.class &&
|
|
132
|
+
attributes == o.attributes &&
|
|
133
|
+
type == o.type &&
|
|
134
|
+
additional_properties == o.additional_properties
|
|
135
|
+
end
|
|
136
|
+
|
|
137
|
+
# Calculates hash code according to all attributes.
|
|
138
|
+
# @return [Integer] Hash code
|
|
139
|
+
# @!visibility private
|
|
140
|
+
def hash
|
|
141
|
+
[attributes, type, additional_properties].hash
|
|
142
|
+
end
|
|
143
|
+
end
|
|
144
|
+
end
|
|
@@ -17,16 +17,19 @@ require 'date'
|
|
|
17
17
|
require 'time'
|
|
18
18
|
|
|
19
19
|
module DatadogAPIClient::V2
|
|
20
|
-
# Remediation details for the deployment. Optional, but required to calculate failed deployment recovery time.
|
|
20
|
+
# Remediation details for the deployment. Optional, but required to calculate failed deployment recovery time. Specify either `id` or `version` to identify the remediation deployment, but not both.
|
|
21
21
|
class DORADeploymentPatchRemediation
|
|
22
22
|
include BaseGenericModel
|
|
23
23
|
|
|
24
|
-
# The ID of the remediation deployment.
|
|
24
|
+
# The ID of the remediation deployment. Use this or `version` to identify the remediation deployment, but not both.
|
|
25
25
|
attr_accessor :id
|
|
26
26
|
|
|
27
27
|
# The type of remediation action taken. Required when the failed deployment must be linked to a remediation deployment.
|
|
28
28
|
attr_accessor :type
|
|
29
29
|
|
|
30
|
+
# The version of the remediation deployment, matched against the same service and environment as the failed deployment. Use this or `id` to identify the remediation deployment, but not both.
|
|
31
|
+
attr_accessor :version
|
|
32
|
+
|
|
30
33
|
attr_accessor :additional_properties
|
|
31
34
|
|
|
32
35
|
# Attribute mapping from ruby-style variable name to JSON key.
|
|
@@ -34,7 +37,8 @@ module DatadogAPIClient::V2
|
|
|
34
37
|
def self.attribute_map
|
|
35
38
|
{
|
|
36
39
|
:'id' => :'id',
|
|
37
|
-
:'type' => :'type'
|
|
40
|
+
:'type' => :'type',
|
|
41
|
+
:'version' => :'version'
|
|
38
42
|
}
|
|
39
43
|
end
|
|
40
44
|
|
|
@@ -43,7 +47,8 @@ module DatadogAPIClient::V2
|
|
|
43
47
|
def self.openapi_types
|
|
44
48
|
{
|
|
45
49
|
:'id' => :'String',
|
|
46
|
-
:'type' => :'DORADeploymentPatchRemediationType'
|
|
50
|
+
:'type' => :'DORADeploymentPatchRemediationType',
|
|
51
|
+
:'version' => :'String'
|
|
47
52
|
}
|
|
48
53
|
end
|
|
49
54
|
|
|
@@ -72,6 +77,10 @@ module DatadogAPIClient::V2
|
|
|
72
77
|
if attributes.key?(:'type')
|
|
73
78
|
self.type = attributes[:'type']
|
|
74
79
|
end
|
|
80
|
+
|
|
81
|
+
if attributes.key?(:'version')
|
|
82
|
+
self.version = attributes[:'version']
|
|
83
|
+
end
|
|
75
84
|
end
|
|
76
85
|
|
|
77
86
|
# Returns the object in the form of hash, with additionalProperties support.
|
|
@@ -102,6 +111,7 @@ module DatadogAPIClient::V2
|
|
|
102
111
|
self.class == o.class &&
|
|
103
112
|
id == o.id &&
|
|
104
113
|
type == o.type &&
|
|
114
|
+
version == o.version &&
|
|
105
115
|
additional_properties == o.additional_properties
|
|
106
116
|
end
|
|
107
117
|
|
|
@@ -109,7 +119,7 @@ module DatadogAPIClient::V2
|
|
|
109
119
|
# @return [Integer] Hash code
|
|
110
120
|
# @!visibility private
|
|
111
121
|
def hash
|
|
112
|
-
[id, type, additional_properties].hash
|
|
122
|
+
[id, type, version, additional_properties].hash
|
|
113
123
|
end
|
|
114
124
|
end
|
|
115
125
|
end
|
|
@@ -24,7 +24,7 @@ module DatadogAPIClient::V2
|
|
|
24
24
|
# Indicates whether the deployment resulted in a change failure.
|
|
25
25
|
attr_accessor :change_failure
|
|
26
26
|
|
|
27
|
-
# Remediation details for the deployment. Optional, but required to calculate failed deployment recovery time.
|
|
27
|
+
# Remediation details for the deployment. Optional, but required to calculate failed deployment recovery time. Specify either `id` or `version` to identify the remediation deployment, but not both.
|
|
28
28
|
attr_accessor :remediation
|
|
29
29
|
|
|
30
30
|
attr_accessor :additional_properties
|