public interface EndPoint
By default, the driver assumes plain TCP connections, and this is just a wrapper around an
InetSocketAddress
. However, more complex deployment scenarios might use a custom
implementation that contains additional information; for example, if the nodes are accessed
through a proxy with SNI routing, an SNI server name is needed in addition to the proxy address.
Modifier and Type | Method and Description |
---|---|
String |
asMetricPrefix()
Returns an alternate string representation for use in node-level metric names.
|
SocketAddress |
resolve()
Resolves this instance to a socket address.
|
@NonNull SocketAddress resolve()
This will be called each time the driver opens a new connection to the node. The returned address cannot be null.
@NonNull String asMetricPrefix()
Because metrics names are path-like, dot-separated strings, raw IP addresses don't make very
good identifiers. So this method will typically replace the dots by another character, for
example 127_0_0_1_9042
.
Copyright © 2017–2024. All rights reserved.