Hello 

I have a camel route like this

from("restlet:http://0.0.0.0:7839/dwb/item?restletMethods=get";)
                .log('MESSAGE RECEIVED AT ITEM SERVICE  ${body}. query
parameters are as follows ${in.header.CamelHttpQuery}')
                .process(new QueryParameterParser())
                .process(new ParseDPCI())
                .to("velocity:velocityTemplates/ItemServiceFormat.vm")
                .log('SOAP Request - ${body}')
                .removeHeaders("*")
                .setHeader("SOAPAction").simple('')
               
.setHeader("Content-Type").constant("application/xml;charset=UTF-8")
               
.to("cxf:http://tmci-stores.target.com:80/TMCI/services/ItemAvailabilityServicePort?dataFormat=MESSAGE";)
                .convertBodyTo(java.lang.String)
                .log('SOAP Response - ${body}')
               
.setProperty("itemAvailability",ns.xpath("//p693:responseBody/p693:itemStoreAvailability/p693:itemAvailabilityStatus/text()"))
               
.setHeader("CamelHttpUri").simple('http://tws.target.com/webapp/wcs/stores/servlet/ItemLookup?IdType=DPCI&ItemId=${property.dpciWithoutHipen}&ResponseGroups=MerchantItemAttributes%2cIACAttributes%2cReviews&AccessKeyId=***********Secret**********************')
               
.to('http://tws.target.com/webapp/wcs/stores/servlet/ItemLookup')
                .convertBodyTo(java.lang.String)       
               
.setProperty("Description",xpath("//Items/Item/ASIN/text()"))
                .to("xquery:xquery/itemavailability.xq")
                .convertBodyTo(java.lang.String)
                .log('Response from Integration layer - ${body}')          
                .end()

For composing the response, I am hitting a soap service as well as a rest
service before returning back to the rest client. Everything works perfect.
In soap UI log, I can see the response received. 

But I see that SOAP UI is not able to show the response message and it keeps
waiting untill the socket timeout happens.

Can someone tell me why it waits for the socket timeout though SOAP UI shows
the response xml received back from the camel route?


Camel Log
--------------
[main] INFO org.apache.camel.spring.SpringCamelContext - Route: route2
started and consuming from:
Endpoint[http://0.0.0.0:7839/dwb/item?restletMethods=GET]
[main] INFO org.apache.camel.spring.SpringCamelContext - Total 2 routes, of
which 2 is started.
[main] INFO org.apache.camel.spring.SpringCamelContext - Apache Camel 2.15.1
(CamelContext: DCIContext) started in 3.091 seconds
[Restlet-1872012709] INFO route2 - MESSAGE RECEIVED AT ITEM SERVICE  . query
parameters are as follows dpci=037-13-0991&storeId=1375
[Restlet-1872012709] INFO route2 - SOAP Request - <soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/";
xmlns:ns="http://schemas.target.com/schemas/Store/ItemAvailabilitySchema/V1/2006-03-28";
xmlns:ns1="http://schemas.target.com/schemas/Store/TMCICommonSchema/V1/2006-03-28";>
   <soapenv:Header/>
   <soapenv:Body>
      <ns:ItemAvailabilityRequestElement>
         <ns:requestHeader>
            <ns1:userID>DWBUSER</ns1:userID>
            <ns1:timeStamp>2010-03-22T00:00:00.000+05:00</ns1:timeStamp>
            <ns1:clientApp>DWB</ns1:clientApp>
            
            <ns1:measID>?</ns1:measID>
            
            <ns1:debug>false</ns1:debug>
         </ns:requestHeader>
         <ns:requestBody>
            
            <ns:storeId>1375</ns:storeId>
            <ns:dpci>
               <ns1:deptID>037</ns1:deptID>
               <ns1:classID>13</ns1:classID>
               <ns1:itemID>0991</ns1:itemID>
            </ns:dpci>
         </ns:requestBody>
      </ns:ItemAvailabilityRequestElement>
   </soapenv:Body>
</soapenv:Envelope>
[default-workqueue-1] INFO route2 - SOAP Response - <soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/";
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/";
xmlns:xsd="http://www.w3.org/2001/XMLSchema";
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";><soapenv:Header/><soapenv:Body><p693:ItemAvailabilityResponseElement
xmlns:p693="http://schemas.target.com/schemas/Store/ItemAvailabilitySchema/V1/2006-03-28";><p693:responseHeader><p529:userID
xmlns:p529="http://schemas.target.com/schemas/Store/TMCICommonSchema/V1/2006-03-28";>DWBUSER</p529:userID><p529:timeStamp
xmlns:p529="http://schemas.target.com/schemas/Store/TMCICommonSchema/V1/2006-03-28";>2016-01-18T07:12:57.552Z</p529:timeStamp><p529:clientApp
xmlns:p529="http://schemas.target.com/schemas/Store/TMCICommonSchema/V1/2006-03-28";>DWB</p529:clientApp><p529:measID
xmlns:p529="http://schemas.target.com/schemas/Store/TMCICommonSchema/V1/2006-03-28";>?</p529:measID><p529:debug
xmlns:p529="http://schemas.target.com/schemas/Store/TMCICommonSchema/V1/2006-03-28";>0</p529:debug></p693:responseHeader><p693:responseBody><p693:itemStoreAvailability><p693:storeID>1375</p693:storeID><p693:itemAvailabilityStatus>3</p693:itemAvailabilityStatus></p693:itemStoreAvailability></p693:responseBody></p693:ItemAvailabilityResponseElement></soapenv:Body></soapenv:Envelope>
[default-workqueue-1] INFO org.apache.camel.builder.xml.XPathBuilder -
Created default XPathFactory org.apache.xpath.jaxp.XPathFactoryImpl@fe9aee8
[default-workqueue-1] WARN org.apache.commons.httpclient.HttpMethodBase -
Cookie rejected: "$Version=0; twsakalb=scs; $Path=/; $Domain=target.com".
Domain attribute "target.com" violates RFC 2109: domain must start with a
dot
[default-workqueue-1] INFO route2 - Response from Integration layer -
<Item><DPCI>037130991</DPCI><Description>B0000A4EW3</Description><Status>TBD</Status><SellingRetail>TBD</SellingRetail><RegularRetail>TBD</RegularRetail><RecallFlag>TBD</RecallFlag><StoreLocation><SalesFloorLoc>TBD</SalesFloorLoc><Schematic>TBD</Schematic></StoreLocation><StoreLocation><SalesFloorLoc>TBD</SalesFloorLoc><Schematic>TBD</Schematic></StoreLocation><storeID>1375</storeID><ItemAvailabilityStatus>3</ItemAvailabilityStatus></Item>
Jan 18, 2016 12:43:05 PM org.restlet.engine.log.LogFilter afterHandle
INFO: 2016-01-18        12:43:05        0:0:0:0:0:0:0:1 -       -       7839    
GET     /dwb/item
dpci=037-13-0991&storeId=1375   200     9551    0       9400    
http://localhost:7839
Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko)
Chrome/47.0.2526.106 Safari/537.36      -








Jetty Log in SOAP UI
----------------------
Mon Jan 18 12:44:21 IST 2016:DEBUG:>> "GET
/dwb/item?dpci=037-13-0991&storeId=1375 HTTP/1.1[\r][\n]"
Mon Jan 18 12:44:21 IST 2016:DEBUG:>> "Accept-Encoding:
gzip,deflate[\r][\n]"
Mon Jan 18 12:44:21 IST 2016:DEBUG:>> "Host: localhost:7839[\r][\n]"
Mon Jan 18 12:44:21 IST 2016:DEBUG:>> "Connection: Keep-Alive[\r][\n]"
Mon Jan 18 12:44:21 IST 2016:DEBUG:>> "User-Agent: Apache-HttpClient/4.1.1
(java 1.5)[\r][\n]"
Mon Jan 18 12:44:21 IST 2016:DEBUG:>> "[\r][\n]"
Mon Jan 18 12:44:24 IST 2016:DEBUG:<< "HTTP/1.1 200 OK[\r][\n]"
Mon Jan 18 12:44:24 IST 2016:DEBUG:<< "Server:
Restlet-Framework/2.2.3[\r][\n]"
Mon Jan 18 12:44:24 IST 2016:DEBUG:<< "Lite-checkout: N[\r][\n]"
Mon Jan 18 12:44:24 IST 2016:DEBUG:<< "Connection: keep-alive[\r][\n]"
Mon Jan 18 12:44:24 IST 2016:DEBUG:<< "Pragma: No-cache[\r][\n]"
Mon Jan 18 12:44:24 IST 2016:DEBUG:<< "X-powered-by: Servlet/3.0[\r][\n]"
Mon Jan 18 12:44:24 IST 2016:DEBUG:<< "Keep-alive: timeout=10,
max=100[\r][\n]"
Mon Jan 18 12:44:24 IST 2016:DEBUG:<< "Date: Mon, 18 Jan 2016 07:14:24
GMT[\r][\n]"
Mon Jan 18 12:44:24 IST 2016:DEBUG:<< "Responsecontext:
{org.apache.cxf.message.Message.PROTOCOL_HEADERS={connection=[Keep-Alive],
Content-Language=[en-US], Content-Length=[1298], content-type=[text/xml;
charset=utf-8], Date=[Mon, 18 Jan 2016 07:14:22 GMT],
Keep-Alive=[timeout=10, max=100], X-Powered-By=[Servlet/3.0]},
org.apache.cxf.ws.policy.AssertionInfoMap={},
org.apache.cxf.transport.Conduit=conduit: class
org.apache.cxf.transport.http.URLConnectionHTTPConduit1996323274target:
http://tmci-stores.target.com:80/TMCI/services/ItemAvailabilityServicePort,
org.apache.cxf.client=true,
org.apache.cxf.binding.soap.SoapVersion=org.apache.cxf.binding.soap.Soap11@b40fa89,
org.apache.cxf.message.Message.ENCODING=UTF-8,
org.apache.cxf.message.inbound=true,
org.apache.cxf.message.Message.RESPONSE_CODE=200, Content-Type=text/xml;
charset=utf-8}[\r][\n]"
Mon Jan 18 12:44:24 IST 2016:DEBUG:<< "Content-type:
application/xml;charset=UTF-8[\r][\n]"
Mon Jan 18 12:44:24 IST 2016:DEBUG:<< "Content-language: en-US[\r][\n]"
Mon Jan 18 12:44:24 IST 2016:DEBUG:<< "Content-length: 9550[\r][\n]"
Mon Jan 18 12:44:24 IST 2016:DEBUG:<< "Expires: Mon, 18 Jan 2016 07:14:24
GMT[\r][\n]"
Mon Jan 18 12:44:24 IST 2016:DEBUG:<< "Cache-control: no-cache,
no-store[\r][\n]"
Mon Jan 18 12:44:24 IST 2016:DEBUG:<< "Set-cookie:
[estoreJSESSIONID=0000q2w1tOwJXz6fGjCqEi7M5GW:01h3129; Path=/,
WC_PERSISTENT=r7x4YgE3zmKAopo%2bFSJlCHJDLkA%3d%0a%3b2016%2d01%2d18+07%3a14%3a23%2e958%5f1453101263958%2d2831%5f0;
Expires=Tue, 17-Jan-17 07:14:23 GMT; Path=/; Domain=.target.com,
WC_SESSION_ESTABLISHED=true; Path=/; Domain=.target.com,
WC_PERSISTENT=2f14DSabuKuIP2ll9vvyY0Q%2b6o0%3d%0a%3b2016%2d01%2d18+07%3a14%3a23%2e992%5f1453101263958%2d2831%5f10151%5f%2d1002%2c%2d1%2cUSD%5f10151;
Expires=Tue, 17-Jan-17 07:14:23 GMT; Path=/; Domain=.target.com,
WC_ACTIVEPOINTER=%2d1%2c10151; Path=/; Domain=.target.com,
WC_USERACTIVITY_-1002=%2d1002%2c10151%2cnull%2cnull%2cnull%2cnull%2cnull%2cnull%2cnull%2cnull%2cSP%2fIoOzQQLz52ShgaAyMntwmIs%2bagX69WemImoSkhN9Cb1vkihrIKG2uz2xiAt7x5po1CV%2fuS919%0a%2bRq6jb4lGI7bHW733etDU6L2UM%2fI82f010teSr0je4szY0dV61VSQM668muAN89pOKcmMqVog9xU%0aey%2bacO2wi0NIGHb1cA2nd36B2iFpJXI9v2i6nwUU4u20YdzSDXkvenvITldNZQ%3d%3d;
Path=/; Domain=.target.com,
WC_GENERIC_ACTIVITYDATA=[132414167448%3atrue%3afalse%3a0%3atq2316Xpmq96Gs%2fivJgsuBt6VLY%3d][com.ibm.commerce.context.audit.AuditContext|1453101263958%2d2831][CTXSETNAME|Store][com.ibm.commerce.context.globalization.GlobalizationContext|%2d1%26USD%26%2d1%26USD][com.ibm.commerce.catalog.businesscontext.CatalogContext|10051%26null%26false%26false%26false][com.ibm.commerce.context.base.BaseContext|10151%26%2d1002%26%2d1002%2610][com.ibm.commerce.context.entitlement.EntitlementContext|4000000000000000005%264000000000000000005%26null%26%2d2000%26null%26null%26null];
Path=/; Domain=.target.com, twsakalb=scs;path=/;domain=target.com;][\r][\n]"
Mon Jan 18 12:44:24 IST 2016:DEBUG:<< "[\r][\n]"
Mon Jan 18 12:44:24 IST 2016:DEBUG:<<
"<Item><DPCI>037130991</DPCI><Description>B0000A4EW3</Description><Status>TBD</Status><SellingRetail>TBD</SellingRetail><RegularRetail>TBD</RegularRetail><RecallFlag>TBD</RecallFlag><StoreLocation><SalesFloorLoc>TBD</SalesFloorLoc><Schematic>TBD</Schematic></StoreLocation><StoreLocation><SalesFloorLoc>TBD</SalesFloorLoc><Schematic>TBD</Schematic></StoreLocation><storeID>1375</storeID><ItemAvailabilityStatus>3</ItemAvailabilityStatus></Item>"
Mon Jan 18 12:44:38 IST 2016:DEBUG:>> "GET
/dwb/item?dpci=037-13-0991&storeId=1375 HTTP/1.1[\r][\n]"
Mon Jan 18 12:44:38 IST 2016:DEBUG:>> "Accept-Encoding:
gzip,deflate[\r][\n]"
Mon Jan 18 12:44:38 IST 2016:DEBUG:>> "Host: localhost:7839[\r][\n]"
Mon Jan 18 12:44:38 IST 2016:DEBUG:>> "Connection: Keep-Alive[\r][\n]"
Mon Jan 18 12:44:38 IST 2016:DEBUG:>> "User-Agent: Apache-HttpClient/4.1.1
(java 1.5)[\r][\n]"
Mon Jan 18 12:44:38 IST 2016:DEBUG:>> "[\r][\n]"
Mon Jan 18 12:44:40 IST 2016:DEBUG:<< "HTTP/1.1 200 OK[\r][\n]"
Mon Jan 18 12:44:40 IST 2016:DEBUG:<< "Server:
Restlet-Framework/2.2.3[\r][\n]"
Mon Jan 18 12:44:40 IST 2016:DEBUG:<< "Lite-checkout: N[\r][\n]"
Mon Jan 18 12:44:40 IST 2016:DEBUG:<< "Connection: keep-alive[\r][\n]"
Mon Jan 18 12:44:40 IST 2016:DEBUG:<< "Pragma: No-cache[\r][\n]"
Mon Jan 18 12:44:40 IST 2016:DEBUG:<< "X-powered-by: Servlet/3.0[\r][\n]"
Mon Jan 18 12:44:40 IST 2016:DEBUG:<< "Keep-alive: timeout=10,
max=100[\r][\n]"
Mon Jan 18 12:44:40 IST 2016:DEBUG:<< "Date: Mon, 18 Jan 2016 07:14:40
GMT[\r][\n]"
Mon Jan 18 12:44:40 IST 2016:DEBUG:<< "Responsecontext:
{org.apache.cxf.message.Message.PROTOCOL_HEADERS={connection=[Keep-Alive],
Content-Language=[en-US], Content-Length=[1298], content-type=[text/xml;
charset=utf-8], Date=[Mon, 18 Jan 2016 07:14:39 GMT],
Keep-Alive=[timeout=10, max=100], X-Powered-By=[Servlet/3.0]},
org.apache.cxf.ws.policy.AssertionInfoMap={},
org.apache.cxf.transport.Conduit=conduit: class
org.apache.cxf.transport.http.URLConnectionHTTPConduit1996323274target:
http://tmci-stores.target.com:80/TMCI/services/ItemAvailabilityServicePort,
org.apache.cxf.client=true,
org.apache.cxf.binding.soap.SoapVersion=org.apache.cxf.binding.soap.Soap11@b40fa89,
org.apache.cxf.message.Message.ENCODING=UTF-8,
org.apache.cxf.message.inbound=true,
org.apache.cxf.message.Message.RESPONSE_CODE=200, Content-Type=text/xml;
charset=utf-8}[\r][\n]"
Mon Jan 18 12:44:40 IST 2016:DEBUG:<< "Content-type:
application/xml;charset=UTF-8[\r][\n]"
Mon Jan 18 12:44:40 IST 2016:DEBUG:<< "Content-language: en-US[\r][\n]"
Mon Jan 18 12:44:40 IST 2016:DEBUG:<< "Content-length: 9551[\r][\n]"
Mon Jan 18 12:44:40 IST 2016:DEBUG:<< "Expires: Mon, 18 Jan 2016 07:14:40
GMT[\r][\n]"
Mon Jan 18 12:44:40 IST 2016:DEBUG:<< "Cache-control: no-cache,
no-store[\r][\n]"
Mon Jan 18 12:44:40 IST 2016:DEBUG:<< "Set-cookie:
[estoreJSESSIONID=0000tkm7hHIqvQyYDAHU6Wc1oU2:06h3264; Path=/,
WC_PERSISTENT=tUG6kiXKp%2fCUUDT5j%2bbxdVGTcaQ%3d%0a%3b2016%2d01%2d18+07%3a14%3a40%2e261%5f1453101280261%2d2797%5f0;
Expires=Tue, 17-Jan-17 07:14:40 GMT; Path=/; Domain=.target.com,
WC_SESSION_ESTABLISHED=true; Path=/; Domain=.target.com,
WC_PERSISTENT=2zjsHpxzqETGYgziU%2f4HysEs%2fQE%3d%0a%3b2016%2d01%2d18+07%3a14%3a40%2e281%5f1453101280261%2d2797%5f10151%5f%2d1002%2c%2d1%2cUSD%5f10151;
Expires=Tue, 17-Jan-17 07:14:40 GMT; Path=/; Domain=.target.com,
WC_ACTIVEPOINTER=%2d1%2c10151; Path=/; Domain=.target.com,
WC_USERACTIVITY_-1002=%2d1002%2c10151%2cnull%2cnull%2cnull%2cnull%2cnull%2cnull%2cnull%2cnull%2cl%2fIhBoGgZL9HasFY7VtG4H27RiaDLjY2Ogwe40F0ZN8scQ7vAcgTIn0c2xQpQ%2bop%2f3%2bq14ySVeHh%0aDX0PbPTDgpaQDLEpgqeKbmN8XiQhogQX1iuTvcJI0HYCh0WYQnlFygtx1PQzLOP%2bdtkV04ISE%2fWs%0akjixR9ZYRL5hHAJdi1w9zHePLO0FXEq19SCuLoc5dXWSWkmLA25MsKn0E5aFTg%3d%3d;
Path=/; Domain=.target.com,
WC_GENERIC_ACTIVITYDATA=[132414417047%3atrue%3afalse%3a0%3a0zmVoBuRZ4wvkLxd8SBWZBtTEIc%3d][com.ibm.commerce.context.audit.AuditContext|1453101280261%2d2797][CTXSETNAME|Store][com.ibm.commerce.context.globalization.GlobalizationContext|%2d1%26USD%26%2d1%26USD][com.ibm.commerce.catalog.businesscontext.CatalogContext|10051%26null%26false%26false%26false][com.ibm.commerce.context.base.BaseContext|10151%26%2d1002%26%2d1002%2610][com.ibm.commerce.context.entitlement.EntitlementContext|4000000000000000005%264000000000000000005%26null%26%2d2000%26null%26null%26null];
Path=/; Domain=.target.com, twsakalb=scs;path=/;domain=target.com;][\r][\n]"
Mon Jan 18 12:44:40 IST 2016:DEBUG:<< "[\r][\n]"
Mon Jan 18 12:44:40 IST 2016:DEBUG:<<
"<Item><DPCI>037130991</DPCI><Description>B0000A4EW3</Description><Status>TBD</Status><SellingRetail>TBD</SellingRetail><RegularRetail>TBD</RegularRetail><RecallFlag>TBD</RecallFlag><StoreLocation><SalesFloorLoc>TBD</SalesFloorLoc><Schematic>TBD</Schematic></StoreLocation><StoreLocation><SalesFloorLoc>TBD</SalesFloorLoc><Schematic>TBD</Schematic></StoreLocation><storeID>1375</storeID><ItemAvailabilityStatus>3</ItemAvailabilityStatus></Item>"




-----
Reji Mathews
Sr. Developer - Middleware Integration / SOA ( Open Source - Apache Camel & 
Jboss Fuse ESB | Mule ESB )
LinkedIn - http://in.linkedin.com/pub/reji-mathews/31/9a2/40a
Twitter - reji_mathews
--
View this message in context: 
http://camel.465427.n5.nabble.com/Restlet-Response-Decoding-issue-tp5776382.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Reply via email to