Package org.jgroups.protocols
package org.jgroups.protocols
Provides implementations of transport protocols which are
responsible for sending and receiving messages to/from the network.
-
ClassDescriptionBundler implementation which sends message batches (or single messages) as soon as the target destination changes (or max_bundler_size would be exceeded).Encrypts and decrypts communication in JGroups by using a secret key distributed to all cluster members by the key server (coordinator) using asymmetric (public/private key) encryption.
The secret key is identical for all cluster members and is used to encrypt messages when sending and decrypt them when receiving messages.Simple and stupid async version of NoBundler.The AUTH protocol adds a layer of authentication to JGroups.AuthHeader is a holder object for the token that is passed from the joiner to the coordinatorAll messages up the stack have to go through a barrier (read lock, RL).Implements storing of messages in a hashmap and sending of single messages and message batches.Shared base class for TCP protocolsBatches messages near the top of the stack.Batches messages near the top of the stack.Bundler based onBATCH.Broadcast PING.Pluggable way to collect messages and send them as batchesDeprecated.See http://belaban.blogspot.com/2020/11/i-hate-distributed-locks.html.Deprecated.See http://belaban.blogspot.com/2020/11/i-hate-distributed-locks.html.Sample implementation ofSSL_KEY_EXCHANGE.SessionVerifierProtocol which clears a set of flags in the down or up direction for all messagesCompresses the payload of a message.Protocol which is used byCounterServiceto provide a distributed atomic counterCOUNTER.UpdateFunctionRequest<T extends Streamable>COUNTER.UpdateFunctionResponse<T extends Streamable>COUNTER.UpdateResult<T extends Streamable>Implementation of daisy chaining.Delays incoming/outgoing messages by a random number of milliseconds (range between 0 and n where n is determined by the user) and nanoseconds (constant amount).Detects unicast loopbacks: messages where dest == local addressKey exchange based on Diffie-Hellman-Merkle (https://en.wikipedia.org/wiki/Diffie%E2%80%93Hellman_key_exchange).Discards up or down messages based on a percentage; e.g., setting property 'up' to 0.1 causes 10% of all up messages to be discarded.Discards a message whose sequence number (in the payload, as a Long) matches seqno 2 times, before passing it down.The Discovery protocol retrieves the initial membership (used by GMS and MERGE3) by sending discovery requests.Protocol which drops up or down messages according to user-defined filtersDuplicates outgoing or incoming messages by copying themEncrypt<E extends KeyStore.Entry>Super class of symmetric (SYM_ENCRYPT) and asymmetric (ASYM_ENCRYPT) encryption protocols.Example of a protocol layer.Header used by various flow control protocolsFailure detection based on simple heartbeat protocol.Failure detection based on simple heartbeat protocol.Failure detection based on simple heartbeat protocol.Failure detection protocol which detects the crash or hanging of entire hosts and suspects all cluster members on those hosts.Command used to check whether a given host is alive, periodically calledFailure detection protocol based on sockets.Handles a client connection; multiple client can connect at the same timeFailure detection protocol based on TCP connections, successor toFD_SOCK.Simple discovery protocol which uses a file on shared storage such as an SMB share, NFS mount or S3.Simple flow control protocol based on a credit system.The FORK protocol; multiplexes messages to different forks in a stack (https://issues.redhat.com/browse/JGRP-1613).Fragmentation layer.A fragmentation list keeps a list of fragmentation tables sorted by an Address ( the sender ).Keeps track of the fragments that are received.inner class represents an entry for a message each entry holds an array of byte arrays sorted once all the byte buffer entries have been filled the fragmentation is considered complete.Fragmentation layer.Class represents an entry for a message.Fragmentation protocol which uses less memory to store fragments thanFRAG2.Fragmentation layer.Base class for all fragmentation protocols.Prints the headers of all sent or received messagesSimple protocol to inject an arbitrary view on one or more cluster nodes.Discovery protocol using a JDBC connection to a shared database.New version ofJDBC_PING.Base class for protocols implementing key exchange: a secret key to be used for encryption is exchanged between 2 parties (usually the key server and a new cluster member) securely; ie.Discovery protocol for finding members in the local process only.A local transport is used for sending messages only to single (or all) members of the same host.Deprecated.See http://belaban.blogspot.com/2020/11/i-hate-distributed-locks.html.A response to a request, to be sent back to the requester as a messageIntercepts individual up messages and creates batches from them, passing the batches up.Protocol to discover subgroups; e.g., existing due to a network partition (that healed).Simple flow control protocol based on a credit system.Non-blocking alternative toMFC.Uses its own IP multicast socket to send and receive discovery requests/responses.Class which has all the stats about received/sent messages etc.Bundler which doesn't bundle :-) Can be used to measure the diff between bundling and non-bundling (e.g.Detects sends during processing of incoming messages and sets flagMessage.TransientFlag.DONT_BLOCKto prevent blocking the incoming thread on a send.Persistent Discovery Cache.Queues messages per destination ('null' is a special destination), sending when the last sender thread to the same destination returns or max_size has been reached.Protocol measuring latency between stacks.The PING protocol retrieves the initial membership by mcasting a discovery request (via the multicast capable transport) to all current cluster membersEncapsulates information about a cluster node, e.g.Used to send discovery requests and responsesDiscovery protocol based on Rackspace Cloud Files storage solutionA thread safe Rackspace ReST clientMeasures incoming and outgoing rates: messages/sec, bytes/sec.Protocol which sends at most max_bytes in time_period milliseconds.Rate limiter based credits (max_bytes).Implementation of Random Early Drop: messages are discarded when the bundler's queue in the transport nears exhaustion.Bundler implementation which sends message batches (or single messages) as soon as the remove queue is full (or max_bundler_size would be exceeded).Reverses the next N messages that are received.Bundler which usesRingBufferto store messages.Bundler which doesn't use locks but relies on CAS.Lockless bundler using a reader thread which is unparked by (exactly one) writer thread.Protocol which implements synchronous messages (https://issues.redhat.com/browse/JGRP-1389).Header to measure round-trip times (in nanoseconds) for sync RPCs (https://issues.redhat.com/browse/JGRP-2604)Implementation of total order protocol using a sequencer.Implementation of total order protocol using a sequencer_uum.Serializes the entire message (including payload, headers, flags and destination and src) into the payload of another message that's then sent.Loopback transport shared by all channels within the same VM.Discovery protocol running overSHARED_LOOPBACKonly.Reorders messages by buffering them and shuffling the result after TIMEOUT ms.Bare-bones thread-per-connection TCP-based transport.This bundler uses the same logic asTransferQueueBundlerbut does not allocate memory except for the buffer itself and does not use complex data structures.Protocol which prints out the real size of a message.Protocol trying to print message payloads as stringsPeriodically fetches some attributes and writes them to a file (https://issues.redhat.com/browse/JGRP-2402)Key exchange based on SSL sockets.Provides various statsProtocol which provides STOMP (https://stomp.github.io/) support.Discovery protocol based on Openstack Swift (object storage).Supported Swift authentication providersContract for Swift authentication providersBuild HttpURLConnections with adequate headers and methodResult of a successfully authenticated sessionResponse for a Swift API callOpenstack Keytsone v2.0 authentication provider.A thread safe Swift clientEncrypts and decrypts communication in JGroups by using a secret key shared by all cluster members.TCP based protocol.Protocol using TCP/IP to send and receive messages.The TCPGOSSIP protocol layer retrieves the initial membership (used by GMS when started by sending event FIND_INITIAL_MBRS down the stack).The TCPPING protocol defines a static cluster membership.Maintains averages of up- and down-threadsProtocol measuring delivery times.Generic transport - specific implementations should extend this abstract class.Generic transport header, used by TP.This bundler adds all (unicast or multicast) messages to a queue until max size has been exceeded, but does send messages immediately when no other messages are available.This bundler adds all (unicast or multicast) messages to a queue until max size has been exceeded, but does send messages immediately when no other messages are available.Replacement for UDP.IP multicast transport based on UDP.Simple flow control protocol based on a credit system.Non-blocking alternative toUFC.InterceptsProtocol.up(MessageBatch)and passes up each message of a message batch as a single message.Reliable unicast protocol using a combination of positive and negative acks.Moved out ofUNICAST3into separate class.Catches SUSPECT events traveling up the stack.Double-checks that a suspected member is really dead.