Class RemoteConnectionStrategy

java.lang.Object
org.elasticsearch.transport.RemoteConnectionStrategy
All Implemented Interfaces:
Closeable, AutoCloseable, TransportConnectionListener
Direct Known Subclasses:
ProxyConnectionStrategy, SniffConnectionStrategy

public abstract class RemoteConnectionStrategy extends Object implements TransportConnectionListener, Closeable
  • Field Details

    • logger

      protected final org.apache.logging.log4j.Logger logger
    • transportService

      protected final TransportService transportService
    • connectionManager

      protected final RemoteConnectionManager connectionManager
    • originProjectId

      protected final ProjectId originProjectId
    • linkedProjectId

      protected final ProjectId linkedProjectId
    • clusterAlias

      protected final String clusterAlias
  • Method Details

    • strategyMustBeRebuilt

      protected abstract boolean strategyMustBeRebuilt(LinkedProjectConfig config)
    • strategyType

      protected abstract org.elasticsearch.transport.RemoteConnectionStrategy.ConnectionStrategy strategyType()
    • addStrategySpecificConnectionErrorMetricAttributes

      protected void addStrategySpecificConnectionErrorMetricAttributes(Map<String,Object> attributesMap)
      Add strategy-specific attributes for a new connection error metric record. The default implementation is a no-op.
    • onNodeDisconnected

      public void onNodeDisconnected(DiscoveryNode node, @Nullable Exception closeException)
      Description copied from interface: TransportConnectionListener
      Called once a node connection is closed and unregistered.
      Specified by:
      onNodeDisconnected in interface TransportConnectionListener
    • close

      public void close()
      Specified by:
      close in interface AutoCloseable
      Specified by:
      close in interface Closeable
    • isClosed

      public boolean isClosed()
    • shouldOpenMoreConnections

      protected abstract boolean shouldOpenMoreConnections()
    • connectImpl

      protected abstract void connectImpl(ActionListener<Void> listener)
    • getModeInfo

      protected abstract RemoteConnectionInfo.ModeInfo getModeInfo()
    • isRetryableException

      protected static boolean isRetryableException(Exception e)