Class: Google::Apis::GkebackupV1::Restore

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

Overview

Represents both a request to Restore some portion of a Backup into a target GKE cluster and a record of the restore operation itself.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Restore

Returns a new instance of Restore.



2396
2397
2398
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2396

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

Instance Attribute Details

#backupString

Required. Immutable. A reference to the Backup used as the source from which this Restore will restore. Note that this Backup must be a sub-resource of the RestorePlan's backup_plan. Format: projects/*/locations/*/backupPlans/*/ backups/*. Corresponds to the JSON property backup

Returns:

  • (String)


2279
2280
2281
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2279

def backup
  @backup
end

#clusterString

Output only. The target cluster into which this Restore will restore data. Valid formats: - projects/*/locations/*/clusters/* - projects/*/zones/*/ clusters/* Inherited from parent RestorePlan's cluster value. Corresponds to the JSON property cluster

Returns:

  • (String)


2286
2287
2288
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2286

def cluster
  @cluster
end

#complete_timeString

Output only. Timestamp of when the restore operation completed. Corresponds to the JSON property completeTime

Returns:

  • (String)


2291
2292
2293
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2291

def complete_time
  @complete_time
end

#create_timeString

Output only. The timestamp when this Restore resource was created. Corresponds to the JSON property createTime

Returns:

  • (String)


2296
2297
2298
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2296

def create_time
  @create_time
end

#descriptionString

Optional. User specified descriptive string for this Restore. Corresponds to the JSON property description

Returns:

  • (String)


2301
2302
2303
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2301

def description
  @description
end

#etagString

Output only. etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a restore from overwriting each other. It is strongly suggested that systems make use of the etag in the read-modify- write cycle to perform restore updates in order to avoid race conditions: An etag is returned in the response to GetRestore, and systems are expected to put that etag in the request to UpdateRestore or DeleteRestore to ensure that their change will be applied to the same version of the resource. Corresponds to the JSON property etag

Returns:

  • (String)


2312
2313
2314
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2312

def etag
  @etag
end

#filterGoogle::Apis::GkebackupV1::Filter

Defines the filter for Restore. This filter can be used to further refine the resource selection of the Restore beyond the coarse-grained scope defined in the RestorePlan. exclusion_filters take precedence over inclusion_filters. If a resource matches both inclusion_filters and exclusion_filters, it will not be restored. Corresponds to the JSON property filter



2321
2322
2323
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2321

def filter
  @filter
end

#labelsHash<String,String>

A set of custom labels supplied by user. Corresponds to the JSON property labels

Returns:

  • (Hash<String,String>)


2326
2327
2328
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2326

def labels
  @labels
end

#nameString

Output only. Identifier. The full name of the Restore resource. Format: projects/*/locations/*/restorePlans/*/restores/* Corresponds to the JSON property name

Returns:

  • (String)


2332
2333
2334
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2332

def name
  @name
end

#resources_excluded_countFixnum

Output only. Number of resources excluded during the restore execution. Corresponds to the JSON property resourcesExcludedCount

Returns:

  • (Fixnum)


2337
2338
2339
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2337

def resources_excluded_count
  @resources_excluded_count
end

#resources_failed_countFixnum

Output only. Number of resources that failed to be restored during the restore execution. Corresponds to the JSON property resourcesFailedCount

Returns:

  • (Fixnum)


2343
2344
2345
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2343

def resources_failed_count
  @resources_failed_count
end

#resources_restored_countFixnum

Output only. Number of resources restored during the restore execution. Corresponds to the JSON property resourcesRestoredCount

Returns:

  • (Fixnum)


2348
2349
2350
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2348

def resources_restored_count
  @resources_restored_count
end

#restore_configGoogle::Apis::GkebackupV1::RestoreConfig

Configuration of a restore. Corresponds to the JSON property restoreConfig



2353
2354
2355
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2353

def restore_config
  @restore_config
end

#stateString

Output only. The current state of the Restore. Corresponds to the JSON property state

Returns:

  • (String)


2358
2359
2360
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2358

def state
  @state
end

#state_reasonString

Output only. Human-readable description of why the Restore is in its current state. This field is only meant for human readability and should not be used programmatically as this field is not guaranteed to be consistent. Corresponds to the JSON property stateReason

Returns:

  • (String)


2365
2366
2367
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2365

def state_reason
  @state_reason
end

#troubleshooting_infoGoogle::Apis::GkebackupV1::TroubleshootingInfo

Stores information about troubleshooting doc for debugging a particular state of an operation (eg - backup/restore). This will be used by the end user to debug their operation failure scenario easily. Corresponds to the JSON property troubleshootingInfo



2372
2373
2374
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2372

def troubleshooting_info
  @troubleshooting_info
end

#uidString

Output only. Server generated global unique identifier of UUID format. Corresponds to the JSON property uid

Returns:

  • (String)


2378
2379
2380
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2378

def uid
  @uid
end

#update_timeString

Output only. The timestamp when this Restore resource was last updated. Corresponds to the JSON property updateTime

Returns:

  • (String)


2383
2384
2385
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2383

def update_time
  @update_time
end

#volume_data_restore_policy_overridesArray<Google::Apis::GkebackupV1::VolumeDataRestorePolicyOverride>

Optional. Immutable. Overrides the volume data restore policies selected in the Restore Config for override-scoped resources. Corresponds to the JSON property volumeDataRestorePolicyOverrides



2389
2390
2391
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2389

def volume_data_restore_policy_overrides
  @volume_data_restore_policy_overrides
end

#volumes_restored_countFixnum

Output only. Number of volumes restored during the restore execution. Corresponds to the JSON property volumesRestoredCount

Returns:

  • (Fixnum)


2394
2395
2396
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2394

def volumes_restored_count
  @volumes_restored_count
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2401
2402
2403
2404
2405
2406
2407
2408
2409
2410
2411
2412
2413
2414
2415
2416
2417
2418
2419
2420
2421
2422
# File 'lib/google/apis/gkebackup_v1/classes.rb', line 2401

def update!(**args)
  @backup = args[:backup] if args.key?(:backup)
  @cluster = args[:cluster] if args.key?(:cluster)
  @complete_time = args[:complete_time] if args.key?(:complete_time)
  @create_time = args[:create_time] if args.key?(:create_time)
  @description = args[:description] if args.key?(:description)
  @etag = args[:etag] if args.key?(:etag)
  @filter = args[:filter] if args.key?(:filter)
  @labels = args[:labels] if args.key?(:labels)
  @name = args[:name] if args.key?(:name)
  @resources_excluded_count = args[:resources_excluded_count] if args.key?(:resources_excluded_count)
  @resources_failed_count = args[:resources_failed_count] if args.key?(:resources_failed_count)
  @resources_restored_count = args[:resources_restored_count] if args.key?(:resources_restored_count)
  @restore_config = args[:restore_config] if args.key?(:restore_config)
  @state = args[:state] if args.key?(:state)
  @state_reason = args[:state_reason] if args.key?(:state_reason)
  @troubleshooting_info = args[:troubleshooting_info] if args.key?(:troubleshooting_info)
  @uid = args[:uid] if args.key?(:uid)
  @update_time = args[:update_time] if args.key?(:update_time)
  @volume_data_restore_policy_overrides = args[:volume_data_restore_policy_overrides] if args.key?(:volume_data_restore_policy_overrides)
  @volumes_restored_count = args[:volumes_restored_count] if args.key?(:volumes_restored_count)
end