Class: OCI::ApmTraces::Models::BulkActivationMetadata
- Inherits:
-
Object
- Object
- OCI::ApmTraces::Models::BulkActivationMetadata
- Defined in:
- lib/oci/apm_traces/models/bulk_activation_metadata.rb
Overview
Metadata about the bulk activation operation. The bulk activation operation is atomic and binary. If the processing of any of the attributes in the bulk activation request results in a processing or validation error, then none of the attributes in the request are activated. The bulk activation request succeeds only when all the attributes in the bulk activation request are processed and they get a successful attributeStatus back.
Constant Summary collapse
- OPERATION_STATUS_ENUM =
[ OPERATION_STATUS_SUCCESS = 'SUCCESS'.freeze, OPERATION_STATUS_EMPTY_ATTRIBUTE_LIST = 'EMPTY_ATTRIBUTE_LIST'.freeze, OPERATION_STATUS_NUMERIC_ATTRIBUTE_LIMIT_EXCEEDED = 'NUMERIC_ATTRIBUTE_LIMIT_EXCEEDED'.freeze, OPERATION_STATUS_STRING_ATTRIBUTE_LIMIT_EXCEEDED = 'STRING_ATTRIBUTE_LIMIT_EXCEEDED'.freeze, OPERATION_STATUS_INSUFFICIENT_STRING_SPACE = 'INSUFFICIENT_STRING_SPACE'.freeze, OPERATION_STATUS_INSUFFICIENT_NUMERIC_SPACE = 'INSUFFICIENT_NUMERIC_SPACE'.freeze, OPERATION_STATUS_INVALID_BULK_REQUEST = 'INVALID_BULK_REQUEST'.freeze, OPERATION_STATUS_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
- OPERATION_TYPE_ENUM =
[ OPERATION_TYPE_ACTIVATE = 'ACTIVATE'.freeze, OPERATION_TYPE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
Instance Attribute Summary collapse
-
#available_numeric_attributes ⇒ Integer
Total number of free slots available to activate numeric attributes in the TRACES namespace in the APM Domain.
-
#available_string_attributes ⇒ Integer
Total number of free slots available to activate string attributes in the TRACES namespace in the APM Domain.
-
#available_synthetic_numeric_attributes ⇒ Integer
Total number of free slots available to activate numeric attributes in the SYNTHETIC namespace in the APM Domain.
-
#available_synthetic_string_attributes ⇒ Integer
Total number of free slots available to activate string attributes in the SYNTHETIC namespace in the APM Domain.
-
#numeric_attributes_activated ⇒ Integer
Total number of numeric attributes in TRACES namespace that were activated.
-
#operation_status ⇒ String
[Required] Operation status of the bulk activation operation.
-
#operation_type ⇒ String
[Required] Type of operation.
-
#string_attributes_activated ⇒ Integer
Total number of string attributes in TRACES namespace that were activated.
-
#synthetic_numeric_attributes_activated ⇒ Integer
Total number of numeric attributes in SYNTHETIC namespace that were activated.
-
#synthetic_string_attributes_activated ⇒ Integer
Total number of string attributes in SYNTHETIC namespace that were activated.
Class Method Summary collapse
-
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
-
.swagger_types ⇒ Object
Attribute type mapping.
Instance Method Summary collapse
-
#==(other) ⇒ Object
Checks equality by comparing each attribute.
-
#build_from_hash(attributes) ⇒ Object
Builds the object from hash.
- #eql?(other) ⇒ Boolean
-
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
-
#initialize(attributes = {}) ⇒ BulkActivationMetadata
constructor
Initializes the object.
-
#to_hash ⇒ Hash
Returns the object in the form of hash.
-
#to_s ⇒ String
Returns the string representation of the object.
Constructor Details
#initialize(attributes = {}) ⇒ BulkActivationMetadata
Initializes the object
148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 148 def initialize(attributes = {}) return unless attributes.is_a?(Hash) # convert string to symbol for hash key attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v } self.operation_status = attributes[:'operationStatus'] if attributes[:'operationStatus'] raise 'You cannot provide both :operationStatus and :operation_status' if attributes.key?(:'operationStatus') && attributes.key?(:'operation_status') self.operation_status = attributes[:'operation_status'] if attributes[:'operation_status'] self.operation_type = attributes[:'operationType'] if attributes[:'operationType'] raise 'You cannot provide both :operationType and :operation_type' if attributes.key?(:'operationType') && attributes.key?(:'operation_type') self.operation_type = attributes[:'operation_type'] if attributes[:'operation_type'] self.string_attributes_activated = attributes[:'stringAttributesActivated'] if attributes[:'stringAttributesActivated'] raise 'You cannot provide both :stringAttributesActivated and :string_attributes_activated' if attributes.key?(:'stringAttributesActivated') && attributes.key?(:'string_attributes_activated') self.string_attributes_activated = attributes[:'string_attributes_activated'] if attributes[:'string_attributes_activated'] self.numeric_attributes_activated = attributes[:'numericAttributesActivated'] if attributes[:'numericAttributesActivated'] raise 'You cannot provide both :numericAttributesActivated and :numeric_attributes_activated' if attributes.key?(:'numericAttributesActivated') && attributes.key?(:'numeric_attributes_activated') self.numeric_attributes_activated = attributes[:'numeric_attributes_activated'] if attributes[:'numeric_attributes_activated'] self.synthetic_string_attributes_activated = attributes[:'syntheticStringAttributesActivated'] if attributes[:'syntheticStringAttributesActivated'] raise 'You cannot provide both :syntheticStringAttributesActivated and :synthetic_string_attributes_activated' if attributes.key?(:'syntheticStringAttributesActivated') && attributes.key?(:'synthetic_string_attributes_activated') self.synthetic_string_attributes_activated = attributes[:'synthetic_string_attributes_activated'] if attributes[:'synthetic_string_attributes_activated'] self.synthetic_numeric_attributes_activated = attributes[:'syntheticNumericAttributesActivated'] if attributes[:'syntheticNumericAttributesActivated'] raise 'You cannot provide both :syntheticNumericAttributesActivated and :synthetic_numeric_attributes_activated' if attributes.key?(:'syntheticNumericAttributesActivated') && attributes.key?(:'synthetic_numeric_attributes_activated') self.synthetic_numeric_attributes_activated = attributes[:'synthetic_numeric_attributes_activated'] if attributes[:'synthetic_numeric_attributes_activated'] self.available_string_attributes = attributes[:'availableStringAttributes'] if attributes[:'availableStringAttributes'] raise 'You cannot provide both :availableStringAttributes and :available_string_attributes' if attributes.key?(:'availableStringAttributes') && attributes.key?(:'available_string_attributes') self.available_string_attributes = attributes[:'available_string_attributes'] if attributes[:'available_string_attributes'] self.available_numeric_attributes = attributes[:'availableNumericAttributes'] if attributes[:'availableNumericAttributes'] raise 'You cannot provide both :availableNumericAttributes and :available_numeric_attributes' if attributes.key?(:'availableNumericAttributes') && attributes.key?(:'available_numeric_attributes') self.available_numeric_attributes = attributes[:'available_numeric_attributes'] if attributes[:'available_numeric_attributes'] self.available_synthetic_string_attributes = attributes[:'availableSyntheticStringAttributes'] if attributes[:'availableSyntheticStringAttributes'] raise 'You cannot provide both :availableSyntheticStringAttributes and :available_synthetic_string_attributes' if attributes.key?(:'availableSyntheticStringAttributes') && attributes.key?(:'available_synthetic_string_attributes') self.available_synthetic_string_attributes = attributes[:'available_synthetic_string_attributes'] if attributes[:'available_synthetic_string_attributes'] self.available_synthetic_numeric_attributes = attributes[:'availableSyntheticNumericAttributes'] if attributes[:'availableSyntheticNumericAttributes'] raise 'You cannot provide both :availableSyntheticNumericAttributes and :available_synthetic_numeric_attributes' if attributes.key?(:'availableSyntheticNumericAttributes') && attributes.key?(:'available_synthetic_numeric_attributes') self.available_synthetic_numeric_attributes = attributes[:'available_synthetic_numeric_attributes'] if attributes[:'available_synthetic_numeric_attributes'] end |
Instance Attribute Details
#available_numeric_attributes ⇒ Integer
Total number of free slots available to activate numeric attributes in the TRACES namespace in the APM Domain. Note that if a bulk request has succeeded, this number reflects the total number of free slots available for activation of additional numeric attributes in the TRACES namespace in the APM Domain.
82 83 84 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 82 def available_numeric_attributes @available_numeric_attributes end |
#available_string_attributes ⇒ Integer
Total number of free slots available to activate string attributes in the TRACES namespace in the APM Domain. Note that if a bulk request has succeeded, this number reflects the total number of free slots available for activation of additional string attributes in the TRACES namespace in the APM Domain.
76 77 78 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 76 def available_string_attributes @available_string_attributes end |
#available_synthetic_numeric_attributes ⇒ Integer
Total number of free slots available to activate numeric attributes in the SYNTHETIC namespace in the APM Domain. Note that if a bulk request has succeeded, this number reflects the total number of free synthetic slots available for activation of additional numeric attributes in the SYNTHETIC namespace in the APM Domain.
94 95 96 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 94 def available_synthetic_numeric_attributes @available_synthetic_numeric_attributes end |
#available_synthetic_string_attributes ⇒ Integer
Total number of free slots available to activate string attributes in the SYNTHETIC namespace in the APM Domain. Note that if a bulk request has succeeded, this number reflects the total number of free synthetic slots available for activation of additional string attributes in the SYNTHETIC namespace in the APM Domain.
88 89 90 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 88 def available_synthetic_string_attributes @available_synthetic_string_attributes end |
#numeric_attributes_activated ⇒ Integer
Total number of numeric attributes in TRACES namespace that were activated.
60 61 62 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 60 def numeric_attributes_activated @numeric_attributes_activated end |
#operation_status ⇒ String
[Required] Operation status of the bulk activation operation. The bulk activation operation could have either a success or an error status as defined below. The following is a success status for the bulk activation operation. SUCCESS - The bulk activation operation has succeeded and all the attributes in the bulk activation request have been activated by this operation or activated earlier. The following are error statuses for the bulk activation operation. Note that none of the attributes (string or numeric) in the bulk request have been activated by this bulk activation operation if any of the below statuses. EMPTY_ATTRIBUTE_LIST - The bulk activation request object was empty and did not contain any attributes to be activated. NUMERIC_ATTRIBUTE_LIMIT_EXCEEDED - The number of numeric attributes in the bulk request exceeded the maximum limit (100) of numeric attributes that could be activated in the APM Domain. STRING_ATTRIBUTE_LIMIT_EXCEEDED - The number of string attributes in the bulk request exceeded the maximum limit (700) of string attributes that could be activated in the APM Domain. INSUFFICIENT_STRING_SPACE - There are not enough free slots available in the APM Domain to activate the string attributes present in the bulk request. INSUFFICIENT_NUMERIC_SPACE - There are not enough free slots available in the APM Domain to activate the numeric attributes present in the bulk request. INVALID_BULK_REQUEST - The bulk request contains invalid attribute(s), or attribute(s) that resulted in a validation error, or an attribute that resulted in a processing error.
45 46 47 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 45 def operation_status @operation_status end |
#operation_type ⇒ String
[Required] Type of operation.
50 51 52 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 50 def operation_type @operation_type end |
#string_attributes_activated ⇒ Integer
Total number of string attributes in TRACES namespace that were activated.
55 56 57 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 55 def string_attributes_activated @string_attributes_activated end |
#synthetic_numeric_attributes_activated ⇒ Integer
Total number of numeric attributes in SYNTHETIC namespace that were activated.
70 71 72 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 70 def synthetic_numeric_attributes_activated @synthetic_numeric_attributes_activated end |
#synthetic_string_attributes_activated ⇒ Integer
Total number of string attributes in SYNTHETIC namespace that were activated.
65 66 67 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 65 def synthetic_string_attributes_activated @synthetic_string_attributes_activated end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 97 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'operation_status': :'operationStatus', 'operation_type': :'operationType', 'string_attributes_activated': :'stringAttributesActivated', 'numeric_attributes_activated': :'numericAttributesActivated', 'synthetic_string_attributes_activated': :'syntheticStringAttributesActivated', 'synthetic_numeric_attributes_activated': :'syntheticNumericAttributesActivated', 'available_string_attributes': :'availableStringAttributes', 'available_numeric_attributes': :'availableNumericAttributes', 'available_synthetic_string_attributes': :'availableSyntheticStringAttributes', 'available_synthetic_numeric_attributes': :'availableSyntheticNumericAttributes' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 115 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'operation_status': :'String', 'operation_type': :'String', 'string_attributes_activated': :'Integer', 'numeric_attributes_activated': :'Integer', 'synthetic_string_attributes_activated': :'Integer', 'synthetic_numeric_attributes_activated': :'Integer', 'available_string_attributes': :'Integer', 'available_numeric_attributes': :'Integer', 'available_synthetic_string_attributes': :'Integer', 'available_synthetic_numeric_attributes': :'Integer' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 248 def ==(other) return true if equal?(other) self.class == other.class && operation_status == other.operation_status && operation_type == other.operation_type && string_attributes_activated == other.string_attributes_activated && numeric_attributes_activated == other.numeric_attributes_activated && synthetic_string_attributes_activated == other.synthetic_string_attributes_activated && synthetic_numeric_attributes_activated == other.synthetic_numeric_attributes_activated && available_string_attributes == other.available_string_attributes && available_numeric_attributes == other.available_numeric_attributes && available_synthetic_string_attributes == other.available_synthetic_string_attributes && available_synthetic_numeric_attributes == other.available_synthetic_numeric_attributes end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 287 def build_from_hash(attributes) return nil unless attributes.is_a?(Hash) self.class.swagger_types.each_pair do |key, type| if type =~ /^Array<(.*)>/i # check to ensure the input is an array given that the the attribute # is documented as an array but the input is not if attributes[self.class.attribute_map[key]].is_a?(Array) public_method("#{key}=").call( attributes[self.class.attribute_map[key]] .map { |v| OCI::Internal::Util.convert_to_type(Regexp.last_match(1), v) } ) end elsif !attributes[self.class.attribute_map[key]].nil? public_method("#{key}=").call( OCI::Internal::Util.convert_to_type(type, attributes[self.class.attribute_map[key]]) ) end # or else data not found in attributes(hash), not an issue as the data can be optional end self end |
#eql?(other) ⇒ Boolean
267 268 269 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 267 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
276 277 278 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 276 def hash [operation_status, operation_type, string_attributes_activated, numeric_attributes_activated, synthetic_string_attributes_activated, synthetic_numeric_attributes_activated, available_string_attributes, available_numeric_attributes, available_synthetic_string_attributes, available_synthetic_numeric_attributes].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
320 321 322 323 324 325 326 327 328 329 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 320 def to_hash hash = {} self.class.attribute_map.each_pair do |attr, param| value = public_method(attr).call next if value.nil? && !instance_variable_defined?("@#{attr}") hash[param] = _to_hash(value) end hash end |
#to_s ⇒ String
Returns the string representation of the object
314 315 316 |
# File 'lib/oci/apm_traces/models/bulk_activation_metadata.rb', line 314 def to_s to_hash.to_s end |