Class: Google::Apis::BaremetalsolutionV2::Volume

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/baremetalsolution_v2/classes.rb,
lib/google/apis/baremetalsolution_v2/representations.rb,
lib/google/apis/baremetalsolution_v2/representations.rb

Overview

A storage volume.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Volume

Returns a new instance of Volume.



1853
1854
1855
# File 'lib/google/apis/baremetalsolution_v2/classes.rb', line 1853

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#auto_grown_size_gibFixnum

The size, in GiB, that this storage volume has expanded as a result of an auto grow policy. In the absence of auto-grow, the value is 0. Corresponds to the JSON property autoGrownSizeGib

Returns:

  • (Fixnum)


1778
1779
1780
# File 'lib/google/apis/baremetalsolution_v2/classes.rb', line 1778

def auto_grown_size_gib
  @auto_grown_size_gib
end

#current_size_gibFixnum

The current size of this storage volume, in GiB, including space reserved for snapshots. This size might be different than the requested size if the storage volume has been configured with auto grow or auto shrink. Corresponds to the JSON property currentSizeGib

Returns:

  • (Fixnum)


1785
1786
1787
# File 'lib/google/apis/baremetalsolution_v2/classes.rb', line 1785

def current_size_gib
  @current_size_gib
end

#emergency_size_gibFixnum

Additional emergency size that was requested for this Volume, in GiB. current_size_gib includes this value. Corresponds to the JSON property emergencySizeGib

Returns:

  • (Fixnum)


1791
1792
1793
# File 'lib/google/apis/baremetalsolution_v2/classes.rb', line 1791

def emergency_size_gib
  @emergency_size_gib
end

#idString

An identifier for the Volume, generated by the backend. Corresponds to the JSON property id

Returns:

  • (String)


1796
1797
1798
# File 'lib/google/apis/baremetalsolution_v2/classes.rb', line 1796

def id
  @id
end

#labelsHash<String,String>

Labels as key value pairs. Corresponds to the JSON property labels

Returns:

  • (Hash<String,String>)


1801
1802
1803
# File 'lib/google/apis/baremetalsolution_v2/classes.rb', line 1801

def labels
  @labels
end

#nameString

Output only. The resource name of this Volume. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/ resource_names. Format: projects/project/locations/location/volumes/ volume` Corresponds to the JSON propertyname`

Returns:

  • (String)


1809
1810
1811
# File 'lib/google/apis/baremetalsolution_v2/classes.rb', line 1809

def name
  @name
end

#remaining_space_gibFixnum

The space remaining in the storage volume for new LUNs, in GiB, excluding space reserved for snapshots. Corresponds to the JSON property remainingSpaceGib

Returns:

  • (Fixnum)


1815
1816
1817
# File 'lib/google/apis/baremetalsolution_v2/classes.rb', line 1815

def remaining_space_gib
  @remaining_space_gib
end

#requested_size_gibFixnum

The requested size of this storage volume, in GiB. Corresponds to the JSON property requestedSizeGib

Returns:

  • (Fixnum)


1820
1821
1822
# File 'lib/google/apis/baremetalsolution_v2/classes.rb', line 1820

def requested_size_gib
  @requested_size_gib
end

#snapshot_auto_delete_behaviorString

The behavior to use when snapshot reserved space is full. Corresponds to the JSON property snapshotAutoDeleteBehavior

Returns:

  • (String)


1825
1826
1827
# File 'lib/google/apis/baremetalsolution_v2/classes.rb', line 1825

def snapshot_auto_delete_behavior
  @snapshot_auto_delete_behavior
end

#snapshot_enabledBoolean Also known as: snapshot_enabled?

Whether snapshots are enabled. Corresponds to the JSON property snapshotEnabled

Returns:

  • (Boolean)


1830
1831
1832
# File 'lib/google/apis/baremetalsolution_v2/classes.rb', line 1830

def snapshot_enabled
  @snapshot_enabled
end

#snapshot_reservation_detailGoogle::Apis::BaremetalsolutionV2::SnapshotReservationDetail

Details about snapshot space reservation and usage on the storage volume. Corresponds to the JSON property snapshotReservationDetail



1836
1837
1838
# File 'lib/google/apis/baremetalsolution_v2/classes.rb', line 1836

def snapshot_reservation_detail
  @snapshot_reservation_detail
end

#snapshot_schedule_policyString

The name of the snapshot schedule policy in use for this volume, if any. Corresponds to the JSON property snapshotSchedulePolicy

Returns:

  • (String)


1841
1842
1843
# File 'lib/google/apis/baremetalsolution_v2/classes.rb', line 1841

def snapshot_schedule_policy
  @snapshot_schedule_policy
end

#stateString

The state of this storage volume. Corresponds to the JSON property state

Returns:

  • (String)


1846
1847
1848
# File 'lib/google/apis/baremetalsolution_v2/classes.rb', line 1846

def state
  @state
end

#storage_typeString

The storage type for this volume. Corresponds to the JSON property storageType

Returns:

  • (String)


1851
1852
1853
# File 'lib/google/apis/baremetalsolution_v2/classes.rb', line 1851

def storage_type
  @storage_type
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
# File 'lib/google/apis/baremetalsolution_v2/classes.rb', line 1858

def update!(**args)
  @auto_grown_size_gib = args[:auto_grown_size_gib] if args.key?(:auto_grown_size_gib)
  @current_size_gib = args[:current_size_gib] if args.key?(:current_size_gib)
  @emergency_size_gib = args[:emergency_size_gib] if args.key?(:emergency_size_gib)
  @id = args[:id] if args.key?(:id)
  @labels = args[:labels] if args.key?(:labels)
  @name = args[:name] if args.key?(:name)
  @remaining_space_gib = args[:remaining_space_gib] if args.key?(:remaining_space_gib)
  @requested_size_gib = args[:requested_size_gib] if args.key?(:requested_size_gib)
  @snapshot_auto_delete_behavior = args[:snapshot_auto_delete_behavior] if args.key?(:snapshot_auto_delete_behavior)
  @snapshot_enabled = args[:snapshot_enabled] if args.key?(:snapshot_enabled)
  @snapshot_reservation_detail = args[:snapshot_reservation_detail] if args.key?(:snapshot_reservation_detail)
  @snapshot_schedule_policy = args[:snapshot_schedule_policy] if args.key?(:snapshot_schedule_policy)
  @state = args[:state] if args.key?(:state)
  @storage_type = args[:storage_type] if args.key?(:storage_type)
end