Class: Google::Apis::TrafficdirectorV2::SocketAddress
- Inherits:
-
Object
- Object
- Google::Apis::TrafficdirectorV2::SocketAddress
- 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
[#next-free-field: 7]
Instance Attribute Summary collapse
-
#address ⇒ String
The address for this socket.
-
#ipv4_compat ⇒ Boolean
(also: #ipv4_compat?)
When binding to an IPv6 address above, this enables
IPv4 compatibility
_. -
#named_port ⇒ String
This is only valid if :ref:
resolver_name
is specified below and the named resolver is capable of named port resolution. -
#port_value ⇒ Fixnum
Corresponds to the JSON property
portValue
. -
#protocol ⇒ String
Corresponds to the JSON property
protocol
. -
#resolver_name ⇒ String
The name of the custom resolver.
Instance Method Summary collapse
-
#initialize(**args) ⇒ SocketAddress
constructor
A new instance of SocketAddress.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ SocketAddress
Returns a new instance of SocketAddress.
1068 1069 1070 |
# File 'generated/google/apis/trafficdirector_v2/classes.rb', line 1068 def initialize(**args) update!(**args) end |
Instance Attribute Details
#address ⇒ String
The address for this socket. :ref:Listeners
will bind to the address. An
empty address is not allowed. Specify 0.0.0.0
or ::
to bind to any
address. [#comment:TODO(zuercher) reinstate when implemented: It is possible
to distinguish a Listener address via the prefix/suffix matching in :ref:
FilterChainMatch
.] When used within an upstream :ref:BindConfig
, the
address controls the source address of outbound connections. For :ref:
clusters
, the cluster type determines whether the address must be an IP (*
STATIC* or EDS clusters) or a hostname resolved by DNS (STRICT_DNS or *
LOGICAL_DNS* clusters). Address resolution can be customized via :ref:
resolver_name
.
Corresponds to the JSON property address
1033 1034 1035 |
# File 'generated/google/apis/trafficdirector_v2/classes.rb', line 1033 def address @address end |
#ipv4_compat ⇒ Boolean Also known as: ipv4_compat?
When binding to an IPv6 address above, this enables IPv4 compatibility
_.
Binding to ::
will allow both IPv4 and IPv6 connections, with peer IPv4
addresses mapped into IPv6 space as ::FFFF:
.
Corresponds to the JSON property ipv4Compat
1040 1041 1042 |
# File 'generated/google/apis/trafficdirector_v2/classes.rb', line 1040 def ipv4_compat @ipv4_compat end |
#named_port ⇒ String
This is only valid if :ref:resolver_name
is specified below and the named
resolver is capable of named port resolution.
Corresponds to the JSON property namedPort
1047 1048 1049 |
# File 'generated/google/apis/trafficdirector_v2/classes.rb', line 1047 def named_port @named_port end |
#port_value ⇒ Fixnum
Corresponds to the JSON property portValue
1052 1053 1054 |
# File 'generated/google/apis/trafficdirector_v2/classes.rb', line 1052 def port_value @port_value end |
#protocol ⇒ String
Corresponds to the JSON property protocol
1057 1058 1059 |
# File 'generated/google/apis/trafficdirector_v2/classes.rb', line 1057 def protocol @protocol end |
#resolver_name ⇒ String
The name of the custom resolver. This must have been registered with Envoy. If
this is empty, a context dependent default applies. If the address is a
concrete IP address, no resolution will occur. If address is a hostname this
should be set for resolution other than DNS. Specifying a custom resolver with
STRICT_DNS or LOGICAL_DNS will generate an error at runtime.
Corresponds to the JSON property resolverName
1066 1067 1068 |
# File 'generated/google/apis/trafficdirector_v2/classes.rb', line 1066 def resolver_name @resolver_name end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1073 1074 1075 1076 1077 1078 1079 1080 |
# File 'generated/google/apis/trafficdirector_v2/classes.rb', line 1073 def update!(**args) @address = args[:address] if args.key?(:address) @ipv4_compat = args[:ipv4_compat] if args.key?(:ipv4_compat) @named_port = args[:named_port] if args.key?(:named_port) @port_value = args[:port_value] if args.key?(:port_value) @protocol = args[:protocol] if args.key?(:protocol) @resolver_name = args[:resolver_name] if args.key?(:resolver_name) end |