Hi,

Would you append your wsdl also?
Freeman

Sylvester wrote:
Hi,
I've run into a problem with CXF today. I have a CXF BC communicating with a CXF SE. No problem building and deploying. I can see the wsdl in the browser as well. I am using smx 3.2.3 for this.

My cxf bc xbean is:

beans xmlns="http://www.springframework.org/schema/beans";
   xmlns:cxfbc="http://servicemix.apache.org/cxfbc/1.0";
   xmlns:xsi="http://http://www.w3.org/2001/XMLSchema-instance";
   xmlns:myservice="http://example.com/exampleService";
xsi:schemaLocation="http://servicemix.apache.org/cxfbc/1.0 http://servicemix.apache.org/schema/servicemix-cxfbc-3.2.3.xsd http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd";>

   <cxfbc:consumer wsdl="classpath:service.wsdl"
       targetService="myservice:ExampleService" />

</beans>

CXF se xbean:

<beans xmlns:cxfse="http://servicemix.apache.org/cxfse/1.0";
      xmlns="http://www.springframework.org/schema/beans";
      xmlns:xsi="http://http://www.w3.org/2001/XMLSchema-instance";
xsi:schemaLocation="http://servicemix.apache.org/cxfse/1.0 http://servicemix.apache.org/schema/servicemix-cxfse-3.2.3.xsd http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd";>

   <cxfse:endpoint>
       <cxfse:pojo>
         <bean class="com.ExampleService" />
       </cxfse:pojo>
   </cxfse:endpoint>

</beans>
and com.ExampleService is annotated as:

@WebService(name = "ExampleService", targetNamespace = "http://example.com/exampleService";)
public class ExampleService {

   @WebMethod
   public String getHighLevelBusinessFlow (String CIId, String StateId){
...
}

I generated the wsdl using the .class file from the target folder of my SE with the java2ws utility that came with my CXF 2.1.3.

The response to my soap request is like:

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/";>
  <soap:Body>
     <soap:Fault>
        <faultcode>soap:Server</faultcode>
        <faultstring><![CDATA[Could not find route for exchange: InOut[
 id: ID:blah-blah-
 status: Active
 role: provider
 service: {http://example.com/exampleService}ExampleService
 operation: {http://example.com/exampleService}getHighLevelBusinessFlow
in: <?xml version="1.0" encoding="UTF-8"?><jbi:message xmlns:jbi="http://java.sun.com/xml/ns/jbi/wsdl-11-wrapper"; xmlns:msg="http://example.com/exampleService"; xmlns:xsd="http://www.w3.org/2001/XMLSchema"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; name="getHighLevelBusinessFlow" type="msg:getHighLevelBusinessFlow" version="1.0"><jbi:part><exam:getHighLevelBusinessFlow xmlns:exam="http://example.com/exampleService";>
        <!--Optional:-->
        <arg0 xmlns="">1</arg0>
        <!--Optional:-->
        <arg1 xmlns="">2</arg1>
     </exam:getHighLevelBusinessFlow></jbi:part></jbi:message>
] for service: {http://example.com/exampleService}ExampleService and interface: null]]></faultstring>
     </soap:Fault>
  </soap:Body>
</soap:Envelope>

I see:

] for service: {http://example.com/exampleService}ExampleService and interface:
null
at org.apache.servicemix.cxfbc.CxfBcConsumer$JbiInvokerInterceptor.handl
eMessage(CxfBcConsumer.java:608)
at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseIntercept
orChain.java:220)
at org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainIniti
ationObserver.java:77)
at org.apache.cxf.transport.http_jetty.JettyHTTPDestination.serviceReque
st(JettyHTTPDestination.java:278)
at org.apache.cxf.transport.http_jetty.JettyHTTPDestination.doService(Je
ttyHTTPDestination.java:252)

and the log has:
qtp0-0 | DefaultBroker | rvicemix.jbi.nmr.DefaultBroker 344 | ServiceName ({http://example.com/exampleService}ExampleService) specified for routing, but can't find it registered

I tried changing the targetNamespace and the name but that didn't work either. What could be going wrong?

Thanks,
Sylvester




Reply via email to