Camel 2.14.0 Matrix Params are missing

2014-11-26 Thread Kumaran
Hi 

This is my first post in the forum, We are using camel 2.14.0 version and
need to proxy the web service. i have posted to configurations below
followed from the camel-proxy-example.
 
cxf:rsServer id=rsServer address=/proxyServer
loggingFeatureEnabled=true loggingSizeLimit=20 skipFaultLogging=true 
cxf:serviceBeans  
  bean class=com.test.PServerImpl /
  bean class=com.test.PServerImpl / 
/cxf:serviceBeans
/cxf:rsServer
 
cxf:rsClient id=rsClient address=http://localhost:29090/MyServer/; 
loggingFeatureEnabled=true loggingSizeLimit=20 skipFaultLogging=true  
/cxf:rsClient


  
camelContext id=camel xmlns=http://camel.apache.org/schema/spring;
route
from uri=cxfrs://bean://rsServer?bindingStyle=SimpleConsumer/ 
to uri=cxfrs://bean://rsClient/ 
/route 
/camelContext

But we can see that the Matrix Parameters are completely stripped away in
the CxfRsProducer.  I know that if we use SimpleConsumer as the binding
style the matrix param will be sent as header params.  But shouldn't the
matrix params part of the URL.


ID: 15
Address:
http://localhost:8001/test/services/proxyServer/boxing;state=Current
Http-Method: GET
Content-Type: 
Headers: {Accept=[application/xml], accept-encoding=[gzip, deflate],
accept-language=[en-us], Authorization=[], connection=[keep-alive],
Content-Length=[0], Content-Type=[null], host=[localhost:8001]}
-- 

---
ID: 16
Address: http://localhost:29090/MyServer/boxing
Http-Method: GET
Content-Type: */*
Headers: {Accept=[application/xml], *state=[Current]*,  user-agent=[xx],
accept-encoding=[gzip, deflate], Content-Length=[0], Authorization=[Bearer
fff8ed5e-5509-4116-8fde-6523b0e60144],
org.apache.cxf.request.uri=[/services/proxyServer/boxing;state=Current],
host=[localhost:8001], connection=[keep-alive], accept-language=[en-us],
org.apache.cxf.message.Message.PATH_INFO=[/boxing],
org.apache.cxf.request.method=[GET], Content-Type=[*/*]}
 
 
I have came across similar issue posted in the past.   CAMEL-5405 CXF
Transport loses HTTP Matrix parameters
http://camel.465427.n5.nabble.com/CXFRS-URL-Matrix-Parameters-seemingly-stripped-away-td5714486.html
   
But we are using camel 2.14.0 version.

Can somebody help us on resolving this issue ?


Thanks in Advance.
-Kumaran




--
View this message in context: 
http://camel.465427.n5.nabble.com/Camel-2-14-0-Matrix-Params-are-missing-tp5759668.html
Sent from the Camel - Users mailing list archive at Nabble.com.


Re: Camel 2.14.0 Matrix Params are missing

2014-11-26 Thread Sergey Beryozkin

Hi

I agree it is a CXFRS producer bug that matrix parameters are lost.
CAMEL-5405 was addressing a server side issue.
I'll have a look.

In meantime - please consider using an alternative Camel HTTP centric 
component - may be REST DSL ? or if it is feasible then pass the options 
as path or query parameters


Thanks, Sergey

On 26/11/14 20:09, Kumaran wrote:

Hi

This is my first post in the forum, We are using camel 2.14.0 version and
need to proxy the web service. i have posted to configurations below
followed from the camel-proxy-example.

cxf:rsServer id=rsServer address=/proxyServer
loggingFeatureEnabled=true loggingSizeLimit=20 skipFaultLogging=true 
cxf:serviceBeans
   bean class=com.test.PServerImpl /
   bean class=com.test.PServerImpl /
 /cxf:serviceBeans
/cxf:rsServer

cxf:rsClient id=rsClient address=http://localhost:29090/MyServer/;
loggingFeatureEnabled=true loggingSizeLimit=20 skipFaultLogging=true
/cxf:rsClient



camelContext id=camel xmlns=http://camel.apache.org/schema/spring;
route
from uri=cxfrs://bean://rsServer?bindingStyle=SimpleConsumer/
to uri=cxfrs://bean://rsClient/
/route
/camelContext

But we can see that the Matrix Parameters are completely stripped away in
the CxfRsProducer.  I know that if we use SimpleConsumer as the binding
style the matrix param will be sent as header params.  But shouldn't the
matrix params part of the URL.


ID: 15
Address:
http://localhost:8001/test/services/proxyServer/boxing;state=Current
Http-Method: GET
Content-Type:
Headers: {Accept=[application/xml], accept-encoding=[gzip, deflate],
accept-language=[en-us], Authorization=[], connection=[keep-alive],
Content-Length=[0], Content-Type=[null], host=[localhost:8001]}
--

---
ID: 16
Address: http://localhost:29090/MyServer/boxing
Http-Method: GET
Content-Type: */*
Headers: {Accept=[application/xml], *state=[Current]*,  user-agent=[xx],
accept-encoding=[gzip, deflate], Content-Length=[0], Authorization=[Bearer
fff8ed5e-5509-4116-8fde-6523b0e60144],
org.apache.cxf.request.uri=[/services/proxyServer/boxing;state=Current],
host=[localhost:8001], connection=[keep-alive], accept-language=[en-us],
org.apache.cxf.message.Message.PATH_INFO=[/boxing],
org.apache.cxf.request.method=[GET], Content-Type=[*/*]}


I have came across similar issue posted in the past.   CAMEL-5405 CXF
Transport loses HTTP Matrix parameters
http://camel.465427.n5.nabble.com/CXFRS-URL-Matrix-Parameters-seemingly-stripped-away-td5714486.html
But we are using camel 2.14.0 version.

Can somebody help us on resolving this issue ?


Thanks in Advance.
-Kumaran




--
View this message in context: 
http://camel.465427.n5.nabble.com/Camel-2-14-0-Matrix-Params-are-missing-tp5759668.html
Sent from the Camel - Users mailing list archive at Nabble.com.




--
Sergey Beryozkin

Talend Community Coders
http://coders.talend.com/

Blog: http://sberyozkin.blogspot.com


Re: Camel 2.14.0 Matrix Params are missing

2014-11-26 Thread Kumaran
Hi  Sergey  

Thanks for the quick reply and taking a look at this issue. I will not be
able to change the real REST service signature.

Meanwhile i was going through REST DSL option suggestion.  The
camel-netty-http, camel-jetty, camel-restlet, camel-servlet,
camel-spark-rest   components documentation doesn't talked about
MatrixParam, i can see some docs related to query param.  i really doubts
even if i start using any of these components i will sendup in the same
Matrix param issue.

Any pointer or samples related to REST producer with Matrix param in camel
2.14  will be great helpful.

Just thinking like headerfilter  can we customize the URL also ?





--
View this message in context: 
http://camel.465427.n5.nabble.com/Camel-2-14-0-Matrix-Params-are-missing-tp5759668p5759675.html
Sent from the Camel - Users mailing list archive at Nabble.com.


Re: Camel 2.14.0 Matrix Params are missing

2014-11-26 Thread Kumaran
Hi Sergey

I had a fix for this issue to support Matrix Parameter Could you validate.

CxfRsProducer.java
http://camel.465427.n5.nabble.com/file/n5759678/CxfRsProducer.java  

Added new methods like setupClientMatrix,getMatrixParametersFromMatrixString

Thanks
Kumaran



--
View this message in context: 
http://camel.465427.n5.nabble.com/Camel-2-14-0-Matrix-Params-are-missing-tp5759668p5759678.html
Sent from the Camel - Users mailing list archive at Nabble.com.


Re: Camel 2.14.0 Matrix Params are missing

2014-11-26 Thread Willem Jiang
Hi Kumaran,

Thanks for your contribution.
Could you create a JIRA[1] and submit the diff patch to it?
It could be more easy for us to track the issue and apply the patch.

--  
Willem Jiang

Red Hat, Inc.
Web: http://www.redhat.com
Blog: http://willemjiang.blogspot.com (English)
http://jnn.iteye.com (Chinese)
Twitter: willemjiang  
Weibo: 姜宁willem



On November 27, 2014 at 9:47:05 AM, Kumaran (mail2dkuma...@gmail.com) wrote:
 Hi Sergey
  
 I had a fix for this issue to support Matrix Parameter Could you validate.
  
 CxfRsProducer.java
  
  
 Added new methods like setupClientMatrix,getMatrixParametersFromMatrixString  
  
 Thanks
 Kumaran
  
  
  
 --
 View this message in context: 
 http://camel.465427.n5.nabble.com/Camel-2-14-0-Matrix-Params-are-missing-tp5759668p5759678.html
   
 Sent from the Camel - Users mailing list archive at Nabble.com.