Class: OCI::Mysql::Models::HeatWaveClusterMemoryEstimate
- Inherits:
-
Object
- Object
- OCI::Mysql::Models::HeatWaveClusterMemoryEstimate
- Defined in:
- lib/oci/mysql/models/heat_wave_cluster_memory_estimate.rb
Overview
HeatWave cluster memory estimate that can be used to determine a suitable HeatWave cluster size. For each MySQL user table the estimated memory footprint when the table is loaded to the HeatWave cluster memory is returned.
Constant Summary collapse
- STATUS_ENUM =
[ STATUS_ACCEPTED = 'ACCEPTED'.freeze, STATUS_IN_PROGRESS = 'IN_PROGRESS'.freeze, STATUS_FAILED = 'FAILED'.freeze, STATUS_SUCCEEDED = 'SUCCEEDED'.freeze, STATUS_CANCELING = 'CANCELING'.freeze, STATUS_CANCELED = 'CANCELED'.freeze, STATUS_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
Instance Attribute Summary collapse
-
#db_system_id ⇒ String
[Required] The OCID of the DB System the HeatWave cluster memory estimate is associated with.
-
#status ⇒ String
[Required] Current status of the Work Request generating the HeatWave cluster memory estimate.
-
#table_schemas ⇒ Array<OCI::Mysql::Models::HeatWaveClusterSchemaMemoryEstimate>
[Required] Collection of schemas with estimated memory footprints for MySQL user tables of each schema when loaded to HeatWave cluster memory.
-
#time_created ⇒ DateTime
[Required] The date and time that the Work Request to generate the HeatWave cluster memory estimate was issued, as described by [RFC 3339](tools.ietf.org/rfc/rfc333).
-
#time_updated ⇒ DateTime
[Required] The date and time that the HeatWave cluster memory estimate was generated, as described by [RFC 3339](tools.ietf.org/rfc/rfc333).
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 = {}) ⇒ HeatWaveClusterMemoryEstimate
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 = {}) ⇒ HeatWaveClusterMemoryEstimate
Initializes the object
84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 |
# File 'lib/oci/mysql/models/heat_wave_cluster_memory_estimate.rb', line 84 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.db_system_id = attributes[:'dbSystemId'] if attributes[:'dbSystemId'] raise 'You cannot provide both :dbSystemId and :db_system_id' if attributes.key?(:'dbSystemId') && attributes.key?(:'db_system_id') self.db_system_id = attributes[:'db_system_id'] if attributes[:'db_system_id'] self.status = attributes[:'status'] if attributes[:'status'] self.time_created = attributes[:'timeCreated'] if attributes[:'timeCreated'] raise 'You cannot provide both :timeCreated and :time_created' if attributes.key?(:'timeCreated') && attributes.key?(:'time_created') self.time_created = attributes[:'time_created'] if attributes[:'time_created'] self.time_updated = attributes[:'timeUpdated'] if attributes[:'timeUpdated'] raise 'You cannot provide both :timeUpdated and :time_updated' if attributes.key?(:'timeUpdated') && attributes.key?(:'time_updated') self.time_updated = attributes[:'time_updated'] if attributes[:'time_updated'] self.table_schemas = attributes[:'tableSchemas'] if attributes[:'tableSchemas'] raise 'You cannot provide both :tableSchemas and :table_schemas' if attributes.key?(:'tableSchemas') && attributes.key?(:'table_schemas') self.table_schemas = attributes[:'table_schemas'] if attributes[:'table_schemas'] end |
Instance Attribute Details
#db_system_id ⇒ String
[Required] The OCID of the DB System the HeatWave cluster memory estimate is associated with.
27 28 29 |
# File 'lib/oci/mysql/models/heat_wave_cluster_memory_estimate.rb', line 27 def db_system_id @db_system_id end |
#status ⇒ String
[Required] Current status of the Work Request generating the HeatWave cluster memory estimate.
31 32 33 |
# File 'lib/oci/mysql/models/heat_wave_cluster_memory_estimate.rb', line 31 def status @status end |
#table_schemas ⇒ Array<OCI::Mysql::Models::HeatWaveClusterSchemaMemoryEstimate>
[Required] Collection of schemas with estimated memory footprints for MySQL user tables of each schema when loaded to HeatWave cluster memory.
45 46 47 |
# File 'lib/oci/mysql/models/heat_wave_cluster_memory_estimate.rb', line 45 def table_schemas @table_schemas end |
#time_created ⇒ DateTime
[Required] The date and time that the Work Request to generate the HeatWave cluster memory estimate was issued, as described by [RFC 3339](tools.ietf.org/rfc/rfc333).
35 36 37 |
# File 'lib/oci/mysql/models/heat_wave_cluster_memory_estimate.rb', line 35 def time_created @time_created end |
#time_updated ⇒ DateTime
[Required] The date and time that the HeatWave cluster memory estimate was generated, as described by [RFC 3339](tools.ietf.org/rfc/rfc333).
39 40 41 |
# File 'lib/oci/mysql/models/heat_wave_cluster_memory_estimate.rb', line 39 def time_updated @time_updated end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
48 49 50 51 52 53 54 55 56 57 58 |
# File 'lib/oci/mysql/models/heat_wave_cluster_memory_estimate.rb', line 48 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'db_system_id': :'dbSystemId', 'status': :'status', 'time_created': :'timeCreated', 'time_updated': :'timeUpdated', 'table_schemas': :'tableSchemas' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
61 62 63 64 65 66 67 68 69 70 71 |
# File 'lib/oci/mysql/models/heat_wave_cluster_memory_estimate.rb', line 61 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'db_system_id': :'String', 'status': :'String', 'time_created': :'DateTime', 'time_updated': :'DateTime', 'table_schemas': :'Array<OCI::Mysql::Models::HeatWaveClusterSchemaMemoryEstimate>' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
137 138 139 140 141 142 143 144 145 146 |
# File 'lib/oci/mysql/models/heat_wave_cluster_memory_estimate.rb', line 137 def ==(other) return true if equal?(other) self.class == other.class && db_system_id == other.db_system_id && status == other.status && time_created == other.time_created && time_updated == other.time_updated && table_schemas == other.table_schemas end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 |
# File 'lib/oci/mysql/models/heat_wave_cluster_memory_estimate.rb', line 171 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
151 152 153 |
# File 'lib/oci/mysql/models/heat_wave_cluster_memory_estimate.rb', line 151 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
160 161 162 |
# File 'lib/oci/mysql/models/heat_wave_cluster_memory_estimate.rb', line 160 def hash [db_system_id, status, time_created, time_updated, table_schemas].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
204 205 206 207 208 209 210 211 212 213 |
# File 'lib/oci/mysql/models/heat_wave_cluster_memory_estimate.rb', line 204 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
198 199 200 |
# File 'lib/oci/mysql/models/heat_wave_cluster_memory_estimate.rb', line 198 def to_s to_hash.to_s end |