Class: Google::Apis::BigtableadminV2::AutomatedBackupPolicy

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

Overview

Defines an automated backup policy for a table

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ AutomatedBackupPolicy

Returns a new instance of AutomatedBackupPolicy.



241
242
243
# File 'lib/google/apis/bigtableadmin_v2/classes.rb', line 241

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

Instance Attribute Details

#frequencyString

How frequently automated backups should occur. The only supported value at this time is 24 hours. An undefined frequency is treated as 24 hours. Corresponds to the JSON property frequency

Returns:

  • (String)


225
226
227
# File 'lib/google/apis/bigtableadmin_v2/classes.rb', line 225

def frequency
  @frequency
end

#locationsArray<String>

Optional. A list of Cloud Bigtable zones where automated backups are allowed to be created. If empty, automated backups will be created in all zones of the instance. Locations are in the format projects/project/locations/zone`. This field can only set for tables in Enterprise Plus instances. Corresponds to the JSON propertylocations`

Returns:

  • (Array<String>)


233
234
235
# File 'lib/google/apis/bigtableadmin_v2/classes.rb', line 233

def locations
  @locations
end

#retention_periodString

Required. How long the automated backups should be retained. Values must be at least 3 days and at most 90 days. Corresponds to the JSON property retentionPeriod

Returns:

  • (String)


239
240
241
# File 'lib/google/apis/bigtableadmin_v2/classes.rb', line 239

def retention_period
  @retention_period
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



246
247
248
249
250
# File 'lib/google/apis/bigtableadmin_v2/classes.rb', line 246

def update!(**args)
  @frequency = args[:frequency] if args.key?(:frequency)
  @locations = args[:locations] if args.key?(:locations)
  @retention_period = args[:retention_period] if args.key?(:retention_period)
end