Ok, the issue is that Jetty is not using a simple MBean, its using a ModelMBean
which is a more dynamic entity that does not expose its methods statically.
Therefore the MBeanServer has to pass the method invocation onto the bean
to see if its implemented, and in this case it is not.
The stack trace is coming from the Jetty ModelMBeanImpl class, not JBoss's
ServiceControl. Although annoying, this is just a cosmetic exception. To clean
this up we could add a notification filter attribute to the ServiceControl mbean
that allowed one to control which mbeans registeration notifications so that in
a Jetty configuration its non-service mbeans could be excluded. This will require
use of a naming convention. I'll send out an example filter later.
>
> Hey,
>
>
> > There shouldn't even be a log msg about the missing method since if you invoke a
> > method that does not exist on an MBean you will get a ReflectionException and
> > these are simply ignored. All MBeans show up on the management page because
> > this page is about MBeans and cares nothing about service abstractions.
> >
>
> Scott, that is what I thought too. But how is he getting this stacktrace:
>
> [Jetty]
> java.lang.NoSuchMethodException: init()
> at com.mortbay.Jetty.JMX.ModelMBeanImpl.invoke(ModelMBeanImpl.java)
> at
> com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1555)
> at
> com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)
> at org.jboss.util.ServiceControl.init(ServiceControl.java:59)
> at java.lang.reflect.Method.invoke(Native Method)
> at
> com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628)
> at
> com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)
> at org.jboss.Main.<init>(Main.java:202)
> at org.jboss.Main$1.run(Main.java:107)
> at java.security.AccessController.doPrivileged(Native Method)
> at org.jboss.Main.main(Main.java:103)
>
_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-development