How to run multiple nuxeo WARs on one Tomcat?

Hi all,

I tried on a tomcat server 7.0.61 to run multiple nuxeo 7.2 instances, built according to http://doc.nuxeo.com/x/HoeN, but errors occured during the startup of the server:

localhost-startStop-1 10:42:22,112 ERROR [RegistrationInfoImpl] Component notification of application started failed.{}
java.lang.RuntimeException: javax.management.InstanceAlreadyExistsException: org.nuxeo.automation:name=tracerfactory
        at org.nuxeo.ecm.automation.core.AutomationComponent.applicationStarted(AutomationComponent.java:219)
        at org.nuxeo.runtime.model.impl.RegistrationInfoImpl.notifyApplicationStarted(RegistrationInfoImpl.java:323)
        at org.nuxeo.runtime.osgi.OSGiRuntimeService.notifyComponentsOnStarted(OSGiRuntimeService.java:487)
        at org.nuxeo.runtime.osgi.OSGiRuntimeService.fireApplicationStarted(OSGiRuntimeService.java:523)
        at org.nuxeo.runtime.osgi.OSGiRuntimeService.frameworkEvent(OSGiRuntimeService.java:533)
        at org.nuxeo.osgi.OSGiAdapter.fireFrameworkEvent(OSGiAdapter.java:232)
        at org.nuxeo.osgi.application.loader.FrameworkLoader.doStart(FrameworkLoader.java:246)
        at org.nuxeo.osgi.application.loader.FrameworkLoader.start(FrameworkLoader.java:126)
        at org.nuxeo.runtime.deployment.NuxeoStarter.start(NuxeoStarter.java:114)
        at org.nuxeo.runtime.deployment.NuxeoStarter.contextInitialized(NuxeoStarter.java:87)
        at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:5016)
        at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5528)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
        at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
        at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
        at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:652)
        at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1258)
        at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1918)
        at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
        at java.util.concurrent.FutureTask.run(Unknown Source)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
        at java.lang.Thread.run(Unknown Source)
Caused by: javax.management.InstanceAlreadyExistsException: org.nuxeo.automation:name=tracerfactory
        at com.sun.jmx.mbeanserver.Repository.addMBean(Unknown Source)
        at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerWithRepository(Unknown Source)
        at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerDynamicMBean(Unknown Source)
        at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerObject(Unknown Source)
        at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerMBean(Unknown Source)
        at com.sun.jmx.mbeanserver.JmxMBeanServer.registerMBean(Unknown Source)
        at org.nuxeo.ecm.automation.core.AutomationComponent.bindManagement(AutomationComponent.java:95)
        at org.nuxeo.ecm.automation.core.AutomationComponent.applicationStarted(AutomationComponent.java:217)
        ... 22 more

It looks like there is a conflict between the Nuxeo instances. Is there a way to make it works please? Is there some configuration missing in the nuxeo web.xml or context.xml files? Or is it necessary to move some nuxeo libs in the $TOMCAT/lib shared classloader?

Thanks in advance

0 votes

0 answers

2334 views

ANSWER

Hi,

Could your share the whole stack trace (you can use http://pastebin.com)?

08/06/2015