What’s kind of error did you get? -- 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 March 20, 2015 at 8:40:48 PM, pilgrim08 (john.al...@libertymutual.com) wrote: > Thank you Willem. > > I had added the "application/x-www-form-urlencoded" content-type because I > saw it in another thread. Maybe that wasn't a good idea. > > I did try your solution of setting the parameters in the body but it still > doesn't send them as POST parameters. In this case it sends the parameters > in the request body. The web service I am calling is unable to access the > parameters. > > Are there other options/ideas I could try? > > from("timer://runOnce?repeatCount=1") > .onException(Exception.class) > .handled(true) > .process(new GenericExceptionProcessor()) > .end() > .setHeader(Exchange.HTTP_METHOD, constant("POST")) > .setHeader(Exchange.CONTENT_TYPE, > constant("application/x-www-form-urlencoded")) > > .setBody(constant("serviceType=getNextIDFromDB&serviceID=1&dataElementID=814&dataSourceID=50")) > > .to("https://dev-sdsservices-was8/IMSDSWebService/servlet/SDSClientRequestServlet" > > + > "?proxyHost=VDDP03C-EDB4ED9&proxyPort=8888&httpClient.authenticationPreemptive=true" > > + "&authMethod=Basic&authUsername=********&authPassword=********" > + "&httpClient.soTimeout=5000") > .to("file:{{sf.archive.dir}}?fileName=sds-response.xml") > .end(); > > Regards, John > > > > -- > View this message in context: > http://camel.465427.n5.nabble.com/Http-Component-Post-Parameters-tp5764464p5764480.html > > Sent from the Camel - Users mailing list archive at Nabble.com. >