Class JMXProvider

    • Field Detail

      • JMX_INSTRUMENT_ALIASES

        public static final java.lang.String[] JMX_INSTRUMENT_ALIASES
      • MBEAN_DOMAIN

        public static final java.lang.String MBEAN_DOMAIN
        The MBean domain for OpenJPA
        See Also:
        Constant Field Values
    • Constructor Detail

      • JMXProvider

        public JMXProvider()
    • Method Detail

      • registerMBean

        protected void registerMBean​(JMXInstrument mBean)
        Register an MBean with the mbean server.
      • getMBeanServer

        public java.util.Set<javax.management.MBeanServer> getMBeanServer()
        Returns the mbean server
      • createObjectName

        public static javax.management.ObjectName createObjectName​(JMXInstrument instrument,
                                                                   java.util.Map<java.lang.String,​java.lang.String> props)
                                                            throws java.lang.Exception
        Creates an object name for the supplied instrument and key properties
        Parameters:
        instrument - the instrument
        props - additional key properties
        Returns:
        the JMX object name
        Throws:
        java.lang.Exception - a generic JMX-type exception
      • startInstrument

        public void startInstrument​(Instrument instrument)
        Start an instrument. Registers an mbean with the server.
        Parameters:
        instrument - this instrument to start
      • stopInstrument

        public void stopInstrument​(Instrument instrument,
                                   boolean force)
        Stop an instrument. Unregisters an mbean with the server.
        Parameters:
        instrument - the instrument to stop
        force - forces the stop if the instrument does not stop gracefully.