public class CommunicationTcpUtils extends Object
| Modifier and Type | Field and Description |
|---|---|
static IgniteRunnable |
NOOP
No-op runnable.
|
| Constructor and Description |
|---|
CommunicationTcpUtils() |
| Modifier and Type | Method and Description |
|---|---|
static void |
failNode(ClusterNode nodeToFail,
IgniteSpiContext spiCtx,
Throwable err,
IgniteLogger log)
Forcibly fails client node.
|
static IgniteSpiOperationTimeoutException |
handshakeTimeoutException()
Returns handshake exception with specific message.
|
static boolean |
isRecoverableException(Throwable errs) |
static Collection<InetSocketAddress> |
nodeAddresses(ClusterNode node,
boolean filterReachableAddrs,
AttributeNames attrs,
Supplier<ClusterNode> localNode) |
static boolean |
usePairedConnections(ClusterNode node,
String attributeName) |
static void |
writeMessageType(OutputStream os,
short type)
Write message type to output stream.
|
public static final IgniteRunnable NOOP
public static boolean usePairedConnections(ClusterNode node, String attributeName)
node - Node.True if can use in/out connection pair for communication.public static void writeMessageType(OutputStream os, short type) throws IOException
os - Output stream.type - Message type.IOException - On error.public static Collection<InetSocketAddress> nodeAddresses(ClusterNode node, boolean filterReachableAddrs, AttributeNames attrs, Supplier<ClusterNode> localNode) throws IgniteCheckedException
node - Node.filterReachableAddrs - Filter addresses flag.IgniteCheckedException - If node does not have addresses.public static IgniteSpiOperationTimeoutException handshakeTimeoutException()
public static boolean isRecoverableException(Throwable errs)
errs - Error.True if error was caused by some connection IO error or IgniteCheckedException due to timeout.public static void failNode(ClusterNode nodeToFail, IgniteSpiContext spiCtx, Throwable err, IgniteLogger log)
nodeToFail - Client node to forcible fail.spiCtx - Context to request node failing.err - Error to fail client with.log - Logger to print message about failed node to.
Follow @ApacheIgnite
Ignite Database and Caching Platform : ver. 2.15.0 Release Date : April 25 2023