You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by JVD <ja...@synchronoss.com> on 2015/06/26 21:39:13 UTC

class org.apache.camel.management.mbean.ManagedService is not a JMX compliant MXBean

Good day -

I am trying to port a production server's test suite to use ActiveMQ
(5.7.0.fuse-71-047) ,  where the
production server normally uses a licensed copy of SwiftMQ-HA ,  with 
apache-camel-2.9.0.fuse-7-061 and  
Spring Framework ( 3.1.2-RELEASE ) - us developers do not get access to
SwiftMQ-HA licenses.  
These versions cannot be changed easily .

Previously the test suite used to fake sending JMS messages with a mock, but
this is
now no longer possible - it must receive real JMS messages and send them. 
  
I have got the server to include the camel-amqp jar and dependencies in its
classpath ,
and modified its Camel configuration to use 'amqp:' prefixed URIs instead of
'swiftmq:'
preifixed URIs - that is the only change I've made to the Camel
configuration.

Now I am getting this exception during Spring initialization, but because it
is caught, 
Spring initialization never terminates - ie. the call to
'ClassPathXmlApplicationContext("myAppContext.xml")
never returns - the complete exception text is:

"javax.management.NotCompliantMBeanException: MBean class
org.apache.camel.management.mbean.ManagedService does not implement
DynamicMBean, neither follows the Standard MBean conventions
(javax.management.NotCompliantMBeanException: Class
org.apache.camel.management.mbean.ManagedService is not a JMX compliant
Standard MBean) nor the MXBean conventions
(javax.management.NotCompliantMBeanException:
org.apache.camel.management.mbean.ManagedService: Class
org.apache.camel.management.mbean.ManagedService is not a JMX compliant
MXBean).
"

The main thread is stuck in this stack frame and never leaves it :

"main@1" prio=5 tid=0x1 nid=NA runnable
  java.lang.Thread.State: RUNNABLE
	  at
org.apache.camel.management.DefaultManagementAgent.register(DefaultManagementAgent.java:235)
	  at
org.apache.camel.management.DefaultManagementAgent.register(DefaultManagementAgent.java:227)
	  at
org.apache.camel.management.ManagedManagementStrategy.manageNamedObject(ManagedManagementStrategy.java:73)
	  at
org.apache.camel.management.ManagedManagementStrategy.manageObject(ManagedManagementStrategy.java:66)
	  at
org.apache.camel.management.DefaultManagementLifecycleStrategy.manageObject(DefaultManagementLifecycleStrategy.java:755)
	  at
org.apache.camel.management.DefaultManagementLifecycleStrategy.onServiceAdd(DefaultManagementLifecycleStrategy.java:363)
	  at
org.apache.camel.impl.DefaultCamelContext.addService(DefaultCamelContext.java:887)
	  at
org.apache.camel.impl.DefaultCamelContext.doStartCamel(DefaultCamelContext.java:1513)
	  at
org.apache.camel.impl.DefaultCamelContext.doStart(DefaultCamelContext.java:1413)
	  - locked <0x15f4> (a org.apache.camel.spring.SpringCamelContext)
	  at
org.apache.camel.spring.SpringCamelContext.doStart(SpringCamelContext.java:181)
	  at org.apache.camel.support.ServiceSupport.start(ServiceSupport.java:60)
	  at
org.apache.camel.impl.DefaultCamelContext.start(DefaultCamelContext.java:1381)
	  at
org.apache.camel.spring.SpringCamelContext.maybeStart(SpringCamelContext.java:230)
	  at
org.apache.camel.spring.SpringCamelContext.onApplicationEvent(SpringCamelContext.java:120)
	  at
org.apache.camel.spring.CamelContextFactoryBean.onApplicationEvent(CamelContextFactoryBean.java:242)
	  at
org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:97)
	  at
org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:324)
	  at
org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:934)
	  at
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:472)
	  - locked <0x16bd> (a java.lang.Object)
          at
org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:139)

It is obviously trying to register the management agent , but this gets the 
indicated exception, which is caught, and
the process is repeated ad infinitum.

As the thread is entirely within Spring + Camel code I'm a bit stumped as to
what to do about this .

Any ideas about how to workaround this problem with current Spring, Camel
and ActiveMQ versions given above would be 
much appreciated .

Why isn't the org.apache.camel.management.mbean.ManagedService  a JMX
compliant MXBean ?

Any responses gratefully received.

Thanks & Regards,
Jason



--
View this message in context: http://camel.465427.n5.nabble.com/class-org-apache-camel-management-mbean-ManagedService-is-not-a-JMX-compliant-MXBean-tp5768604.html
Sent from the Camel - Users mailing list archive at Nabble.com.