cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Freeman Fang (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CXF-4878) Avoid trying to register Jetty MBean if already registered to avoid very ugly WARN with stacktrace
Date Wed, 11 Sep 2013 10:16:52 GMT

    [ https://issues.apache.org/jira/browse/CXF-4878?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13764182#comment-13764182
] 

Freeman Fang commented on CXF-4878:
-----------------------------------

Found that we can't workaround on CXF side, as some jetty class like org.eclipse.jetty.server.handler.ContextHandler
also has similar issue. need fixed in org.eclipse.jetty.jmx.MBeanContainer anyway.
so we wait for jetty community.
                
> Avoid trying to register Jetty MBean if already registered to avoid very ugly WARN with
stacktrace
> --------------------------------------------------------------------------------------------------
>
>                 Key: CXF-4878
>                 URL: https://issues.apache.org/jira/browse/CXF-4878
>             Project: CXF
>          Issue Type: Improvement
>          Components: Core
>    Affects Versions: 2.7.3
>            Reporter: Claus Ibsen
>            Assignee: Freeman Fang
>            Priority: Minor
>
> Running som OSGi Karaf + Camel + CXF tests and noticed these ugly warns
> {code}
> 2013-03-06 15:27:09,958 | WARN  | rint Extender: 1 | MBeanContainer                 
 | eclipse.jetty.jmx.MBeanContainer  305 | 94 - org.eclipse.jetty.util - 7.6.8.v20121106 |
bean: org.apache.cxf.transport.http_jetty.JettyHTTPHandler@42882b9d
> javax.management.InstanceAlreadyExistsException: org.apache.cxf.transport.http_jetty:type=jettyhttphandler,id=0
> 	at com.sun.jmx.mbeanserver.Repository.addMBean(Repository.java:437)[:1.7.0_13]
> 	at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerWithRepository(DefaultMBeanServerInterceptor.java:1898)[:1.7.0_13]
> 	at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerDynamicMBean(DefaultMBeanServerInterceptor.java:966)[:1.7.0_13]
> 	at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerObject(DefaultMBeanServerInterceptor.java:900)[:1.7.0_13]
> 	at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerMBean(DefaultMBeanServerInterceptor.java:324)[:1.7.0_13]
> 	at com.sun.jmx.mbeanserver.JmxMBeanServer.registerMBean(JmxMBeanServer.java:512)[:1.7.0_13]
> 	at org.eclipse.jetty.jmx.MBeanContainer.addBean(MBeanContainer.java:298)[99:org.eclipse.jetty.jmx:7.6.8.v20121106]
> 	at org.eclipse.jetty.util.component.Container.addBean(Container.java:182)[94:org.eclipse.jetty.util:7.6.8.v20121106]
> 	at org.eclipse.jetty.server.handler.AbstractHandler.setServer(AbstractHandler.java:80)[100:org.eclipse.jetty.server:7.6.8.v20121106]
> 	at org.eclipse.jetty.server.handler.HandlerWrapper.setServer(HandlerWrapper.java:136)[100:org.eclipse.jetty.server:7.6.8.v20121106]
> 	at org.eclipse.jetty.server.handler.ContextHandler.setServer(ContextHandler.java:249)[100:org.eclipse.jetty.server:7.6.8.v20121106]
> 	at org.eclipse.jetty.server.handler.HandlerCollection.setHandlers(HandlerCollection.java:90)[100:org.eclipse.jetty.server:7.6.8.v20121106]
> 	at org.eclipse.jetty.server.handler.ContextHandlerCollection.setHandlers(ContextHandlerCollection.java:162)[100:org.eclipse.jetty.server:7.6.8.v20121106]
> 	at org.eclipse.jetty.server.handler.HandlerCollection.addHandler(HandlerCollection.java:282)[100:org.eclipse.jetty.server:7.6.8.v20121106]
> 	at org.apache.cxf.transport.http_jetty.JettyHTTPServerEngine.addServant(JettyHTTPServerEngine.java:432)[139:org.apache.cxf.cxf-rt-transports-http-jetty:2.7.3]
> 	at org.apache.cxf.transport.http_jetty.JettyHTTPDestination.activate(JettyHTTPDestination.java:179)[139:org.apache.cxf.cxf-rt-transports-http-jetty:2.7.3]
> 	at org.apache.cxf.transport.AbstractObservable.setMessageObserver(AbstractObservable.java:48)[113:org.apache.cxf.cxf-api:2.7.3]
> 	at org.apache.cxf.binding.AbstractBaseBindingFactory.addListener(AbstractBaseBindingFactory.java:95)[113:org.apache.cxf.cxf-api:2.7.3]
> 	at org.apache.cxf.endpoint.ServerImpl.start(ServerImpl.java:131)[113:org.apache.cxf.cxf-api:2.7.3]
> 	at org.apache.camel.component.cxf.jaxrs.CxfRsConsumer.doStart(CxfRsConsumer.java:44)[170:org.apache.camel.camel-cxf:2.11.0.SNAPSHOT]
> 	at org.apache.camel.support.ServiceSupport.start(ServiceSupport.java:60)[68:org.apache.camel.camel-core:2.11.0.SNAPSHOT]
> {code}
> You can see them on the console when running this test from Apache Camel
> {code}
> camel/tests/camel-itest-osgi$ mvn clean test -Dtest=CxfRsBlueprintRouterTest
> {code}
> Wonder if there is a way to check if the mbean is already registered and avoid the WARN
logs.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message