Hi Claus,
There is a way to set the CxfEndpoint's data format by using the
properties elements.
<cxf:cxfEndpoint id="testEndpoint" address="http://localhost:9000/router"
serviceClass="org.apache.camel.component.cxf.HelloService"
endpointName="s:PortName"
serviceName="s:ServiceName"
xmlns:s="http://www.example.com/test">
<cxf:properties>
<entry key="dataFormat" value="MESSAGE"/>
<entry key="setDefaultBus" value="true"/>
</cxf:properties>
Current camel-cxf is already support this feature last month , I should
update wiki page at that moment :(.
Willem
Claus Ibsen wrote:
Hi Willem
Well I am glad to back out in the world after 1½ year in the cage with an
"enterprise product" ;)
I don't fully understand your answer. So I try with a few more questions.
POJO is the default data format as I understand it. POJO is the java source
code generated by wsdl2java just as we know it from AXIS or similar products
that does this.
If for instance I want to work with the XML then I could use MESSAGE dataformat and use xpath to retrieve my data?
And RAW is good for logging what you got from the client etc? Can be used for
dispute between parties, such as client denying that they sent XXX but if you
have logged the RAW message then you can prove that they did in fact send XXX.
So in Camel the only way to configure dataformat is to use the Java DSL with
the very long uri configuration?
Shouldn't it be possible to configure CXF in Camel with XML? I would imagine
that most end-users of Camel and CXF would configure it using the XML?
If so maybe we should create a ticket for Camel 1.5 so we can try to find a
solution to this?
Med venlig hilsen
Claus Ibsen
......................................
Silverbullet
Skovsgårdsvænget 21
8362 Hørning
Tlf. +45 2962 7576
Web: www.silverbullet.dk
-----Original Message-----
From: Willem Jiang [mailto:[EMAIL PROTECTED]
Sent: 13. juli 2008 04:33
To: [email protected]
Subject: Re: camel-cxf - dataFormat configuration in spring xml
Hi Claus,
Welcome to the CXF world , although its 2.0 just released for a year :)
You can configure the DataFormat property by using the URL option[1],
but you can't configure that property in the CXFEndpointBean[2].
Because I reused the AbstractWSDLBasedEndpointFactory in
CXFEndpointBean, if I add the setDataFormat method in CXFEndpointBean, I
can't configure the CXF endpoint with CXFEndpoingBean.
[1]http://cwiki.apache.org/CAMEL/cxf.html
[2]https://svn.apache.org/repos/asf/activemq/camel/trunk/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/spring/CxfEndpointBean.java
Willem
Claus Ibsen wrote:
Hi Willem
Forgive my ignorance but I am a novelty user on CXF. I had been trolled in a
fullblown custom platform for the last 1½ years or so, where CXF wasn't
possible to use.
Before the time AXIS was the dominating choice.
I am working on my web example and have a webservice endpoint configured using
spring xml as below:
<cxf:cxfEndpoint id="routerEndpoint" address="/incident"
wsdlURL="/WEB-INF/wsdl/report_incident.xml"
serviceClass="org.apache.camel.example.reportincident.ReportIncidentImpl"
endpointName="s:ReportIncidentPort"
serviceName="s:ReportIncidentService"
xmlns:s="http://reportincident.example.camel.apache.org"
/>
I was wondering that there isn't an attribute for dataFormat as there is in the
camel java DSL configuration. As it defaults to POJO I am set to go, but what
if I want MESSAGE?
Med venlig hilsen
Claus Ibsen
......................................
Silverbullet
Skovsgårdsvænget 21
8362 Hørning
Tlf. +45 2962 7576
Web: www.silverbullet.dk