Interface MBeanExporterWithUnregister

All Superinterfaces:
org.springframework.jmx.export.MBeanExportOperations
All Known Implementing Classes:
MBeanExporterWithUnregisterImpl

public interface MBeanExporterWithUnregister extends org.springframework.jmx.export.MBeanExportOperations
This interface has been created to allow us to perform additional necessary operations that are not provided via Spring's JMX support classes. The following operations have been added.
  • Determining whether or not this Exporter is enabled
  • The ability for the Exporter to unregister beans
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
    Setting this system property to true will prevent the exporter from registering or unregistering MBeans, and cause isEnabled() to always return false
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Determines whether or not the export is enabled.
    boolean
    Determines whether the object has been registered.
    void
    Registers the MBean with a given name.
    void
    Deprecated.
    since 5.10.

    Methods inherited from interface org.springframework.jmx.export.MBeanExportOperations

    registerManagedResource, registerManagedResource, unregisterManagedResource
  • Field Details

    • PROPERTY_NAME_JMX_DISABLED

      static final String PROPERTY_NAME_JMX_DISABLED
      Setting this system property to true will prevent the exporter from registering or unregistering MBeans, and cause isEnabled() to always return false
      See Also:
  • Method Details

    • isEnabled

      boolean isEnabled()
      Determines whether or not the export is enabled. If not enabled, the Exporter will not be able to register or unregister any MBeans. If the system property "confluence.jmx.disabled" is set to true, this method will always return false.
      Returns:
      true if enabled
    • unregisterBean

      @Deprecated void unregisterBean(ObjectName name)
      Deprecated.
      since 5.10. Use MBeanExportOperations.unregisterManagedResource(javax.management.ObjectName) instead.
      Unregistered the MBean with the given name. This means that it will no longer be managed by the JMX agent.
      Parameters:
      name - of the resource to be unregistered.
    • isRegistered

      boolean isRegistered(ObjectName name)
      Determines whether the object has been registered.
      Returns:
      true if registered
    • safeRegisterManagedResource

      void safeRegisterManagedResource(Object value, ObjectName name)
      Registers the MBean with a given name. If a duplicate MBean is found the object will be overwritten and any other errors logged and swallowed.
      Parameters:
      value - - MBean object
      name - of the resource