Class: Google::Apis::TrafficdirectorV2::Locality
- Inherits:
-
Object
- Object
- Google::Apis::TrafficdirectorV2::Locality
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- generated/google/apis/trafficdirector_v2/classes.rb,
generated/google/apis/trafficdirector_v2/representations.rb,
generated/google/apis/trafficdirector_v2/representations.rb
Overview
Identifies location of where either Envoy runs or where upstream hosts run.
Instance Attribute Summary collapse
-
#region ⇒ String
Region this :ref:
zone
belongs to. -
#sub_zone ⇒ String
When used for locality of upstream hosts, this field further splits zone into smaller chunks of sub-zones so they can be load balanced independently.
-
#zone ⇒ String
Defines the local service zone where Envoy is running.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Locality
constructor
A new instance of Locality.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ Locality
Returns a new instance of Locality.
630 631 632 |
# File 'generated/google/apis/trafficdirector_v2/classes.rb', line 630 def initialize(**args) update!(**args) end |
Instance Attribute Details
#region ⇒ String
Region this :ref:zone
belongs to.
Corresponds to the JSON property region
613 614 615 |
# File 'generated/google/apis/trafficdirector_v2/classes.rb', line 613 def region @region end |
#sub_zone ⇒ String
When used for locality of upstream hosts, this field further splits zone into
smaller chunks of sub-zones so they can be load balanced independently.
Corresponds to the JSON property subZone
619 620 621 |
# File 'generated/google/apis/trafficdirector_v2/classes.rb', line 619 def sub_zone @sub_zone end |
#zone ⇒ String
Defines the local service zone where Envoy is running. Though optional, it
should be set if discovery service routing is used and the discovery service
exposes :ref:zone data
, either in this message or via :option:--service-
zone
. The meaning of zone is context dependent, e.g. Availability Zone (AZ)
_ on AWS, Zone
_ on GCP, etc.
Corresponds to the JSON property zone
628 629 630 |
# File 'generated/google/apis/trafficdirector_v2/classes.rb', line 628 def zone @zone end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
635 636 637 638 639 |
# File 'generated/google/apis/trafficdirector_v2/classes.rb', line 635 def update!(**args) @region = args[:region] if args.key?(:region) @sub_zone = args[:sub_zone] if args.key?(:sub_zone) @zone = args[:zone] if args.key?(:zone) end |