This is a shortcoming in the (current) implementation of SOAP::Lite. The problem is that the object, implemented as a hash reference, is just serialized as a hash reference. Thus, there is no concern for the order of the keys. But element-order is significant in XML (unless otherwise stated) when using XML Schema, which most web-services (especially Java- and .NET-based ones) use in their WSDL definitions.

At the present time, there is no quick, simple solution to this. You have to write your own serializer, and you have to plug it into SOAP::Lite. I wrote an article for O'Reilly that touches on this in the context of talking to .NET services, but it would apply here, as well. The article is Five Tips for .NET Programming in Perl.

--rjray


In reply to Re: Trouble Passing Objects using SOAP::Lite by rjray
in thread Trouble Passing Objects using SOAP::Lite by fogues

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.