Class: Google::Apis::FileV1::ReplicaConfig

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

Overview

Replica configuration for the instance.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ ReplicaConfig

Returns a new instance of ReplicaConfig.



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

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

Instance Attribute Details

#last_active_sync_timeString

Output only. The timestamp of the latest replication snapshot taken on the active instance and is already replicated safely. Corresponds to the JSON property lastActiveSyncTime

Returns:

  • (String)


1777
1778
1779
# File 'lib/google/apis/file_v1/classes.rb', line 1777

def last_active_sync_time
  @last_active_sync_time
end

#peer_instanceString

Optional. The name of the source instance for the replica, in the format projects/project/locations/location/instances/instance`. This field is required when creating a replica. Corresponds to the JSON propertypeerInstance`

Returns:

  • (String)


1784
1785
1786
# File 'lib/google/apis/file_v1/classes.rb', line 1784

def peer_instance
  @peer_instance
end

#stateString

Output only. The replica state. Corresponds to the JSON property state

Returns:

  • (String)


1789
1790
1791
# File 'lib/google/apis/file_v1/classes.rb', line 1789

def state
  @state
end

#state_reasonsArray<String>

Output only. Additional information about the replication state, if available. Corresponds to the JSON property stateReasons

Returns:

  • (Array<String>)


1794
1795
1796
# File 'lib/google/apis/file_v1/classes.rb', line 1794

def state_reasons
  @state_reasons
end

#state_update_timeString

Output only. The time when the replica state was updated. Corresponds to the JSON property stateUpdateTime

Returns:

  • (String)


1799
1800
1801
# File 'lib/google/apis/file_v1/classes.rb', line 1799

def state_update_time
  @state_update_time
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1806
1807
1808
1809
1810
1811
1812
# File 'lib/google/apis/file_v1/classes.rb', line 1806

def update!(**args)
  @last_active_sync_time = args[:last_active_sync_time] if args.key?(:last_active_sync_time)
  @peer_instance = args[:peer_instance] if args.key?(:peer_instance)
  @state = args[:state] if args.key?(:state)
  @state_reasons = args[:state_reasons] if args.key?(:state_reasons)
  @state_update_time = args[:state_update_time] if args.key?(:state_update_time)
end