My SOAP::Lite gets a faultcode "Part content ID cannot be blank for non root MIME parts" when I do plain-vanilla SOAP attachments:

my $packager = SOAP::Lite::Packager::MIME->new; my $cmdService = SOAP::Lite ->packager($packager) ->parts([$entity]) ->uri($cmdNamespace) ->proxy($cmdEndpoint); my $cmdResponse = $cmdService->call( @argumentList

I saw a web page that suggests that Axis2 always gives this error when someone forgets that line terminations are \r\n and not just \n. My HTTP message looks about right, but I cannot see the missing \r-s, of course. I posted this at the end (company name changed, and the problem is not the encoding.)

Is there a problem with the code? Or is there a problem with SOAP::Lite::Packager? I looked at Entity.pm and I see lots of \n and not a single \r\n.

SOAP::Transport::HTTP::Client::send_receive: POST https://localhost:98 +43/services/CLITunnelService HTTP/1.1 Accept: text/xml Accept: multipart/* Accept: application/soap Content-Length: 1664 Content-Type: Multipart/Related; type="text/xml"; start="<main_envelop +e>"; boundary="----------=_1257541705-5420-0"; charset=utf-8 SOAPAction: "http://mycompanyname.com/webservices/skeleton/clitunnel#e +xecuteCommandUsingAttachments" This is a multi-part message in MIME format... ------------=_1257541705-5420-0 Content-Type: text/xml Content-Disposition: inline Content-Location: /main_envelope Content-ID: <main_envelope> <?xml version="1.0" encoding="UTF-8"?><soap:Envelope xmlns:xsi="http:/ +/www.w3.org/2001/XMLSchema-instance" xmlns:soapenc="http://schemas.xm +lsoap.org/soap/encoding/" xmlns:xsd="http://www.w3.org/2001/XMLSchema +" soap:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmln +s:soap="http://schemas.xmlsoap.org/soap/envelope/"><soap:Header><ns1: +sessionId xsi:type="xsd:anyURI" xmlns:ns1="http://mycompanyname.com/w +ebservices/framework/xsd">urn:uuid:F72A714A5C6621242B1257541698211</n +s1:sessionId></soap:Header><soap:Body><ns6:executeCommandUsingAttachm +ents xmlns:ns6="http://mycompanyname.com/webservices/skeleton/clitunn +el"><ns6:nameSpace xsi:type="xsd:string">Server</ns6:nameSpace><ns6:c +ommandName xsi:type="xsd:string">bulkAddServers</ns6:commandName><ns6 +:commandArguments xsi:type="xsd:string">C:/temp</ns6:commandArguments +><ns6:commandArguments xsi:type="xsd:string">servers.csv</ns6:command +Arguments><ns6:commandArguments xsi:type="xsd:string">UTF-8</ns6:comm +andArguments><ns6:commandArguments xsi:type="xsd:boolean">false</ns6: +commandArguments></ns6:executeCommandUsingAttachments></soap:Body></s +oap:Envelope> ------------=_1257541705-5420-0 Content-Type: text/plain; name="C:\temp\servers.txt" Content-Disposition: attachment; filename="C:\temp\servers.txt" MIME-Version: 1.0 X-Mailer: MIME-tools 5.427 (Entity 5.427) Content-Location: /cid_0 Content-ID: <cid_0> Content-Transfer-Encoding: base64 TmFtZQphMTcKCgoKCgoKCg== ------------=_1257541705-5420-0--

In reply to SOAP::Lite::Packager and bad Content-ID by Tardigrade4

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.