Class PublicationTransportHandler.PublicationContext

java.lang.Object
org.elasticsearch.core.AbstractRefCounted
org.elasticsearch.cluster.coordination.PublicationTransportHandler.PublicationContext
All Implemented Interfaces:
org.elasticsearch.core.RefCounted
Enclosing class:
PublicationTransportHandler

public class PublicationTransportHandler.PublicationContext extends org.elasticsearch.core.AbstractRefCounted
Publishing a cluster state typically involves sending the same cluster state (or diff) to every node, so the work of diffing, serializing, and compressing the state can be done once and the results shared across publish requests. The PublicationContext implements this sharing. It's ref-counted: the initial reference is released by the coordinator when a state (or diff) has been sent to every node, every transmitted diff also holds a reference in case it needs to retry with a full state.