Class FailoverLoomClient

java.lang.Object
com.loomcache.client.FailoverLoomClient
All Implemented Interfaces:
AutoCloseable

public final class FailoverLoomClient extends Object implements AutoCloseable
Blue/green failover wrapper that connects to one configured cluster at a time.
  • Constructor Details

  • Method Details

    • connect

      public static FailoverLoomClient connect(ClientFailoverConfig config)
    • connect

      public void connect()
      Connect to the first reachable configured client cluster.
    • failover

      public void failover()
      Close the active client and roll to the next reachable configured cluster.
    • currentClient

      public LoomClient currentClient()
    • currentConfigIndex

      public int currentConfigIndex()
    • isConnected

      public boolean isConnected()
    • connectedNodeCount

      public int connectedNodeCount()
    • asCache

      public LoomCache asCache()
    • addLifecycleListener

      public FailoverLoomClient addLifecycleListener(LifecycleListener listener)
    • removeLifecycleListener

      public boolean removeLifecycleListener(LifecycleListener listener)
    • close

      public void close()
      Specified by:
      close in interface AutoCloseable