Class MultiClusterJmx

java.lang.Object
org.openspaces.core.multicluster.internal.MultiClusterJmx
All Implemented Interfaces:
AutoCloseable

public final class MultiClusterJmx extends Object implements AutoCloseable
Registers a proxy's MultiClusterMXBean with the platform MBean server, and unregisters it on close.

Registration never fails the proxy. A JMX name collision or a restrictive security manager is a monitoring problem, and taking down data access because monitoring could not start would be the wrong trade - so problems are logged and the proxy carries on.

  • Method Details

    • register

      public static MultiClusterJmx register(String name, MultiClusterGigaSpace proxy, MultiClusterStats stats, Supplier<Map<String,String>> health, Supplier<MultiClusterConfig> config, Supplier<int[]> queueState)
      Exposes a proxy over JMX as org.openspaces.core.multicluster:type=MultiClusterGigaSpace,name=NAME.
      Parameters:
      name - the proxy's name, which becomes the JMX identity
      proxy - the live proxy, used for the health queries and the two operations
      stats - the counters
      health - cluster name to health state, from the health monitor
      config - the live configuration, for the policies the ticket's interface does not expose
      queueState - pending and dropped deferred mutations
      Returns:
      a handle that unregisters the bean, or null if registration failed
    • close

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