Hi guys,

I'm a SM newbee and just playing around a little bit with the capabilities
of ServiceMix. For better understand the components that are used in SM I
have developed a small case study that deals with a orderFood Szenario in a
restaurant.

My intension is to:
 
1. A "food" order  message should send to an external Webservice (kitchen
order client: KOC) for furhter processing.
2. The listening CXF Webservice is deployed on an Tomcat Server (generated
by STP and CXF) and is alread tested seperatly (SoapUI)

so the message flow is:
EIP Router -->EIP Splitter --->EIP Pipeline
 --->CXF BC -->Webservice 


4. The Response of the Webservice should be passed to a Simple
Bean(SimpleConsumer). In my current config with the SimpleConsumer Bean has
already some output (I guess the message that should be the request for the
Webservice)

The message coming from the Splitter looks like this. 
---------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<jbi:message xmlns:jbi="http://java.sun.com/xml/ns/jbi/wsdl-11-wrapper";
xmlns:cos="http://ps.com/COS/"; xmlns:kit="http://ps.com/kitchen/";>
        <jbi:part>
                <kit:foods>
                        <tableNumber>1</tableNumber>
                        <orderID>1</orderID>
                        <timestamp>1</timestamp>
                        <id>1</id>
                        <name>reis</name>
                        <price>3</price>
                        <quantity/>
                </kit:foods>
        </jbi:part>
</jbi:message>
------------------------------------------------------------
Since I have already tranformed the message beforhand I have added
jbi:message and jbi:parts envelops to the the plain xml using xslt to comply
with JBI NMR. (Maybe the message is not valid for process it in the CXF
BC???)

My problem:
Unfortunatly the Webservice is not invoked from the cxf:provider and I
seriously don't have a guess whats the problem (no error messsages). 

Do you have any idea what's the problem or where are the errors in my
configuration (or maybe some good samples for my scenario)
I really appreciate your help.

Thanks Dave



Here some snippet of my configuration files:
----EIP Router----

So the message flow will be.
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns:eip="http://servicemix.apache.org/eip/1.0";
xmlns:kit="http://ps.com/kitchen/";
xmlns:esb="http://esbinaction.com/examples";>

        
        <eip:xpath-splitter service="esb:xpathSplitterFoods"
                endpoint="endpointSplitterFoods" xpath="/order/foods/food">
                <eip:target>
                        <eip:exchange-target service="esb:KOCServicePipeline" />
                </eip:target>
        </eip:xpath-splitter>

        <eip:xpath-splitter service="esb:xpathSplitterDrinks"
                endpoint="endpointSplitterDrinks" xpath="/order/drinks/drink">
                <eip:target>
                        <eip:exchange-target service="esb:outputDrinks" />
                </eip:target>
        </eip:xpath-splitter>
        
        <eip:pipeline service="esb:KOCServicePipeline"
endpoint="routingServicesEndpoint">
                <eip:transformer>
                <eip:exchange-target service="kit:KOCService"
operation="kit:foodOrder"/>
                </eip:transformer>
                <eip:target>
                <eip:exchange-target service="esb:simpleComponent" />
                </eip:target>
        </eip:pipeline>
</beans>
-----------------------------------------------------------
CXF-BC
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns:cxfbc="http://servicemix.apache.org/cxfbc/1.0";
        xmlns:cos="http://ps.com/COS/"; 
xmlns="http://xbean.org/schemas/spring/1.0"; 
        xmlns:esb="http://esbinaction.com/examples";
        xmlns:kit="http://ps.com/kitchen/";>
        <classpath>
                <location>.</location>
        </classpath>

        <cxfbc:provider wsdl="classpath:KOC.wsdl" 
                        locationURI="http://localhost:8090/KOC/services/KOC";
                        endpoint="KOCSoap"
                        interfaceName="kit:KOCPortType"
                        service="kit:KOCService"
                        useJBIWrapper="false" 
                        />
        
-------------------------------------------------------------------------------------
WSDL file:
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<wsdl:definitions name="KOCService" xmlns:osesb="http://ps.com/kitchen/";
        xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";
        xmlns:xsd="http://www.w3.org/2001/XMLSchema"; 
        targetNamespace="http://ps.com/kitchen/";>
        <wsdl:types>
                <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema";
                        attributeFormDefault="unqualified" 
elementFormDefault="unqualified"
                        targetNamespace="http://ps.com/kitchen/";>

                        <xsd:element name="foods" type="osesb:foodsType" />
                        
                        <xsd:complexType name="foodsType">
                                <xsd:sequence>
                                        <xsd:element name="tableNumber" 
type="xsd:integer" />
                                        <xsd:element name="orderID" 
type="xsd:integer" />
                                        <xsd:element name="timestamp" 
type="xsd:string" />
                                        <xsd:element name="id" 
type="xsd:integer" />
                                        <xsd:element name="name" 
type="xsd:string" />
                                        <xsd:element name="price" 
type="xsd:double" />
                                        <xsd:element name="quantity" 
type="xsd:integer" />
                                </xsd:sequence>
                        </xsd:complexType>

                        <xsd:element name="confirm" type="osesb:confirmType" />
                        <xsd:complexType name="confirmType">
                                <xsd:sequence>
                                        <xsd:element name="msg" 
type="xsd:string" />
                                </xsd:sequence>
                        </xsd:complexType>
                        
                </xsd:schema>
        </wsdl:types>
        <wsdl:message name="foodOrderRequest">
                <wsdl:part element="osesb:foods" name="parameters" />
        </wsdl:message>
        <wsdl:message name="foodOrderResponse">
                <wsdl:part element="osesb:confirm" name="parameters" />
        </wsdl:message>
        
        <wsdl:portType name="KOCPortType">
                <wsdl:operation name="foodOrder">
                        <wsdl:input message="osesb:foodOrderRequest" />
                        <wsdl:output message="osesb:foodOrderResponse" />
                </wsdl:operation>
        </wsdl:portType>
        
        <wsdl:binding name="KOCSoapBinding" type="osesb:KOCPortType">
                <soap:binding style="document"
                        transport="http://schemas.xmlsoap.org/soap/http"; />
                <wsdl:operation name="foodOrder">
                        <soap:operation 
soapAction="http://ps.com/KOC/foodOrder"; />
                        <wsdl:input>
                                <soap:body use="literal" />
                        </wsdl:input>
                        <wsdl:output>
                                <soap:body use="literal" />
                        </wsdl:output>
                </wsdl:operation>
        </wsdl:binding>
        <wsdl:service name="KOCService">
                <wsdl:port name="KOCSoap" binding="osesb:KOCSoapBinding">
                        <soap:address 
location="http://localhost:8090/KOC/services/KOC"; />
                </wsdl:port>
        </wsdl:service>
</wsdl:definitions>
---------------------------------------------------------------------------
Thanks for you help
        


        

-- 
View this message in context: 
http://www.nabble.com/CXF-Provider-External-Webservice-Call-tp21739545p21739545.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.

Reply via email to