camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "S.R." <srassok...@gmail.com>
Subject Starting Camel context causes JMX exception.
Date Sun, 06 Jul 2008 18:46:25 GMT

When Camel context is starting
javax.management.InstanceAlreadyExistsException is thrown.

This happens ONLY for 1.4.0 version AND if the route has 2 equal bean
endpoints, for example:
from("jms:queue").to("bean:testBean?methodName=test").to("bean:testBean?methodName=test")
or
from("jms:queue").to("bean:testBean").to("bean:testBean").

However, the following example doesn't cause that exception:
from("jms:queue").to("bean:testBean?methodName=test1").to("bean:testBean?methodName=test2").

Original stack trace:
WARNING: Could not register Counter MBean
javax.management.InstanceAlreadyExistsException:
org.apache.camel:context=srassokhin-pc/camelContext,route=[jms]Queue.IMB.System@-2079852353,type=processor,name="To[bean:systemReplyBean\?methodName=replyLogin]"
	at com.sun.jmx.mbeanserver.Repository.addMBean(Repository.java:453)
	at
com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.internal_addObject(DefaultMBeanServerInterceptor.java:1484)
	at
com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerDynamicMBean(DefaultMBeanServerInterceptor.java:963)
	at
com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerObject(DefaultMBeanServerInterceptor.java:917)
	at
com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerMBean(DefaultMBeanServerInterceptor.java:312)
	at
com.sun.jmx.mbeanserver.JmxMBeanServer.registerMBean(JmxMBeanServer.java:482)
	at
org.apache.camel.management.DefaultInstrumentationAgent.registerMBeanWithServer(DefaultInstrumentationAgent.java:224)
	at
org.apache.camel.management.DefaultInstrumentationAgent.register(DefaultInstrumentationAgent.java:165)
	at
org.apache.camel.management.DefaultInstrumentationAgent.register(DefaultInstrumentationAgent.java:146)
	at
org.apache.camel.management.InstrumentationLifecycleStrategy.onRouteContextCreate(InstrumentationLifecycleStrategy.java:173)
	at org.apache.camel.model.RouteType.addRoutes(RouteType.java:216)
	at org.apache.camel.model.RouteType.addRoutes(RouteType.java:90)
	at
org.apache.camel.impl.DefaultCamelContext.startRouteDefinitions(DefaultCamelContext.java:520)
	at
org.apache.camel.impl.DefaultCamelContext.doStart(DefaultCamelContext.java:512)
	at
org.apache.camel.spring.SpringCamelContext.doStart(SpringCamelContext.java:149)
	at org.apache.camel.impl.ServiceSupport.start(ServiceSupport.java:47)
	at
org.apache.camel.spring.SpringCamelContext.onApplicationEvent(SpringCamelContext.java:103)
	at
org.springframework.context.event.SimpleApplicationEventMulticaster$1.run(SimpleApplicationEventMulticaster.java:78)
	at
org.springframework.core.task.SyncTaskExecutor.execute(SyncTaskExecutor.java:49)
	at
org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:76)
	at
org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:275)
	at
org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:737)
	at
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:384)
	at
org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:139)
	at
org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:93)

Sergey

-- 
View this message in context: http://www.nabble.com/Starting-Camel-context-causes-JMX-exception.-tp18304692s22882p18304692.html
Sent from the Camel - Users mailing list archive at Nabble.com.


Mime
View raw message