Examples of MBeanServerInterceptor


Examples of mx4j.server.interceptor.MBeanServerInterceptor

      }
   }

   private MBeanServerInterceptor getHeadInterceptor()
   {
      MBeanServerInterceptor head = invoker.getHeadInterceptor();

      if (head == null) throw new IllegalStateException("No MBeanServer interceptor, probably the configurator has been stopped");

      return head;
   }
View Full Code Here

Examples of mx4j.server.interceptor.MBeanServerInterceptor

   {
      introspector.introspect(metadata);

      if (!introspector.isMBeanCompliant(metadata)) throw new NotCompliantMBeanException("MBean is not compliant");

      MBeanServerInterceptor head = getHeadInterceptor();

      head.registration(metadata, MBeanServerInterceptor.PRE_REGISTER);

      // The MBean implementor could have replaced the ObjectName with a subclass that is not secure, secure it again
      metadata.setObjectName(secureObjectName(metadata.getObjectName()));

      int postRegisterFlag = MBeanServerInterceptor.POST_REGISTER_FALSE;
      try
      {
         register(metadata, privileged);
         postRegisterFlag = MBeanServerInterceptor.POST_REGISTER_TRUE;
      }
      finally
      {
         head.registration(metadata, postRegisterFlag);
      }

      Object mbean = metadata.getMBean();
      if (mbean instanceof ClassLoader && !(mbean instanceof PrivateClassLoader))
      {
View Full Code Here

Examples of mx4j.server.interceptor.MBeanServerInterceptor

         throw new RuntimeOperationsException(new IllegalArgumentException("Domain 'JMImplementation' is reserved for the JMX Agent"));
      }

      MBeanMetaData metadata = findMBeanMetaData(objectName);

      MBeanServerInterceptor head = getHeadInterceptor();
      head.registration(metadata, MBeanServerInterceptor.PRE_DEREGISTER);
      unregister(metadata);

      getHeadInterceptor().registration(metadata, MBeanServerInterceptor.POST_DEREGISTER);

      Object mbean = metadata.getMBean();
View Full Code Here

Examples of org.apache.felix.mosgi.jmx.agent.mx4j.server.interceptor.MBeanServerInterceptor

      }
   }

   private MBeanServerInterceptor getHeadInterceptor()
   {
      MBeanServerInterceptor head = invoker.getHeadInterceptor();

      if (head == null) throw new IllegalStateException("No MBeanServer interceptor, probably the configurator has been stopped");

      return head;
   }
View Full Code Here

Examples of org.apache.felix.mosgi.jmx.agent.mx4j.server.interceptor.MBeanServerInterceptor

   {
      introspector.introspect(metadata);

      if (!introspector.isMBeanCompliant(metadata)) throw new NotCompliantMBeanException("MBean is not compliant");

      MBeanServerInterceptor head = getHeadInterceptor();

      try
      {
         // With this call, the MBean implementor can replace the ObjectName with a subclass that is not secure, secure it again
         head.registration(metadata, MBeanServerInterceptor.PRE_REGISTER);
         metadata.name = secureObjectName(metadata.name);

         metadata.instance = new ObjectInstance(metadata.name, metadata.info.getClassName());

         register(metadata, privileged);

         head.registration(metadata, MBeanServerInterceptor.POST_REGISTER_TRUE);
      }
      catch (Throwable x)
      {
         try
         {
            head.registration(metadata, MBeanServerInterceptor.POST_REGISTER_FALSE);
         }
         catch (MBeanRegistrationException ignored)
         {/* Ignore this one to rethrow the other one */
         }

View Full Code Here

Examples of org.apache.felix.mosgi.jmx.agent.mx4j.server.interceptor.MBeanServerInterceptor

      MBeanMetaData metadata = findMBeanMetaData(objectName);

      try
      {
         MBeanServerInterceptor head = getHeadInterceptor();
         head.registration(metadata, MBeanServerInterceptor.PRE_DEREGISTER);

         unregister(metadata);

         getHeadInterceptor().registration(metadata, MBeanServerInterceptor.POST_DEREGISTER);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.