You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@servicemix.apache.org by "Ge@@ru" <ge...@gmail.com> on 2011/04/06 16:00:20 UTC
Error on use servicemix-cxf-bc as osgi bundle and with ssl
Hi, i created a bundle for use servicemix-cxf-bc module but i have this
error when i try to deploy it.
15:16:56,896 | ERROR | xtenderThread-58 | tServiceReferenceRecipe
$Listener | 7 - org.apache.aries.blueprint - 0.2.0.incubating | Error
calling listener method public void
org.apache.servicemix.common.osgi.EndpointTracker.register(org.apache.servicemix.common.osgi.EndpointWrapper,java.util.Map) throws java.lang.Exception
java.lang.reflect.InvocationTargetException
at sun.reflect.GeneratedMethodAccessor62.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)[:1.6.0_22]
at java.lang.reflect.Method.invoke(Method.java:597)[:1.6.0_22]
at
org.apache.aries.blueprint.utils.ReflectionUtils.invoke(ReflectionUtils.java:221)[7:org.apache.aries.blueprint:0.2.0.incubating]
at org.apache.aries.blueprint.container.AbstractServiceReferenceRecipe
$Listener.invokeMethods(AbstractServiceReferenceRecipe.java:553)[7:org.apache.aries.blueprint:0.2.0.incubating]
at org.apache.aries.blueprint.container.AbstractServiceReferenceRecipe
$Listener.bind(AbstractServiceReferenceRecipe.java:518)[7:org.apache.aries.blueprint:0.2.0.incubating]
at
org.apache.aries.blueprint.container.AbstractServiceReferenceRecipe.bind(AbstractServiceReferenceRecipe.java:415)[7:org.apache.aries.blueprint:0.2.0.incubating]
at
org.apache.aries.blueprint.container.ReferenceListRecipe.track(ReferenceListRecipe.java:135)[7:org.apache.aries.blueprint:0.2.0.incubating]
at
org.apache.aries.blueprint.container.AbstractServiceReferenceRecipe.serviceAdded(AbstractServiceReferenceRecipe.java:365)[7:org.apache.aries.blueprint:0.2.0.incubating]
at
org.apache.aries.blueprint.container.AbstractServiceReferenceRecipe.serviceChanged(AbstractServiceReferenceRecipe.java:349)[7:org.apache.aries.blueprint:0.2.0.incubating]
at
org.apache.felix.framework.util.EventDispatcher.invokeServiceListenerCallback(EventDispatcher.java:871)[org.apache.felix.framework-3.0.9.jar:]
at
org.apache.felix.framework.util.EventDispatcher.fireEventImmediately(EventDispatcher.java:733)[org.apache.felix.framework-3.0.9.jar:]
at
org.apache.felix.framework.util.EventDispatcher.fireServiceEvent(EventDispatcher.java:662)[org.apache.felix.framework-3.0.9.jar:]
at
org.apache.felix.framework.Felix.fireServiceEvent(Felix.java:3772)[org.apache.felix.framework-3.0.9.jar:]
at org.apache.felix.framework.Felix.access
$000(Felix.java:80)[org.apache.felix.framework-3.0.9.jar:]
at org.apache.felix.framework.Felix
$2.serviceChanged(Felix.java:729)[org.apache.felix.framework-3.0.9.jar:]
at
org.apache.felix.framework.ServiceRegistry.registerService(ServiceRegistry.java:107)[org.apache.felix.framework-3.0.9.jar:]
at
org.apache.felix.framework.Felix.registerService(Felix.java:2861)[org.apache.felix.framework-3.0.9.jar:]
at
org.apache.felix.framework.BundleContextImpl.registerService(BundleContextImpl.java:251)[org.apache.felix.framework-3.0.9.jar:]
at
org.apache.felix.framework.BundleContextImpl.registerService(BundleContextImpl.java:229)[org.apache.felix.framework-3.0.9.jar:]
at
org.apache.servicemix.common.osgi.EndpointExporter.deploy(EndpointExporter.java:121)[120:servicemix-common:2011.01.0]
at
org.apache.servicemix.common.osgi.EndpointExporter.afterPropertiesSet(EndpointExporter.java:185)[120:servicemix-common:2011.01.0]
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1477)[58:org.springframework.beans:3.0.5.RELEASE]
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1417)[58:org.springframework.beans:3.0.5.RELEASE]
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)[58:org.springframework.beans:3.0.5.RELEASE]
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)[58:org.springframework.beans:3.0.5.RELEASE]
at org.springframework.beans.factory.support.AbstractBeanFactory
$1.getObject(AbstractBeanFactory.java:291)[58:org.springframework.beans:3.0.5.RELEASE]
at
org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)[58:org.springframework.beans:3.0.5.RELEASE]
at
org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:288)[58:org.springframework.beans:3.0.5.RELEASE]
at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:190)[58:org.springframework.beans:3.0.5.RELEASE]
at
org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:580)[58:org.springframework.beans:3.0.5.RELEASE]
at
org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:895)[60:org.springframework.context:3.0.5.RELEASE]
at
org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext.access$1600(AbstractDelegatedExecutionApplicationContext.java:69)[70:org.springframework.osgi.core:1.2.0]
at
org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext$4.run(AbstractDelegatedExecutionApplicationContext.java:355)[70:org.springframework.osgi.core:1.2.0]
at
org.springframework.osgi.util.internal.PrivilegedUtils.executeWithCustomTCCL(PrivilegedUtils.java:85)[70:org.springframework.osgi.core:1.2.0]
at
org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext.completeRefresh(AbstractDelegatedExecutionApplicationContext.java:320)[70:org.springframework.osgi.core:1.2.0]
at
org.springframework.osgi.extender.internal.dependencies.startup.DependencyWaiterApplicationContextExecutor$CompleteRefreshTask.run(DependencyWaiterApplicationContextExecutor.java:136)[71:org.springframework.osgi.extender:1.2.0]
at java.lang.Thread.run(Thread.java:662)[:1.6.0_22]
Caused by: javax.jbi.management.DeploymentException:
java.lang.RuntimeException:
org.springframework.context.ApplicationContextException: Failed to load
configuration cxf-bus.xml
at
org.apache.servicemix.cxfbc.CxfBcConsumer.validate(CxfBcConsumer.java:562)[155:servicemix-cxf-bc:2011.01.0]
at org.apache.servicemix.common.osgi.EndpointTracker
$OsgiServiceUnit.<init>(EndpointTracker.java:81)[120:servicemix-common:2011.01.0]
at
org.apache.servicemix.common.osgi.EndpointTracker.register(EndpointTracker.java:59)[120:servicemix-common:2011.01.0]
... 38 more
Caused by: java.lang.RuntimeException:
org.springframework.context.ApplicationContextException: Failed to load
configuration cxf-bus.xml
at
org.apache.cxf.bus.spring.SpringBusFactory.createBus(SpringBusFactory.java:96)[115:org.apache.cxf.bundle:2.3.2]
at
org.apache.cxf.bus.spring.SpringBusFactory.createBus(SpringBusFactory.java:88)[115:org.apache.cxf.bundle:2.3.2]
at
org.apache.cxf.bus.spring.SpringBusFactory.createBus(SpringBusFactory.java:64)[115:org.apache.cxf.bundle:2.3.2]
at
org.apache.servicemix.cxfbc.CxfBcConsumer.getBus(CxfBcConsumer.java:678)[155:servicemix-cxf-bc:2011.01.0]
at
org.apache.servicemix.cxfbc.CxfBcConsumer.retrieveWSDL(CxfBcConsumer.java:659)[155:servicemix-cxf-bc:2011.01.0]
at
org.apache.servicemix.cxfbc.CxfBcConsumer.validate(CxfBcConsumer.java:431)[155:servicemix-cxf-bc:2011.01.0]
... 40 more
Caused by: org.springframework.context.ApplicationContextException:
Failed to load configuration cxf-bus.xml
at
org.apache.cxf.bus.spring.BusApplicationContext.getConfigResources(BusApplicationContext.java:152)[115:org.apache.cxf.bundle:2.3.2]
at
org.springframework.context.support.AbstractXmlApplicationContext.loadBeanDefinitions(AbstractXmlApplicationContext.java:120)
at
org.apache.cxf.bus.spring.BusApplicationContext.loadBeanDefinitions(BusApplicationContext.java:262)[115:org.apache.cxf.bundle:2.3.2]
at
org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:130)
at
org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:467)[60:org.springframework.context:3.0.5.RELEASE]
at
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:397)[60:org.springframework.context:3.0.5.RELEASE]
at
org.apache.cxf.bus.spring.BusApplicationContext.<init>(BusApplicationContext.java:91)[115:org.apache.cxf.bundle:2.3.2]
at
org.apache.cxf.bus.spring.SpringBusFactory.createApplicationContext(SpringBusFactory.java:110)[115:org.apache.cxf.bundle:2.3.2]
at
org.apache.cxf.bus.spring.SpringBusFactory.createBus(SpringBusFactory.java:93)[115:org.apache.cxf.bundle:2.3.2]
... 45 more
15:16:56,903 | INFO | xtenderThread-58 | EndpointExporter
| 120 - servicemix-common - 2011.01.0 | Waiting for all endpoints to be
deployed before registering service assembly
If i comment bugCfg all works fine. While, i have same error if i try to
comment tlsServerParameters section.
Is it a bug?
On my pom.xml i have this Import:
<Import-Package>
!org.springframework.*,
!junit.framework,
!org.junit,
org.apache.xbean*,
org.apache.servicemix.cxfbc,
org.apache.servicemix.common.osgi,
org.apache.log4j*,
org.apache.cxf.binding.jbi,
META-INF.services.org.apache.xbean.spring.http.servicemix.apache.org.cxfbc,
javax.*,
com.ibm*,
org.apache.cxf,
org.apache.cxf.bus,
org.apache.servicemix.*,
org.apache.commons*,
org.apache.ws.*,
org.eclipse.*,
org.w3c.dom*,
org.xml.sax*,
org.apache.cxf.bus.spring,
org.apache.cxf.bus.resource,
org.apache.cxf.configuration.spring,
org.apache.cxf.resource,
org.apache.cxf.transport,
org.apache.cxf.transport.http,
org.apache.cxf.transport.http.spring,
META-INF.cxf,
org.springframework.beans.factory.config,
org.apache.ws.security,
javax.security.auth.callback,
org.apache.cxf.binding.soap.saaj,
org.apache.cxf.interceptor,
org.apache.cxf.ws.security.wss4j,
org.apache.ws.security.action,
javax.jws,
javax.wsdl,
javax.xml.bind,
javax.xml.bind.annotation,
javax.xml.namespace,
javax.xml.ws,
org.apache.cxf.transports.http_jetty.configuration,
org.apache.cxf.transport.http_jetty.spring,
org.apache.cxf.transport.https_jetty,
org.apache.cxf.transport.http_jetty.continuations,
org.apache.cxf.transport.http_jetty,
org.apache.cxf*,
org.apache.xml.resolver,
com.sun.xml.bind.marshaller,
com.sun.xml.fastinfoset.stax,
net.sf.cglib.proxy,
org.apache.neethi,
org.apache.xml.resolver.helpers,
org.apache.xml.resolver.tools,
org.objectweb.asm,
org.slf4j
</Import-Package>
--------------------------------------------------------------------------
With xbean.xml file:
--------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<!-- $Id: xbean.xml -1 $ -->
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:cxfbc="http://servicemix.apache.org/cxfbc/1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:tns="http://test.route.it/test"
xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd
http://servicemix.apache.org/cxfbc/1.0
http://servicemix.apache.org/cxfbc/1.0/servicemix-cxf-bc.xsd">
<!-- use this special class to register the endpoints with the NMR
-->
<bean class="org.apache.servicemix.common.osgi.EndpointExporter" />
<cxfbc:consumer
service="tns:testService"
wsdl="classpath:testService.wsdl"
locationURI="http://0.0.0.0:8202/testService/"
endpoint="tns:testService1"
schemaValidationEnabled="true"
busCfg="cxf-bus.xml"
targetService="tns:testService2">
</cxfbc:consumer>
</beans>
---------------------------------------------------------------------------
With this cxf-bus.xml file
---------------------------------------------------------------------------
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:sec="http://cxf.apache.org/configuration/security"
xmlns:http="http://cxf.apache.org/transports/http/configuration"
xmlns:httpj="http://cxf.apache.org/transports/http-jetty/configuration"
xmlns:jaxws="http://cxf.apache.org/xml/ns/jaxws"
xsi:schemaLocation="
http://cxf.apache.org/jaxws
http://cxf.apache.org/schemas/jaxws.xsd
http://cxf.apache.org/configuration/security
http://cxf.apache.org/schemas/configuration/security.xsd
http://cxf.apache.org/transports/http/configuration
http://cxf.apache.org/schemas/configuration/http-conf.xsd
http://cxf.apache.org/transports/http-jetty/configuration
http://cxf.apache.org/schemas/configuration/http-jetty.xsd
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd">
<bean id="cxf" class="org.apache.cxf.bus.CXFBusImpl"/>
<httpj:engine-factory bus="cxf">
<httpj:engine port="8202">
<httpj:tlsServerParameters>
<sec:keyManagers keyPassword="geaaru0">
<sec:keyStore type="JKS" password="qwe123"
file="/tmp/server.keystore"/>
</sec:keyManagers>
<!--<sec:trustManagers>
<sec:keyStore type="JKS" password="password"
file="Truststore.jks"/>
</sec:trustManagers>-->
<sec:cipherSuitesFilter>
<!-- these filters ensure that a ciphersuite with
export-suitable or null encryption is used,
but exclude anonymous Diffie-Hellman key change as
this is vulnerable to man-in-the-middle attacks -->
<sec:include>.*_EXPORT_.*</sec:include>
<sec:include>.*_EXPORT1024_.*</sec:include>
<sec:include>.*_WITH_DES_.*</sec:include>
<sec:include>.*_WITH_NULL_.*</sec:include>
<sec:exclude>.*_DH_anon_.*</sec:exclude>
</sec:cipherSuitesFilter>
</httpj:tlsServerParameters>
<!--<httpj:threadingParameters minThreads="1"
maxThreads="12" />-->
</httpj:engine>
</httpj:engine-factory>
</beans>
Re: Error on use servicemix-cxf-bc as osgi bundle and with ssl
Posted by Freeman Fang <fr...@gmail.com>.
Hi,
If you're using smx4, you'd better use providedBus but not busCfg, you
can take a look at SMXCOMP-688[1], the long comments there explain the
whole map I believe.
Btw, for the SSL configuration, you have something like
<sec:keyStore type="JKS" password="password"
file="Truststore.jks"/>
This doesn't work well in OSGi container, as it try to pass file
between bundles, which is always a problem for package visible between
bundles, you should use some configuration like
<sec:keyStore type="JKS" password="password"
resource="Truststore.jks"/>
use "resource" but not file here
[1]https://issues.apache.org/jira/browse/SMXCOMP-688
Freeman
On 2011-4-6, at 下午10:00, Ge@@ru wrote:
> Hi, i created a bundle for use servicemix-cxf-bc module but i have
> this
> error when i try to deploy it.
>
> 15:16:56,896 | ERROR | xtenderThread-58 | tServiceReferenceRecipe
> $Listener | 7 - org.apache.aries.blueprint - 0.2.0.incubating | Error
> calling listener method public void
> org
> .apache
> .servicemix
> .common
> .osgi
> .EndpointTracker
> .register
> (org.apache.servicemix.common.osgi.EndpointWrapper,java.util.Map)
> throws java.lang.Exception
> java.lang.reflect.InvocationTargetException
> at sun.reflect.GeneratedMethodAccessor62.invoke(Unknown Source)
> at
> sun
> .reflect
> .DelegatingMethodAccessorImpl
> .invoke(DelegatingMethodAccessorImpl.java:25)[:1.6.0_22]
> at java.lang.reflect.Method.invoke(Method.java:597)[:1.6.0_22]
> at
> org
> .apache
> .aries.blueprint.utils.ReflectionUtils.invoke(ReflectionUtils.java:
> 221)[7:org.apache.aries.blueprint:0.2.0.incubating]
> at
> org.apache.aries.blueprint.container.AbstractServiceReferenceRecipe
> $Listener.invokeMethods(AbstractServiceReferenceRecipe.java:553)
> [7:org.apache.aries.blueprint:0.2.0.incubating]
> at
> org.apache.aries.blueprint.container.AbstractServiceReferenceRecipe
> $Listener.bind(AbstractServiceReferenceRecipe.java:518)
> [7:org.apache.aries.blueprint:0.2.0.incubating]
> at
> org
> .apache
> .aries
> .blueprint
> .container
> .AbstractServiceReferenceRecipe
> .bind(AbstractServiceReferenceRecipe.java:415)
> [7:org.apache.aries.blueprint:0.2.0.incubating]
> at
> org
> .apache
> .aries
> .blueprint
> .container.ReferenceListRecipe.track(ReferenceListRecipe.java:135)
> [7:org.apache.aries.blueprint:0.2.0.incubating]
> at
> org
> .apache
> .aries
> .blueprint
> .container
> .AbstractServiceReferenceRecipe
> .serviceAdded(AbstractServiceReferenceRecipe.java:365)
> [7:org.apache.aries.blueprint:0.2.0.incubating]
> at
> org
> .apache
> .aries
> .blueprint
> .container
> .AbstractServiceReferenceRecipe
> .serviceChanged(AbstractServiceReferenceRecipe.java:349)
> [7:org.apache.aries.blueprint:0.2.0.incubating]
> at
> org
> .apache
> .felix
> .framework
> .util
> .EventDispatcher.invokeServiceListenerCallback(EventDispatcher.java:
> 871)[org.apache.felix.framework-3.0.9.jar:]
> at
> org
> .apache
> .felix
> .framework
> .util.EventDispatcher.fireEventImmediately(EventDispatcher.java:733)
> [org.apache.felix.framework-3.0.9.jar:]
> at
> org
> .apache
> .felix
> .framework
> .util.EventDispatcher.fireServiceEvent(EventDispatcher.java:662)
> [org.apache.felix.framework-3.0.9.jar:]
> at
> org.apache.felix.framework.Felix.fireServiceEvent(Felix.java:3772)
> [org.apache.felix.framework-3.0.9.jar:]
> at org.apache.felix.framework.Felix.access
> $000(Felix.java:80)[org.apache.felix.framework-3.0.9.jar:]
> at org.apache.felix.framework.Felix
> $2.serviceChanged(Felix.java:729)
> [org.apache.felix.framework-3.0.9.jar:]
> at
> org
> .apache
> .felix
> .framework.ServiceRegistry.registerService(ServiceRegistry.java:107)
> [org.apache.felix.framework-3.0.9.jar:]
> at
> org.apache.felix.framework.Felix.registerService(Felix.java:2861)
> [org.apache.felix.framework-3.0.9.jar:]
> at
> org
> .apache
> .felix
> .framework.BundleContextImpl.registerService(BundleContextImpl.java:
> 251)[org.apache.felix.framework-3.0.9.jar:]
> at
> org
> .apache
> .felix
> .framework.BundleContextImpl.registerService(BundleContextImpl.java:
> 229)[org.apache.felix.framework-3.0.9.jar:]
> at
> org
> .apache
> .servicemix
> .common.osgi.EndpointExporter.deploy(EndpointExporter.java:121)
> [120:servicemix-common:2011.01.0]
> at
> org
> .apache
> .servicemix
> .common
> .osgi.EndpointExporter.afterPropertiesSet(EndpointExporter.java:185)
> [120:servicemix-common:2011.01.0]
> at
> org
> .springframework
> .beans
> .factory
> .support
> .AbstractAutowireCapableBeanFactory
> .invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1477)
> [58:org.springframework.beans:3.0.5.RELEASE]
> at
> org
> .springframework
> .beans
> .factory
> .support
> .AbstractAutowireCapableBeanFactory
> .initializeBean(AbstractAutowireCapableBeanFactory.java:1417)
> [58:org.springframework.beans:3.0.5.RELEASE]
> at
> org
> .springframework
> .beans
> .factory
> .support
> .AbstractAutowireCapableBeanFactory
> .doCreateBean(AbstractAutowireCapableBeanFactory.java:519)
> [58:org.springframework.beans:3.0.5.RELEASE]
> at
> org
> .springframework
> .beans
> .factory
> .support
> .AbstractAutowireCapableBeanFactory
> .createBean(AbstractAutowireCapableBeanFactory.java:456)
> [58:org.springframework.beans:3.0.5.RELEASE]
> at org.springframework.beans.factory.support.AbstractBeanFactory
> $1.getObject(AbstractBeanFactory.java:291)
> [58:org.springframework.beans:3.0.5.RELEASE]
> at
> org
> .springframework
> .beans
> .factory
> .support
> .DefaultSingletonBeanRegistry
> .getSingleton(DefaultSingletonBeanRegistry.java:222)
> [58:org.springframework.beans:3.0.5.RELEASE]
> at
> org
> .springframework
> .beans
> .factory
> .support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:288)
> [58:org.springframework.beans:3.0.5.RELEASE]
> at
> org
> .springframework
> .beans
> .factory
> .support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:190)
> [58:org.springframework.beans:3.0.5.RELEASE]
> at
> org
> .springframework
> .beans
> .factory
> .support
> .DefaultListableBeanFactory
> .preInstantiateSingletons(DefaultListableBeanFactory.java:580)
> [58:org.springframework.beans:3.0.5.RELEASE]
> at
> org
> .springframework
> .context
> .support
> .AbstractApplicationContext
> .finishBeanFactoryInitialization(AbstractApplicationContext.java:895)
> [60:org.springframework.context:3.0.5.RELEASE]
> at
> org
> .springframework
> .osgi
> .context.support.AbstractDelegatedExecutionApplicationContext.access
> $1600(AbstractDelegatedExecutionApplicationContext.java:69)
> [70:org.springframework.osgi.core:1.2.0]
> at
> org
> .springframework
> .osgi.context.support.AbstractDelegatedExecutionApplicationContext
> $4.run(AbstractDelegatedExecutionApplicationContext.java:355)
> [70:org.springframework.osgi.core:1.2.0]
> at
> org
> .springframework
> .osgi
> .util
> .internal.PrivilegedUtils.executeWithCustomTCCL(PrivilegedUtils.java:
> 85)[70:org.springframework.osgi.core:1.2.0]
> at
> org
> .springframework
> .osgi
> .context
> .support
> .AbstractDelegatedExecutionApplicationContext
> .completeRefresh(AbstractDelegatedExecutionApplicationContext.java:
> 320)[70:org.springframework.osgi.core:1.2.0]
> at
> org
> .springframework
> .osgi
> .extender
> .internal
> .dependencies.startup.DependencyWaiterApplicationContextExecutor
> $
> CompleteRefreshTask
> .run(DependencyWaiterApplicationContextExecutor.java:136)
> [71:org.springframework.osgi.extender:1.2.0]
> at java.lang.Thread.run(Thread.java:662)[:1.6.0_22]
> Caused by: javax.jbi.management.DeploymentException:
> java.lang.RuntimeException:
> org.springframework.context.ApplicationContextException: Failed to
> load
> configuration cxf-bus.xml
> at
> org
> .apache.servicemix.cxfbc.CxfBcConsumer.validate(CxfBcConsumer.java:
> 562)[155:servicemix-cxf-bc:2011.01.0]
> at org.apache.servicemix.common.osgi.EndpointTracker
> $OsgiServiceUnit.<init>(EndpointTracker.java:81)[120:servicemix-
> common:2011.01.0]
> at
> org
> .apache
> .servicemix
> .common.osgi.EndpointTracker.register(EndpointTracker.java:59)
> [120:servicemix-common:2011.01.0]
> ... 38 more
> Caused by: java.lang.RuntimeException:
> org.springframework.context.ApplicationContextException: Failed to
> load
> configuration cxf-bus.xml
> at
> org
> .apache
> .cxf.bus.spring.SpringBusFactory.createBus(SpringBusFactory.java:96)
> [115:org.apache.cxf.bundle:2.3.2]
> at
> org
> .apache
> .cxf.bus.spring.SpringBusFactory.createBus(SpringBusFactory.java:88)
> [115:org.apache.cxf.bundle:2.3.2]
> at
> org
> .apache
> .cxf.bus.spring.SpringBusFactory.createBus(SpringBusFactory.java:64)
> [115:org.apache.cxf.bundle:2.3.2]
> at
> org.apache.servicemix.cxfbc.CxfBcConsumer.getBus(CxfBcConsumer.java:
> 678)[155:servicemix-cxf-bc:2011.01.0]
> at
> org
> .apache
> .servicemix.cxfbc.CxfBcConsumer.retrieveWSDL(CxfBcConsumer.java:659)
> [155:servicemix-cxf-bc:2011.01.0]
> at
> org
> .apache.servicemix.cxfbc.CxfBcConsumer.validate(CxfBcConsumer.java:
> 431)[155:servicemix-cxf-bc:2011.01.0]
> ... 40 more
> Caused by: org.springframework.context.ApplicationContextException:
> Failed to load configuration cxf-bus.xml
> at
> org
> .apache
> .cxf
> .bus
> .spring
> .BusApplicationContext.getConfigResources(BusApplicationContext.java:
> 152)[115:org.apache.cxf.bundle:2.3.2]
> at
> org
> .springframework
> .context
> .support
> .AbstractXmlApplicationContext
> .loadBeanDefinitions(AbstractXmlApplicationContext.java:120)
> at
> org
> .apache
> .cxf
> .bus
> .spring
> .BusApplicationContext
> .loadBeanDefinitions(BusApplicationContext.java:262)
> [115:org.apache.cxf.bundle:2.3.2]
> at
> org
> .springframework
> .context
> .support
> .AbstractRefreshableApplicationContext
> .refreshBeanFactory(AbstractRefreshableApplicationContext.java:130)
> at
> org
> .springframework
> .context
> .support
> .AbstractApplicationContext
> .obtainFreshBeanFactory(AbstractApplicationContext.java:467)
> [60:org.springframework.context:3.0.5.RELEASE]
> at
> org
> .springframework
> .context
> .support
> .AbstractApplicationContext.refresh(AbstractApplicationContext.java:
> 397)[60:org.springframework.context:3.0.5.RELEASE]
> at
> org
> .apache
> .cxf
> .bus.spring.BusApplicationContext.<init>(BusApplicationContext.java:
> 91)[115:org.apache.cxf.bundle:2.3.2]
> at
> org
> .apache
> .cxf
> .bus
> .spring
> .SpringBusFactory.createApplicationContext(SpringBusFactory.java:110)
> [115:org.apache.cxf.bundle:2.3.2]
> at
> org
> .apache
> .cxf.bus.spring.SpringBusFactory.createBus(SpringBusFactory.java:93)
> [115:org.apache.cxf.bundle:2.3.2]
> ... 45 more
> 15:16:56,903 | INFO | xtenderThread-58 | EndpointExporter
> | 120 - servicemix-common - 2011.01.0 | Waiting for all endpoints to
> be
> deployed before registering service assembly
>
> If i comment bugCfg all works fine. While, i have same error if i
> try to
> comment tlsServerParameters section.
>
> Is it a bug?
>
> On my pom.xml i have this Import:
>
> <Import-Package>
> !org.springframework.*,
> !junit.framework,
> !org.junit,
> org.apache.xbean*,
> org.apache.servicemix.cxfbc,
> org.apache.servicemix.common.osgi,
> org.apache.log4j*,
> org.apache.cxf.binding.jbi,
>
> META-
> INF.services.org.apache.xbean.spring.http.servicemix.apache.org.cxfbc,
>
> javax.*,
> com.ibm*,
> org.apache.cxf,
> org.apache.cxf.bus,
> org.apache.servicemix.*,
> org.apache.commons*,
> org.apache.ws.*,
> org.eclipse.*,
> org.w3c.dom*,
> org.xml.sax*,
>
> org.apache.cxf.bus.spring,
> org.apache.cxf.bus.resource,
> org.apache.cxf.configuration.spring,
> org.apache.cxf.resource,
> org.apache.cxf.transport,
> org.apache.cxf.transport.http,
> org.apache.cxf.transport.http.spring,
> META-INF.cxf,
> org.springframework.beans.factory.config,
> org.apache.ws.security,
> javax.security.auth.callback,
> org.apache.cxf.binding.soap.saaj,
> org.apache.cxf.interceptor,
> org.apache.cxf.ws.security.wss4j,
> org.apache.ws.security.action,
> javax.jws,
> javax.wsdl,
> javax.xml.bind,
> javax.xml.bind.annotation,
> javax.xml.namespace,
> javax.xml.ws,
>
> org.apache.cxf.transports.http_jetty.configuration,
> org.apache.cxf.transport.http_jetty.spring,
> org.apache.cxf.transport.https_jetty,
>
> org.apache.cxf.transport.http_jetty.continuations,
> org.apache.cxf.transport.http_jetty,
>
> org.apache.cxf*,
> org.apache.xml.resolver,
> com.sun.xml.bind.marshaller,
> com.sun.xml.fastinfoset.stax,
> net.sf.cglib.proxy,
> org.apache.neethi,
> org.apache.xml.resolver.helpers,
> org.apache.xml.resolver.tools,
> org.objectweb.asm,
> org.slf4j
>
> </Import-Package>
>
> --------------------------------------------------------------------------
> With xbean.xml file:
> --------------------------------------------------------------------------
> <?xml version="1.0" encoding="UTF-8"?>
> <!-- $Id: xbean.xml -1 $ -->
> <beans xmlns="http://www.springframework.org/schema/beans"
> xmlns:cxfbc="http://servicemix.apache.org/cxfbc/1.0"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xmlns:tns="http://test.route.it/test"
> xsi:schemaLocation="
> http://www.springframework.org/schema/beans
> http://www.springframework.org/schema/beans/spring-beans.xsd
> http://servicemix.apache.org/cxfbc/1.0
> http://servicemix.apache.org/cxfbc/1.0/servicemix-cxf-bc.xsd">
>
>
> <!-- use this special class to register the endpoints with the NMR
> -->
> <bean class="org.apache.servicemix.common.osgi.EndpointExporter" />
>
> <cxfbc:consumer
> service="tns:testService"
> wsdl="classpath:testService.wsdl"
> locationURI="http://0.0.0.0:8202/testService/"
> endpoint="tns:testService1"
> schemaValidationEnabled="true"
> busCfg="cxf-bus.xml"
> targetService="tns:testService2">
> </cxfbc:consumer>
>
> </beans>
>
> ---------------------------------------------------------------------------
> With this cxf-bus.xml file
> ---------------------------------------------------------------------------
> <beans xmlns="http://www.springframework.org/schema/beans"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xmlns:sec="http://cxf.apache.org/configuration/security"
> xmlns:http="http://cxf.apache.org/transports/http/configuration"
>
> xmlns:httpj="http://cxf.apache.org/transports/http-jetty/
> configuration"
> xmlns:jaxws="http://cxf.apache.org/xml/ns/jaxws"
> xsi:schemaLocation="
> http://cxf.apache.org/jaxws
> http://cxf.apache.org/schemas/jaxws.xsd
> http://cxf.apache.org/configuration/security
> http://cxf.apache.org/schemas/configuration/
> security.xsd
> http://cxf.apache.org/transports/http/configuration
>
> http://cxf.apache.org/schemas/configuration/http-conf.xsd
>
> http://cxf.apache.org/transports/http-jetty/configuration
>
> http://cxf.apache.org/schemas/configuration/http-jetty.xsd
> http://www.springframework.org/schema/beans
>
> http://www.springframework.org/schema/beans/spring-beans.xsd">
>
> <bean id="cxf" class="org.apache.cxf.bus.CXFBusImpl"/>
>
> <httpj:engine-factory bus="cxf">
> <httpj:engine port="8202">
>
> <httpj:tlsServerParameters>
>
> <sec:keyManagers keyPassword="geaaru0">
> <sec:keyStore type="JKS" password="qwe123"
> file="/tmp/server.keystore"/>
> </sec:keyManagers>
>
> <!--<sec:trustManagers>
> <sec:keyStore type="JKS" password="password"
> file="Truststore.jks"/>
> </sec:trustManagers>-->
> <sec:cipherSuitesFilter>
> <!-- these filters ensure that a ciphersuite with
> export-suitable or null encryption is used,
> but exclude anonymous Diffie-Hellman key change as
> this is vulnerable to man-in-the-middle attacks -->
> <sec:include>.*_EXPORT_.*</sec:include>
> <sec:include>.*_EXPORT1024_.*</sec:include>
> <sec:include>.*_WITH_DES_.*</sec:include>
> <sec:include>.*_WITH_NULL_.*</sec:include>
> <sec:exclude>.*_DH_anon_.*</sec:exclude>
> </sec:cipherSuitesFilter>
>
> </httpj:tlsServerParameters>
> <!--<httpj:threadingParameters minThreads="1"
> maxThreads="12" />-->
>
> </httpj:engine>
> </httpj:engine-factory>
>
> </beans>
>
---------------------------------------------
Freeman Fang
FuseSource
Email:ffang@fusesource.com
Web: fusesource.com
Twitter: freemanfang
Blog: http://freemanfang.blogspot.com
Connect at CamelOne May 24-26
The Open Source Integration Conference