Class: OCI::Database::Models::DatabaseUpgradeHistoryEntrySummary
- Inherits:
-
Object
- Object
- OCI::Database::Models::DatabaseUpgradeHistoryEntrySummary
- Defined in:
- lib/oci/database/models/database_upgrade_history_entry_summary.rb
Overview
The Database service supports the upgrade history of databases.
To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, talk to an administrator. If you are an administrator who needs to write policies to give users access, see [Getting Started with Policies](docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm).
For information about access control and compartments, see [Overview of the Identity Service](docs.cloud.oracle.com/Content/Identity/Concepts/overview.htm).
Warning: Oracle recommends that you avoid using any confidential information when you supply string values using the API.
Constant Summary collapse
- ACTION_ENUM =
[ ACTION_PRECHECK = 'PRECHECK'.freeze, ACTION_UPGRADE = 'UPGRADE'.freeze, ACTION_ROLLBACK = 'ROLLBACK'.freeze, ACTION_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
- SOURCE_ENUM =
[ SOURCE_DB_HOME = 'DB_HOME'.freeze, SOURCE_DB_VERSION = 'DB_VERSION'.freeze, SOURCE_DB_SOFTWARE_IMAGE = 'DB_SOFTWARE_IMAGE'.freeze, SOURCE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
- LIFECYCLE_STATE_ENUM =
[ LIFECYCLE_STATE_SUCCEEDED = 'SUCCEEDED'.freeze, LIFECYCLE_STATE_FAILED = 'FAILED'.freeze, LIFECYCLE_STATE_IN_PROGRESS = 'IN_PROGRESS'.freeze, LIFECYCLE_STATE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
Instance Attribute Summary collapse
-
#action ⇒ String
[Required] action for upgrading database.
-
#id ⇒ String
[Required] The [OCID](docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the database upgrade history.
-
#lifecycle_details ⇒ String
Additional information about the current lifecycle state.
-
#lifecycle_state ⇒ String
[Required] Status of database upgrade history SUCCEEDED|IN_PROGRESS|FAILED.
-
#source ⇒ String
The source of the database upgrade Use ‘DB_HOME’ for using existing db home to upgrade the database Use ‘DB_VERSION’ for using database version to upgrade the database Use ‘DB_SOFTWARE_IMAGE’ for using database software image to upgrade the database.
-
#source_db_home_id ⇒ String
The [OCID](docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the Database Home.
-
#target_database_software_image_id ⇒ String
the database software image used for upgrading database.
-
#target_db_home_id ⇒ String
The [OCID](docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the Database Home.
-
#target_db_version ⇒ String
A valid Oracle Database version.
-
#time_ended ⇒ DateTime
The date and time when the database upgrade ended.
-
#time_started ⇒ DateTime
[Required] The date and time when the database upgrade started.
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 = {}) ⇒ DatabaseUpgradeHistoryEntrySummary
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 = {}) ⇒ DatabaseUpgradeHistoryEntrySummary
Initializes the object
143 144 145 146 147 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 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 143 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.id = attributes[:'id'] if attributes[:'id'] self.action = attributes[:'action'] if attributes[:'action'] self.source = attributes[:'source'] if attributes[:'source'] self.lifecycle_state = attributes[:'lifecycleState'] if attributes[:'lifecycleState'] raise 'You cannot provide both :lifecycleState and :lifecycle_state' if attributes.key?(:'lifecycleState') && attributes.key?(:'lifecycle_state') self.lifecycle_state = attributes[:'lifecycle_state'] if attributes[:'lifecycle_state'] self.lifecycle_details = attributes[:'lifecycleDetails'] if attributes[:'lifecycleDetails'] raise 'You cannot provide both :lifecycleDetails and :lifecycle_details' if attributes.key?(:'lifecycleDetails') && attributes.key?(:'lifecycle_details') self.lifecycle_details = attributes[:'lifecycle_details'] if attributes[:'lifecycle_details'] self.target_db_version = attributes[:'targetDBVersion'] if attributes[:'targetDBVersion'] raise 'You cannot provide both :targetDBVersion and :target_db_version' if attributes.key?(:'targetDBVersion') && attributes.key?(:'target_db_version') self.target_db_version = attributes[:'target_db_version'] if attributes[:'target_db_version'] self.target_database_software_image_id = attributes[:'targetDatabaseSoftwareImageId'] if attributes[:'targetDatabaseSoftwareImageId'] raise 'You cannot provide both :targetDatabaseSoftwareImageId and :target_database_software_image_id' if attributes.key?(:'targetDatabaseSoftwareImageId') && attributes.key?(:'target_database_software_image_id') self.target_database_software_image_id = attributes[:'target_database_software_image_id'] if attributes[:'target_database_software_image_id'] self.target_db_home_id = attributes[:'targetDbHomeId'] if attributes[:'targetDbHomeId'] raise 'You cannot provide both :targetDbHomeId and :target_db_home_id' if attributes.key?(:'targetDbHomeId') && attributes.key?(:'target_db_home_id') self.target_db_home_id = attributes[:'target_db_home_id'] if attributes[:'target_db_home_id'] self.source_db_home_id = attributes[:'sourceDbHomeId'] if attributes[:'sourceDbHomeId'] raise 'You cannot provide both :sourceDbHomeId and :source_db_home_id' if attributes.key?(:'sourceDbHomeId') && attributes.key?(:'source_db_home_id') self.source_db_home_id = attributes[:'source_db_home_id'] if attributes[:'source_db_home_id'] self.time_started = attributes[:'timeStarted'] if attributes[:'timeStarted'] raise 'You cannot provide both :timeStarted and :time_started' if attributes.key?(:'timeStarted') && attributes.key?(:'time_started') self.time_started = attributes[:'time_started'] if attributes[:'time_started'] self.time_ended = attributes[:'timeEnded'] if attributes[:'timeEnded'] raise 'You cannot provide both :timeEnded and :time_ended' if attributes.key?(:'timeEnded') && attributes.key?(:'time_ended') self.time_ended = attributes[:'time_ended'] if attributes[:'time_ended'] end |
Instance Attribute Details
#action ⇒ String
[Required] action for upgrading database.
46 47 48 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 46 def action @action end |
#id ⇒ String
[Required] The [OCID](docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the database upgrade history.
42 43 44 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 42 def id @id end |
#lifecycle_details ⇒ String
Additional information about the current lifecycle state.
62 63 64 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 62 def lifecycle_details @lifecycle_details end |
#lifecycle_state ⇒ String
[Required] Status of database upgrade history SUCCEEDED|IN_PROGRESS|FAILED.
58 59 60 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 58 def lifecycle_state @lifecycle_state end |
#source ⇒ String
The source of the database upgrade Use ‘DB_HOME’ for using existing db home to upgrade the database Use ‘DB_VERSION’ for using database version to upgrade the database Use ‘DB_SOFTWARE_IMAGE’ for using database software image to upgrade the database
54 55 56 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 54 def source @source end |
#source_db_home_id ⇒ String
The [OCID](docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the Database Home.
78 79 80 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 78 def source_db_home_id @source_db_home_id end |
#target_database_software_image_id ⇒ String
the database software image used for upgrading database.
70 71 72 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 70 def target_database_software_image_id @target_database_software_image_id end |
#target_db_home_id ⇒ String
The [OCID](docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the Database Home.
74 75 76 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 74 def target_db_home_id @target_db_home_id end |
#target_db_version ⇒ String
A valid Oracle Database version. To get a list of supported versions, use the list_db_versions operation.
66 67 68 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 66 def target_db_version @target_db_version end |
#time_ended ⇒ DateTime
The date and time when the database upgrade ended.
86 87 88 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 86 def time_ended @time_ended end |
#time_started ⇒ DateTime
[Required] The date and time when the database upgrade started.
82 83 84 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 82 def time_started @time_started end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 89 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'id': :'id', 'action': :'action', 'source': :'source', 'lifecycle_state': :'lifecycleState', 'lifecycle_details': :'lifecycleDetails', 'target_db_version': :'targetDBVersion', 'target_database_software_image_id': :'targetDatabaseSoftwareImageId', 'target_db_home_id': :'targetDbHomeId', 'source_db_home_id': :'sourceDbHomeId', 'time_started': :'timeStarted', 'time_ended': :'timeEnded' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 108 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'id': :'String', 'action': :'String', 'source': :'String', 'lifecycle_state': :'String', 'lifecycle_details': :'String', 'target_db_version': :'String', 'target_database_software_image_id': :'String', 'target_db_home_id': :'String', 'source_db_home_id': :'String', 'time_started': :'DateTime', 'time_ended': :'DateTime' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 250 def ==(other) return true if equal?(other) self.class == other.class && id == other.id && action == other.action && source == other.source && lifecycle_state == other.lifecycle_state && lifecycle_details == other.lifecycle_details && target_db_version == other.target_db_version && target_database_software_image_id == other.target_database_software_image_id && target_db_home_id == other.target_db_home_id && source_db_home_id == other.source_db_home_id && time_started == other.time_started && time_ended == other.time_ended end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 290 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
270 271 272 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 270 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
279 280 281 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 279 def hash [id, action, source, lifecycle_state, lifecycle_details, target_db_version, target_database_software_image_id, target_db_home_id, source_db_home_id, time_started, time_ended].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
323 324 325 326 327 328 329 330 331 332 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 323 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
317 318 319 |
# File 'lib/oci/database/models/database_upgrade_history_entry_summary.rb', line 317 def to_s to_hash.to_s end |