[
https://issues.apache.org/jira/browse/CAMEL-7503?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14051140#comment-14051140
]
ASF GitHub Bot commented on CAMEL-7503:
---------------------------------------
GitHub user ancosen opened a pull request:
https://github.com/apache/camel/pull/208
CAMEL-7503 PAYLOAD Producer select first available operation if
OPERATION_NAME is not specified
Hi,
This PR is related to https://issues.apache.org/jira/browse/CAMEL-7503
I just added an info log line.
Bye,
Andrea
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/ancosen/camel fix-Camel-7503
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/camel/pull/208.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #208
----
commit c4f98205d9c9bae52df5c08782d0b92a2d38606b
Author: ancosen <[email protected]>
Date: 2014-07-03T07:16:07Z
Fixes CAMEL-7503 by adding a simple INFO level log line
----
> PAYLOAD Producer select first available operation if OPERATION_NAME don't
> specified
> -----------------------------------------------------------------------------------
>
> Key: CAMEL-7503
> URL: https://issues.apache.org/jira/browse/CAMEL-7503
> Project: Camel
> Issue Type: Bug
> Components: camel-cxf
> Affects Versions: 2.13.0
> Reporter: Alexey Markevich
> Assignee: Willem Jiang
>
> Webservice [1] contains two operations.
> Following route works:
> from("timer:cTimer_1?period=1&repeatCount=1&delay=1")
> .setBody().constant("<web:GetWeather
> xmlns:web='http://www.webserviceX.NET'><web:CityName>Minsk</web:CityName></web:GetWeather>")
> .to("cxf://http://www.webservicex.net/globalweather.asmx?wsdlURL=F:/globalweather.wsdl&dataFormat=PAYLOAD&serviceName={http://www.webserviceX.NET}GlobalWeather&endpointName={http://www.webserviceX.NET}GlobalWeatherSoap")
> .to("log:cLog_1?level=INFO")
> But with body
> <web:GetCitiesByCountry
> xmlns:web='http://www.webserviceX.NET'><web:CountryName>Belarus</web:CountryName></web:GetCitiesByCountry>
> there is exception [2].
> Looking into the sources [3] I found that first available opration used.
> Expected that operation lookup is based on payload root element (which is
> different for operations)
> 1. http://www.webservicex.net/globalweather.asmx?WSDL
> 2.
> [WARN ]: org.apache.camel.component.timer.TimerConsumer - Error processing
> exchange. Exchange[Message: <web:GetCitiesByCountry
> xmlns:web='http://www.webserviceX.NET'><web:CountryName>Belarus</web:CountryName></web:GetCitiesByCountry>].
> Caused by: [java.lang.IllegalArgumentException - The PayLoad elements cannot
> fit with the message parts of the BindingOperation. Please check the
> BindingOperation and PayLoadMessage.]
> java.lang.IllegalArgumentException: The PayLoad elements cannot fit with the
> message parts of the BindingOperation. Please check the BindingOperation and
> PayLoadMessage.
> at
> org.apache.camel.component.cxf.CxfEndpoint$CamelCxfClientImpl.setParameters(CxfEndpoint.java:1011)
> at org.apache.cxf.endpoint.ClientImpl.doInvoke(ClientImpl.java:526)
> at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:472)
> at
> org.apache.camel.component.cxf.CxfProducer.process(CxfProducer.java:112)
> at
> org.apache.camel.processor.SendProcessor.process(SendProcessor.java:113)
> at
> org.apache.camel.management.InstrumentationProcessor.process(InstrumentationProcessor.java:72)
> at
> org.apache.camel.processor.RedeliveryErrorHandler.process(RedeliveryErrorHandler.java:398)
> at
> org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)
> at org.apache.camel.processor.Pipeline.process(Pipeline.java:118)
> at org.apache.camel.processor.Pipeline.process(Pipeline.java:80)
> at
> org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)
> at
> org.apache.camel.component.timer.TimerConsumer.sendTimerExchange(TimerConsumer.java:139)
> at
> org.apache.camel.component.timer.TimerConsumer$1.run(TimerConsumer.java:64)
> at java.util.TimerThread.mainLoop(Timer.java:555)
> at java.util.TimerThread.run(Timer.java:505)
> 3.
> https://github.com/apache/camel/blob/master/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/CxfProducer.java#L344
--
This message was sent by Atlassian JIRA
(v6.2#6252)