Class: OCI::Database::Models::DbSystem

Inherits:
Object
  • Object
show all
Defined in:
lib/oci/database/models/db_system.rb

Constant Summary collapse

DATABASE_EDITION_ENUM =
[DATABASE_EDITION_STANDARD_EDITION = 'STANDARD_EDITION',
DATABASE_EDITION_ENTERPRISE_EDITION = 'ENTERPRISE_EDITION',
DATABASE_EDITION_ENTERPRISE_EDITION_EXTREME_PERFORMANCE = 'ENTERPRISE_EDITION_EXTREME_PERFORMANCE',
DATABASE_EDITION_ENTERPRISE_EDITION_HIGH_PERFORMANCE = 'ENTERPRISE_EDITION_HIGH_PERFORMANCE',
DATABASE_EDITION_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE']
DISK_REDUNDANCY_ENUM =
[DISK_REDUNDANCY_HIGH = 'HIGH',
DISK_REDUNDANCY_NORMAL = 'NORMAL',
DISK_REDUNDANCY_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE']
LICENSE_MODEL_ENUM =
[LICENSE_MODEL_LICENSE_INCLUDED = 'LICENSE_INCLUDED',
LICENSE_MODEL_BRING_YOUR_OWN_LICENSE = 'BRING_YOUR_OWN_LICENSE',
LICENSE_MODEL_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE']
LIFECYCLE_STATE_ENUM =
[LIFECYCLE_STATE_PROVISIONING = 'PROVISIONING',
LIFECYCLE_STATE_AVAILABLE = 'AVAILABLE',
LIFECYCLE_STATE_UPDATING = 'UPDATING',
LIFECYCLE_STATE_TERMINATING = 'TERMINATING',
LIFECYCLE_STATE_TERMINATED = 'TERMINATED',
LIFECYCLE_STATE_FAILED = 'FAILED',
LIFECYCLE_STATE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE']

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attributes = {}) ⇒ DbSystem

Initializes the object

Parameters:

  • attributes (Hash) (defaults to: {})

    Model attributes in the form of hash



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
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
# File 'lib/oci/database/models/db_system.rb', line 183

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}

  if attributes[:'availabilityDomain']
    self.availability_domain = attributes[:'availabilityDomain']
  end

  if attributes[:'backupSubnetId']
    self.backup_subnet_id = attributes[:'backupSubnetId']
  end

  if attributes[:'clusterName']
    self.cluster_name = attributes[:'clusterName']
  end

  if attributes[:'compartmentId']
    self.compartment_id = attributes[:'compartmentId']
  end

  if attributes[:'cpuCoreCount']
    self.cpu_core_count = attributes[:'cpuCoreCount']
  end

  if attributes[:'dataStoragePercentage']
    self.data_storage_percentage = attributes[:'dataStoragePercentage']
  end

  if attributes[:'dataStorageSizeInGBs']
    self.data_storage_size_in_gbs = attributes[:'dataStorageSizeInGBs']
  end

  if attributes[:'databaseEdition']
    self.database_edition = attributes[:'databaseEdition']
  end

  if attributes[:'diskRedundancy']
    self.disk_redundancy = attributes[:'diskRedundancy']
  end

  if attributes[:'displayName']
    self.display_name = attributes[:'displayName']
  end

  if attributes[:'domain']
    self.domain = attributes[:'domain']
  end

  if attributes[:'hostname']
    self.hostname = attributes[:'hostname']
  end

  if attributes[:'id']
    self.id = attributes[:'id']
  end

  if attributes[:'lastPatchHistoryEntryId']
    self.last_patch_history_entry_id = attributes[:'lastPatchHistoryEntryId']
  end

  if attributes[:'licenseModel']
    self.license_model = attributes[:'licenseModel']
  end

  if attributes[:'lifecycleDetails']
    self.lifecycle_details = attributes[:'lifecycleDetails']
  end

  if attributes[:'lifecycleState']
    self.lifecycle_state = attributes[:'lifecycleState']
  end

  if attributes[:'listenerPort']
    self.listener_port = attributes[:'listenerPort']
  end

  if attributes[:'nodeCount']
    self.node_count = attributes[:'nodeCount']
  end

  if attributes[:'recoStorageSizeInGB']
    self.reco_storage_size_in_gb = attributes[:'recoStorageSizeInGB']
  end

  if attributes[:'scanDnsRecordId']
    self.scan_dns_record_id = attributes[:'scanDnsRecordId']
  end

  if attributes[:'scanIpIds']
    self.scan_ip_ids = attributes[:'scanIpIds']
  end

  if attributes[:'shape']
    self.shape = attributes[:'shape']
  end

  if attributes[:'sshPublicKeys']
    self.ssh_public_keys = attributes[:'sshPublicKeys']
  end

  if attributes[:'subnetId']
    self.subnet_id = attributes[:'subnetId']
  end

  if attributes[:'timeCreated']
    self.time_created = attributes[:'timeCreated']
  end

  if attributes[:'version']
    self.version = attributes[:'version']
  end

  if attributes[:'vipIds']
    self.vip_ids = attributes[:'vipIds']
  end

end

Instance Attribute Details

#availability_domainString

The name of the Availability Domain that the DB System is located in.

Returns:

  • (String)


35
36
37
# File 'lib/oci/database/models/db_system.rb', line 35

def availability_domain
  @availability_domain
end

#backup_subnet_idString

The OCID of the backup network subnet the DB System is associated with. Applicable only to Exadata.

**Subnet Restriction:** See above subnetId’s ‘Subnet Restriction’. to malfunction.

Returns:

  • (String)


43
44
45
# File 'lib/oci/database/models/db_system.rb', line 43

def backup_subnet_id
  @backup_subnet_id
end

#cluster_nameString

Cluster name for Exadata and 2-node RAC DB Systems. The cluster name must begin with an an alphabetic character, and may contain hyphens (-). Underscores (_) are not permitted. The cluster name can be no longer than 11 characters and is not case sensitive.

Returns:

  • (String)


48
49
50
# File 'lib/oci/database/models/db_system.rb', line 48

def cluster_name
  @cluster_name
end

#compartment_idString

The OCID of the compartment.

Returns:

  • (String)


52
53
54
# File 'lib/oci/database/models/db_system.rb', line 52

def compartment_id
  @compartment_id
end

#cpu_core_countInteger

The number of CPU cores enabled on the DB System.

Returns:

  • (Integer)


56
57
58
# File 'lib/oci/database/models/db_system.rb', line 56

def cpu_core_count
  @cpu_core_count
end

#data_storage_percentageInteger

The percentage assigned to DATA storage (user data and database files). The remaining percentage is assigned to RECO storage (database redo logs, archive logs, and recovery manager backups). Accepted values are 40 and 80.

Returns:

  • (Integer)


62
63
64
# File 'lib/oci/database/models/db_system.rb', line 62

def data_storage_percentage
  @data_storage_percentage
end

#data_storage_size_in_gbsInteger

Data storage size, in GBs, that is currently available to the DB system. This is applicable only for VM-based DBs.

Returns:

  • (Integer)


67
68
69
# File 'lib/oci/database/models/db_system.rb', line 67

def data_storage_size_in_gbs
  @data_storage_size_in_gbs
end

#database_editionString

The Oracle Database Edition that applies to all the databases on the DB System.

Returns:

  • (String)


72
73
74
# File 'lib/oci/database/models/db_system.rb', line 72

def database_edition
  @database_edition
end

#disk_redundancyString

The type of redundancy configured for the DB System. Normal is 2-way redundancy. High is 3-way redundancy.

Returns:

  • (String)


79
80
81
# File 'lib/oci/database/models/db_system.rb', line 79

def disk_redundancy
  @disk_redundancy
end

#display_nameString

The user-friendly name for the DB System. It does not have to be unique.

Returns:

  • (String)


83
84
85
# File 'lib/oci/database/models/db_system.rb', line 83

def display_name
  @display_name
end

#domainString

The domain name for the DB System.

Returns:

  • (String)


87
88
89
# File 'lib/oci/database/models/db_system.rb', line 87

def domain
  @domain
end

#hostnameString

The host name for the DB Node.

Returns:

  • (String)


91
92
93
# File 'lib/oci/database/models/db_system.rb', line 91

def hostname
  @hostname
end

#idString

The OCID of the DB System.

Returns:

  • (String)


95
96
97
# File 'lib/oci/database/models/db_system.rb', line 95

def id
  @id
end

#last_patch_history_entry_idString

The OCID of the last patch history. This is updated as soon as a patch operation is started.

Returns:

  • (String)


99
100
101
# File 'lib/oci/database/models/db_system.rb', line 99

def last_patch_history_entry_id
  @last_patch_history_entry_id
end

#license_modelString

The Oracle license model that applies to all the databases on the DB System. The default is LICENSE_INCLUDED.

Returns:

  • (String)


104
105
106
# File 'lib/oci/database/models/db_system.rb', line 104

def license_model
  @license_model
end

#lifecycle_detailsString

Additional information about the current lifecycleState.

Returns:

  • (String)


108
109
110
# File 'lib/oci/database/models/db_system.rb', line 108

def lifecycle_details
  @lifecycle_details
end

#lifecycle_stateString

The current state of the DB System.

Returns:

  • (String)


112
113
114
# File 'lib/oci/database/models/db_system.rb', line 112

def lifecycle_state
  @lifecycle_state
end

#listener_portInteger

The port number configured for the listener on the DB System.

Returns:

  • (Integer)


116
117
118
# File 'lib/oci/database/models/db_system.rb', line 116

def listener_port
  @listener_port
end

#node_countInteger

Number of nodes in this DB system. For RAC DBs, this will be greater than 1.

Returns:

  • (Integer)


121
122
123
# File 'lib/oci/database/models/db_system.rb', line 121

def node_count
  @node_count
end

#reco_storage_size_in_gbInteger

RECO/REDO storage size, in GBs, that is currently allocated to the DB system. This is applicable only for VM-based DBs.

Returns:

  • (Integer)


126
127
128
# File 'lib/oci/database/models/db_system.rb', line 126

def reco_storage_size_in_gb
  @reco_storage_size_in_gb
end

#scan_dns_record_idString

The OCID of the DNS record for the SCAN IP addresses that are associated with the DB System.

Returns:

  • (String)


131
132
133
# File 'lib/oci/database/models/db_system.rb', line 131

def scan_dns_record_id
  @scan_dns_record_id
end

#scan_ip_idsArray<String>

The OCID of the Single Client Access Name (SCAN) IP addresses associated with the DB System. SCAN IP addresses are typically used for load balancing and are not assigned to any interface. Clusterware directs the requests to the appropriate nodes in the cluster.

  • For a single-node DB System, this list is empty.

Returns:

  • (Array<String>)


140
141
142
# File 'lib/oci/database/models/db_system.rb', line 140

def scan_ip_ids
  @scan_ip_ids
end

#shapeString

The shape of the DB System. The shape determines resources to allocate to the DB system - CPU cores and memory for VM shapes; CPU cores, memory and storage for non-VM (or bare metal) shapes.

Returns:

  • (String)


144
145
146
# File 'lib/oci/database/models/db_system.rb', line 144

def shape
  @shape
end

#ssh_public_keysArray<String>

The public key portion of one or more key pairs used for SSH access to the DB System.

Returns:

  • (Array<String>)


148
149
150
# File 'lib/oci/database/models/db_system.rb', line 148

def ssh_public_keys
  @ssh_public_keys
end

#subnet_idString

The OCID of the subnet the DB System is associated with.

**Subnet Restrictions:**

  • For single node and 2-node (RAC) DB Systems, do not use a subnet that overlaps with 192.168.16.16/28

  • For Exadata and VM-based RAC DB Systems, do not use a subnet that overlaps with 192.168.128.0/20

These subnets are used by the Oracle Clusterware private interconnect on the database instance. Specifying an overlapping subnet will cause the private interconnect to malfunction. This restriction applies to both the client subnet and backup subnet.

Returns:

  • (String)


161
162
163
# File 'lib/oci/database/models/db_system.rb', line 161

def subnet_id
  @subnet_id
end

#time_createdDateTime

The date and time the DB System was created.

Returns:

  • (DateTime)


165
166
167
# File 'lib/oci/database/models/db_system.rb', line 165

def time_created
  @time_created
end

#versionString

The version of the DB System.

Returns:

  • (String)


169
170
171
# File 'lib/oci/database/models/db_system.rb', line 169

def version
  @version
end

#vip_idsArray<String>

The OCID of the virtual IP (VIP) addresses associated with the DB System. The Cluster Ready Services (CRS) creates and maintains one VIP address for each node in the DB System to enable failover. If one node fails, the VIP is reassigned to another active node in the cluster.

  • For a single-node DB System, this list is empty.

Returns:

  • (Array<String>)


178
179
180
# File 'lib/oci/database/models/db_system.rb', line 178

def vip_ids
  @vip_ids
end

Instance Method Details

#==(other_object) ⇒ Object

Checks equality by comparing each attribute.

Parameters:

  • other_object (Object)

    to be compared



345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
# File 'lib/oci/database/models/db_system.rb', line 345

def ==(other_object)
  return true if self.equal?(other_object)
  self.class == other_object.class &&
      availability_domain == other_object.availability_domain &&
      backup_subnet_id == other_object.backup_subnet_id &&
      cluster_name == other_object.cluster_name &&
      compartment_id == other_object.compartment_id &&
      cpu_core_count == other_object.cpu_core_count &&
      data_storage_percentage == other_object.data_storage_percentage &&
      data_storage_size_in_gbs == other_object.data_storage_size_in_gbs &&
      database_edition == other_object.database_edition &&
      disk_redundancy == other_object.disk_redundancy &&
      display_name == other_object.display_name &&
      domain == other_object.domain &&
      hostname == other_object.hostname &&
      id == other_object.id &&
      last_patch_history_entry_id == other_object.last_patch_history_entry_id &&
      license_model == other_object.license_model &&
      lifecycle_details == other_object.lifecycle_details &&
      lifecycle_state == other_object.lifecycle_state &&
      listener_port == other_object.listener_port &&
      node_count == other_object.node_count &&
      reco_storage_size_in_gb == other_object.reco_storage_size_in_gb &&
      scan_dns_record_id == other_object.scan_dns_record_id &&
      scan_ip_ids == other_object.scan_ip_ids &&
      shape == other_object.shape &&
      ssh_public_keys == other_object.ssh_public_keys &&
      subnet_id == other_object.subnet_id &&
      time_created == other_object.time_created &&
      version == other_object.version &&
      vip_ids == other_object.vip_ids
end

#build_from_hash(attributes) ⇒ Object

Builds the object from hash

Parameters:

  • attributes (Hash)

    Model attributes in the form of hash

Returns:

  • (Object)

    Returns the model itself



393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
# File 'lib/oci/database/models/db_system.rb', line 393

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)
        self.public_method("#{key}=").call(attributes[self.class.attribute_map[key]].map{ |v| OCI::Internal::Util.convert_to_type($1, v) } )
      end
    elsif !attributes[self.class.attribute_map[key]].nil?
      self.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_object) ⇒ Boolean

Parameters:

  • other_object (Object)

    to be compared

Returns:

  • (Boolean)

See Also:

  • `==` method


380
381
382
# File 'lib/oci/database/models/db_system.rb', line 380

def eql?(other_object)
  self == other_object
end

#hashFixnum

Calculates hash code according to all attributes.

Returns:

  • (Fixnum)

    Hash code



386
387
388
# File 'lib/oci/database/models/db_system.rb', line 386

def hash
  [availability_domain, backup_subnet_id, cluster_name, compartment_id, cpu_core_count, data_storage_percentage, data_storage_size_in_gbs, database_edition, disk_redundancy, display_name, domain, hostname, id, last_patch_history_entry_id, license_model, lifecycle_details, lifecycle_state, listener_port, node_count, reco_storage_size_in_gb, scan_dns_record_id, scan_ip_ids, shape, ssh_public_keys, subnet_id, time_created, version, vip_ids].hash
end

#to_hashHash

Returns the object in the form of hash

Returns:

  • (Hash)

    Returns the object in the form of hash



418
419
420
421
422
423
424
425
426
# File 'lib/oci/database/models/db_system.rb', line 418

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_sString

Returns the string representation of the object

Returns:

  • (String)

    String presentation of the object



412
413
414
# File 'lib/oci/database/models/db_system.rb', line 412

def to_s
  to_hash.to_s
end