[ 
https://issues.apache.org/jira/browse/ODE-656?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12748474#action_12748474
 ] 

Milinda Lakmal Pathirage commented on ODE-656:
----------------------------------------------

When creating request for the external service, ODE wraps the RPC style request 
with a element which has name equals to the calling operation name. The 
namespace for this element is extracted using binding input(I'm not sure about 
this). But ODE couldn't detect the namesapces you are going to use in other 
parts of the message which was created by user. So the  best thing is to define 
those namespace prefixes in your elements using literal notation. For example, 
you can modify your copy operation like following:

 <bpel:copy>
                <bpel:from>
                    <bpel:literal xml:space="preserve"><Attributes 
xmlns:odens="urn://epages.de/WebService/OrderService/2009/01"  
soapenc:arrayType="xs:string[]" 
type="odens:type_AttributeNames_In"></Attributes></bpel:literal>
                </bpel:from>
                <bpel:to part="Attributes" 
variable="OrderDetailPLRequest"></bpel:to>
            </bpel:copy>
          
Can you try this and let me know the result. 
I can check for a solution from ODE side. Can you please upload test BPEL and a 
service if you have. It'll help us to regenerate this situation. Also Axis2 
doesn't fully support RPC literal and it's better you can use document lietral 
style web services. In that way you can get rid of ODE creating your wrapper 
element. Then you can create whole soap payload in BPEL.

> ODE strips namespaces and namespace prefix in request
> -----------------------------------------------------
>
>                 Key: ODE-656
>                 URL: https://issues.apache.org/jira/browse/ODE-656
>             Project: ODE
>          Issue Type: Bug
>          Components: BPEL Runtime
>    Affects Versions: 1.3.2
>         Environment: Eclipse BPEL Designer, ODE, ...
>            Reporter: Andreas Christiani
>
> Hi!
> It seems that ODE (or Axis?) is deleting namespace declarations and the 
> according namespace prefixes from a variable that is initialized correctly (I 
> gave my best at least). I tried a lot of things to heal this, but nothing 
> worked. The called webservice throws a fault, because it cannot process the 
> input correctly.
> This is the request coming from ODE:
> ######################################################################################
> <?xml version='1.0' encoding='UTF-8'?><soapenv:Envelope 
> xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/";>
> <soapenv:Header>
> <addr:To 
> xmlns:addr="http://www.w3.org/2005/08/addressing";>http://localhost:8090/epages/OSCStore.soap</addr:To>
> <addr:Action 
> xmlns:addr="http://www.w3.org/2005/08/addressing";>urn://epages.de/WebService/OrderService/2009/01/getInfo</addr:Action>
> <addr:ReplyTo xmlns:addr="http://www.w3.org/2005/08/addressing";>
>   <addr:Address>http://www.w3.org/2005/08/addressing/anonymous</addr:Address>
> </addr:ReplyTo>
> <addr:MessageID 
> xmlns:addr="http://www.w3.org/2005/08/addressing";>uuid:hqejbhcnphr4ji9g01nlk2</addr:MessageID>
> </soapenv:Header>
> <soapenv:Body>
> <odens:getInfo xmlns:odens="urn://epages.de/WebService/OrderService/2009/01">
> <Orders arrayType="xs:string[]" type="odens:type_GetInfo_In">
>       <Path type="xs:string">EMPTY2</Path>
> </Orders>
> <Attributes arrayType="xs:string[]" type="odens:type_AttributeNames_In" />
> <AddressAttributes arrayType="xs:string[]" 
> type="odens:type_AttributeNames_In" />
> <LineItemAttributes arrayType="xs:string[]" 
> type="odens:type_AttributeNames_In" />
> <LanguageCodes arrayType="xs:string[]" type="odens:type_LanguageCodes_In" />
> </odens:getInfo>
> </soapenv:Body>
> </soapenv:Envelope>
> ######################################################################################
> It is initialized this way:
> ######################################################################################
> <bpel:assign validate="no" name="Assign">
>             <bpel:copy>
>                 <bpel:from>
>                     <bpel:literal xml:space="preserve"><Orders 
> soapenc:arrayType="xs:string[]" type="odens:type_GetInfo_In">
>       <Path type="xs:string">EMPTY2</Path>
> </Orders></bpel:literal>
>                 </bpel:from>
>                 <bpel:to part="Orders" 
> variable="OrderDetailPLRequest"></bpel:to>
>             </bpel:copy>
>             <bpel:copy>
>                 <bpel:from>
>                     <bpel:literal xml:space="preserve"><Attributes 
> soapenc:arrayType="xs:string[]" 
> type="odens:type_AttributeNames_In"></Attributes></bpel:literal>
>                 </bpel:from>
>                 <bpel:to part="Attributes" 
> variable="OrderDetailPLRequest"></bpel:to>
>             </bpel:copy>
>             <bpel:copy>
>                 <bpel:from>
>                     <bpel:literal xml:space="preserve"><AddressAttributes 
> soapenc:arrayType="xs:string[]" 
> type="odens:type_AttributeNames_In"></AddressAttributes></bpel:literal>
>                 </bpel:from>
>                 <bpel:to part="AddressAttributes" 
> variable="OrderDetailPLRequest"></bpel:to>
>             </bpel:copy>
>             <bpel:copy>
>                 <bpel:from>
>                     <bpel:literal xml:space="preserve"><LineItemAttributes 
> soapenc:arrayType="xs:string[]" 
> type="odens:type_AttributeNames_In"></LineItemAttributes></bpel:literal>
>                 </bpel:from>
>                 <bpel:to part="LineItemAttributes" 
> variable="OrderDetailPLRequest"></bpel:to>
>             </bpel:copy>
>             <bpel:copy>
>                 <bpel:from>
>                     <bpel:literal xml:space="preserve"><LanguageCodes 
> soapenc:arrayType="xs:string[]" 
> type="odens:type_LanguageCodes_In"></LanguageCodes></bpel:literal>
>                 </bpel:from>
>                 <bpel:to part="LanguageCodes" 
> variable="OrderDetailPLRequest"></bpel:to>
>             </bpel:copy>
>         </bpel:assign>
> ######################################################################################
> This modified request works fine, when called from SoapUI:
> ######################################################################################
> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/";>
> <soapenv:Header>
>       <addr:To 
> xmlns:addr="http://www.w3.org/2005/08/addressing";>http://localhost:8090/epages/OSCStore.soap</addr:To>
>       <addr:Action 
> xmlns:addr="http://www.w3.org/2005/08/addressing";>urn://epages.de/WebService/OrderService/2009/01/getInfo</addr:Action>
>       <addr:ReplyTo xmlns:addr="http://www.w3.org/2005/08/addressing";>
>               
> <addr:Address>http://www.w3.org/2005/08/addressing/anonymous</addr:Address>
>       </addr:ReplyTo>
>       <addr:MessageID 
> xmlns:addr="http://www.w3.org/2005/08/addressing";>uuid:hqejbhcnphr4ji9g01nljq</addr:MessageID>
> </soapenv:Header>
> <soapenv:Body>
>       <odens:getInfo 
>               xmlns:odens="urn://epages.de/WebService/OrderService/2009/01"
>               xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/";
>               xmlns:xs="http://www.w3.org/2001/XMLSchema";>
>               <Orders soapenc:arrayType="xs:string[]" 
> type="odens:type_GetInfo_In">
>                       <Path type="xs:string">EMPTY2</Path>
>               </Orders>
>               <Attributes soapenc:arrayType="xs:string[]" 
> type="odens:type_AttributeNames_In" />
>               <AddressAttributes soapenc:arrayType="xs:string[]" 
> type="odens:type_AttributeNames_In" />
>               <LineItemAttributes soapenc:arrayType="xs:string[]" 
> type="odens:type_AttributeNames_In" />
>               <LanguageCodes soapenc:arrayType="xs:string[]" 
> type="odens:type_LanguageCodes_In" />
>       </odens:getInfo>
> </soapenv:Body>
> </soapenv:Envelope>
> ######################################################################################
> On the service side it is only about the namspace prefix soapenc: and xs:.
> I don't have any idea how to declare the namespaces in a way that the 
> according prefixes are preserved in the requests.
> Can anybody help me with this?
> Thanks in advance!
> Andreas

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to