public static class ProxyProtocolClientConnectionFactory.V2.Tag extends Object implements ClientConnectionFactory.Decorator
PROXY protocol version 2 metadata holder to be used in conjunction
with Request.tag(Object).
Instances of this class are associated to a destination so that all connections of that destination will initiate the communication with the PROXY protocol version 2 bytes specified by this metadata.
| Modifier and Type | Class and Description |
|---|---|
static class |
ProxyProtocolClientConnectionFactory.V2.Tag.Command |
static class |
ProxyProtocolClientConnectionFactory.V2.Tag.Family |
static class |
ProxyProtocolClientConnectionFactory.V2.Tag.Protocol |
static class |
ProxyProtocolClientConnectionFactory.V2.Tag.TLV |
| Modifier and Type | Field and Description |
|---|---|
static ProxyProtocolClientConnectionFactory.V2.Tag |
LOCAL
The PROXY V2 Tag typically used to "ping" the server.
|
| Constructor and Description |
|---|
Tag()
Creates a Tag whose metadata will be derived from the underlying EndPoint.
|
Tag(ProxyProtocolClientConnectionFactory.V2.Tag.Command command,
ProxyProtocolClientConnectionFactory.V2.Tag.Family family,
ProxyProtocolClientConnectionFactory.V2.Tag.Protocol protocol,
String srcIP,
int srcPort,
String dstIP,
int dstPort,
List<ProxyProtocolClientConnectionFactory.V2.Tag.TLV> tlvs)
Creates a Tag with the given metadata.
|
Tag(String srcIP,
int srcPort)
Creates a Tag with the given source metadata.
|
Tag(String srcIP,
int srcPort,
List<ProxyProtocolClientConnectionFactory.V2.Tag.TLV> tlvs)
Creates a Tag with the given source metadata and Type-Length-Value (TLV) objects.
|
| Modifier and Type | Method and Description |
|---|---|
ClientConnectionFactory |
apply(ClientConnectionFactory factory)
Wraps the given
factory. |
boolean |
equals(Object obj) |
ProxyProtocolClientConnectionFactory.V2.Tag.Command |
getCommand() |
String |
getDestinationAddress() |
int |
getDestinationPort() |
ProxyProtocolClientConnectionFactory.V2.Tag.Family |
getFamily() |
ProxyProtocolClientConnectionFactory.V2.Tag.Protocol |
getProtocol() |
String |
getSourceAddress() |
int |
getSourcePort() |
List<ProxyProtocolClientConnectionFactory.V2.Tag.TLV> |
getTLVs() |
int |
hashCode() |
public static final ProxyProtocolClientConnectionFactory.V2.Tag LOCAL
public Tag()
Creates a Tag whose metadata will be derived from the underlying EndPoint.
public Tag(String srcIP, int srcPort)
Creates a Tag with the given source metadata.
The destination metadata will be derived from the underlying EndPoint.
srcIP - the source IP addresssrcPort - the source portpublic Tag(String srcIP, int srcPort, List<ProxyProtocolClientConnectionFactory.V2.Tag.TLV> tlvs)
Creates a Tag with the given source metadata and Type-Length-Value (TLV) objects.
The destination metadata will be derived from the underlying EndPoint.
srcIP - the source IP addresssrcPort - the source porttlvs - the TLV objectspublic Tag(ProxyProtocolClientConnectionFactory.V2.Tag.Command command, ProxyProtocolClientConnectionFactory.V2.Tag.Family family, ProxyProtocolClientConnectionFactory.V2.Tag.Protocol protocol, String srcIP, int srcPort, String dstIP, int dstPort, List<ProxyProtocolClientConnectionFactory.V2.Tag.TLV> tlvs)
Creates a Tag with the given metadata.
command - the LOCAL or PROXY commandfamily - the protocol familyprotocol - the protocol typesrcIP - the source IP addresssrcPort - the source portdstIP - the destination IP addressdstPort - the destination porttlvs - the TLV objectspublic ProxyProtocolClientConnectionFactory.V2.Tag.Command getCommand()
public ProxyProtocolClientConnectionFactory.V2.Tag.Family getFamily()
public ProxyProtocolClientConnectionFactory.V2.Tag.Protocol getProtocol()
public String getSourceAddress()
public int getSourcePort()
public String getDestinationAddress()
public int getDestinationPort()
public List<ProxyProtocolClientConnectionFactory.V2.Tag.TLV> getTLVs()
public ClientConnectionFactory apply(ClientConnectionFactory factory)
ClientConnectionFactory.DecoratorWraps the given factory.
apply in interface ClientConnectionFactory.Decoratorfactory - the ClientConnectionFactory to wrapCopyright © 2010 - 2020 Adobe. All Rights Reserved