make sure that you have declared the namespace you use "tns"
in your xbean.xml, and it should be the same as your targetNamespace="
http://test/";
from your wsdl.
I think in your xbean.xml this should be like

xmlns:tns="http://test/";


On Wed, Jun 24, 2009 at 10:24 AM, jcamus <[email protected]> wrote:

>
> Hi!
> I am trying to define a CXF-BC provider but when deploying I have the
> following error :
>
> <stack-trace><![CDATA[javax.jbi.management.DeploymentException:
> org.apache.cxf.service.factory.ServiceConstructionException: Could
>  not find definition for service 
> {http://test/}TestService<http://test/%7DTestService>
> .
>        at
> org.apache.servicemix.cxfbc.CxfBcProvider.validate(CxfBcProvider.java:504)
>        at
>
> org.apache.servicemix.common.AbstractDeployer.validate(AbstractDeployer.java:58)
>        at
>
> org.apache.servicemix.common.xbean.BaseXBeanDeployer.validate(BaseXBeanDeployer.java:55)
>        at
>
> org.apache.servicemix.common.xbean.AbstractXBeanDeployer.deploy(AbstractXBeanDeployer.java:97)
>        at
>
> org.apache.servicemix.common.BaseServiceUnitManager.doDeploy(BaseServiceUnitManager.java:88)
>        at
>
> org.apache.servicemix.common.BaseServiceUnitManager.deploy(BaseServiceUnitManager.java:69)
>        at
>
> org.apache.servicemix.jbi.framework.DeploymentService.deployServiceAssembly(DeploymentService.java:520)
>        at
>
> org.apache.servicemix.jbi.framework.AutoDeploymentService.updateServiceAssembly(AutoDeploymentService.java:349)
>        at
>
> org.apache.servicemix.jbi.framework.AutoDeploymentService.updateArchive(AutoDeploymentService.java:255)
>        at
>
> org.apache.servicemix.jbi.framework.AutoDeploymentService.monitorDirectory(AutoDeploymentService.java:658)
>        at
>
> org.apache.servicemix.jbi.framework.AutoDeploymentService.access$800(AutoDeploymentService.java:63)
>        at
>
> org.apache.servicemix.jbi.framework.AutoDeploymentService$1.run(AutoDeploymentService.java:622)
>        at java.util.TimerThread.mainLoop(Timer.java:512)
>        at java.util.TimerThread.run(Timer.java:462)
> Caused by: org.apache.cxf.service.factory.ServiceConstructionException:
> Could not find definition for service 
> {http://test/}TestSe<http://test/%7DTestSe>
> rvice.
>        at
>
> org.apache.cxf.wsdl11.WSDLServiceFactory.create(WSDLServiceFactory.java:126)
>        at
> org.apache.servicemix.cxfbc.CxfBcProvider.validate(CxfBcProvider.java:422)
>        ... 13 more
> ]]></stack-trace>
>
>
> The xbean.xml is :
>
> <cxfbc:provider wsdl="classpath:test.wsdl"
>                 service="tns:TestService"
>         endpoint="TestPortProxy"
>         interfaceName="tns:TestSOAP">
>
>                <cxfbc:inInterceptors>
>                        <bean
> class="org.apache.cxf.interceptor.LoggingInInterceptor" />
>                </cxfbc:inInterceptors>
>                <cxfbc:outInterceptors>
>                        <bean
> class="org.apache.cxf.interceptor.LoggingOutInterceptor" />
>                </cxfbc:outInterceptors>
>                <cxfbc:inFaultInterceptors>
>                        <bean
> class="org.apache.cxf.interceptor.LoggingInInterceptor" />
>                </cxfbc:inFaultInterceptors>
>                <cxfbc:outFaultInterceptors>
>                        <bean
> class="org.apache.cxf.interceptor.LoggingOutInterceptor" />
>                </cxfbc:outFaultInterceptors>
>        </cxfbc:provider>
>
> The test.wsdl is :
>
> <?xml version="1.0" encoding="UTF-8" standalone="no"?>
> <wsdl:definitions xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";
> xmlns:tns="http://test/"; xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";
> xmlns:xsd="http://www.w3.org/2001/XMLSchema"; name="test"
> targetNamespace="http://test/";>
>  <wsdl:types>
>    <xsd:schema targetNamespace="http://test/";>
>      <xsd:element name="NewOperation">
>        <xsd:complexType>
>          <xsd:sequence>
>            <xsd:element name="in" type="xsd:string"/>
>          </xsd:sequence>
>        </xsd:complexType>
>      </xsd:element>
>      <xsd:element name="NewOperationResponse">
>        <xsd:complexType>
>          <xsd:sequence>
>            <xsd:element name="out" type="xsd:string"/>
>          </xsd:sequence>
>        </xsd:complexType>
>      </xsd:element>
>    </xsd:schema>
>  </wsdl:types>
>  <wsdl:message name="NewOperationRequest">
>    <wsdl:part element="tns:NewOperation" name="parameters"/>
>  </wsdl:message>
>  <wsdl:message name="NewOperationResponse">
>    <wsdl:part element="tns:NewOperationResponse" name="parameters"/>
>  </wsdl:message>
>  <wsdl:portType name="test">
>    <wsdl:operation name="NewOperation">
>      <wsdl:input message="tns:NewOperationRequest"/>
>      <wsdl:output message="tns:NewOperationResponse"/>
>    </wsdl:operation>
>  </wsdl:portType>
>  <wsdl:binding name="testSOAP" type="tns:test">
>    <soap:binding style="document"
> transport="http://schemas.xmlsoap.org/soap/http"/>
>    <wsdl:operation name="NewOperation">
>      <soap:operation soapAction="http://test/NewOperation"/>
>      <wsdl:input>
>        <soap:body use="literal"/>
>      </wsdl:input>
>      <wsdl:output>
>        <soap:body use="literal"/>
>      </wsdl:output>
>    </wsdl:operation>
>  </wsdl:binding>
>  <wsdl:service name="test">
>    <wsdl:port binding="tns:testSOAP" name="testSOAP">
>      <soap:address location="http://test/"/>
>    </wsdl:port>
>  </wsdl:service>
> </wsdl:definitions>
>
>
> Please what's wrong with that?
>
> Regards.
>
>
>
>
> --
> View this message in context:
> http://www.nabble.com/CXF-BC-provider-%3A-error-%3A-could-not-find-definition-for-service-tp24187027p24187027.html
> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>
>

Reply via email to