camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "William Tam (JIRA)" <j...@apache.org>
Subject [jira] Issue Comment Edited: (CAMEL-3778) Support CXF Dispatch mode at CXF Endpoints
Date Sun, 20 Mar 2011 04:01:29 GMT

    [ https://issues.apache.org/jira/browse/CAMEL-3778?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13008874#comment-13008874
] 

William Tam edited comment on CAMEL-3778 at 3/20/11 4:01 AM:
-------------------------------------------------------------

Here is the mail thread related to this issue.

http://camel.465427.n5.nabble.com/camel-cxf-endpoint-without-wsdl-and-serviceClass-possible-td3385901.html#a3387482

@Aki
I made some updates to your patch.  Please review CAMEL-3778.patch (ignore CAMEL-3386.patch)
and provide your feedbacks.  

* I added a boolean option "skipPayloadMessagePartCheck" to switch on/off the check for expected
message parts in CxfEndpoint.setParameters().  (To other readers, the enforcement of the check
precludes sending arbitrary payload in PAYLOAD/MESSAGE mode as Aki has found out.)  The default
should be false (i.e. do checking).  In your patch, to skip the checking when it sees null
part name is probably not a good idea.  

* I avoided the hard coded CXF operation info in the CxfEndpoint class by JAXWS annotations
in the Default SEI (i.e. dummy serviceClass), which makes it cleaner and shielded from CXF
model "APIs" changes.



      was (Author: wtam):
    Here is the mail thread related to this issue.

http://camel.465427.n5.nabble.com/camel-cxf-endpoint-without-wsdl-and-serviceClass-possible-td3385901.html#a3387482

@Aki
I made some updates to your patch.  Please review CAMEL-3386.patch (I messed up the number)
and provide your feedbacks.  

* I added a boolean option "skipPayloadMessagePartCheck" to switch on/off the check for expected
message parts in CxfEndpoint.setParameters().  (To other readers, the enforcement of the check
precludes sending arbitrary payload in PAYLOAD/MESSAGE mode as Aki has found out.)  The default
should be false (i.e. do checking).  In your patch, to skip the checking when it sees null
part name is probably not a good idea.  

* I avoided the hard coded CXF operation info in the CxfEndpoint class by JAXWS annotations
in the Default SEI (i.e. dummy serviceClass), which makes it cleaner and shielded from CXF
model "APIs" changes.


  
> Support CXF Dispatch mode at CXF Endpoints
> ------------------------------------------
>
>                 Key: CAMEL-3778
>                 URL: https://issues.apache.org/jira/browse/CAMEL-3778
>             Project: Camel
>          Issue Type: New Feature
>          Components: camel-cxf
>    Affects Versions: 2.6.0
>            Reporter: Aki Yoshida
>            Assignee: William Tam
>             Fix For: 2.8.0
>
>         Attachments: CAMEL-3386.patch, CAMEL-3778.patch, patch-20110310.txt, tests.zip
>
>
> Hi,
> Sometime ago I asked in this mailing list whether it is possible to use the dispatch
mode of CXF in the Camel's CXF endpoint. The answer was no. But I wanted to have the CXF dispatch
mode so that I can run SOAP intermediary/gateway scenarios with CXF features enabled and send
arbitrary SOAP messages from a single endpoint.
> Now I have implemented this feature and I would like to hear what you think.
> In short, I modified CxfSpringEndpoint and CxfEndpoint so that Camel uses the CXF dispatch
mode when no service class nor WSDL is specified in the endpoint configuration. For example,
you can configure the endpoint as:
> {code:xml}
>   <cxf:cxfEndpoint id="serviceEndpoint"
> 		   address="http://localhost:9000/SoapContext/GreeterPort"
> 		   endpointName="s:GreeterPort" 
> 		   serviceName="s:GreeterService"
> 		   bus="#bus">
>     <cxf:properties>
>       <entry key="dataFormat" value="PAYLOAD"/>
>     </cxf:properties>
>   </cxf:cxfEndpoint>
> {code}
> In this case, the endpoint is set up for the dispatch mode. The dispatch mode supports
two operations Invoke and InvokeOneWay and the default operation is Invoke. You can change
the operation by simply setting the camel header operationName.
> I added two unit tests classes to show how the dispatch mode works for both PAYLOAD and
MESSAGE data format.
> I am attached all the file to this ticket. I would appreciate if you can comment on this
feature.
> Thanks.
> Regards, Aki

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message