Loading ...
Sorry, an error occurred while loading the content.

3333Re: [soaplite] Abnormal Memory usage while sending attachments

Expand Messages
  • Randy J. Ray
    Jan 29, 2004
    • 0 Attachment
      Chetan Lalye wrote:
      > Hi
      >
      > I'm using the following code to test attachments.Everything works as
      > expected and I can save the attachment on the server side but during the
      > invocation, the memory usage of the perl process shoots upto 600 MB !!
      > The attachment file is only 30 MB.

      Unfortunately, the problem is less with SOAP::Lite than with LWP, the package
      that SOAP::Lite uses for HTTP transport. Unless a message is assembled in a
      particular way, HTTP::Request and LWP::UserAgent end up creating the entire
      message as an in-memory string, and if there is any redirection or
      authentication done in the communications, there could be multiple copies
      created on the Perl interpreter's heap. It's very likely that SOAP::Lite
      compounds the issue with it's own object memory requirements, since a lot of
      values have to be created in the process of producing the final message.

      There's not really anything that can be done about this, at least not for now.

      Randy
      --
      rjray@... http://www.rjray.org http://www.svsm.org

      Always code as if the guy who ends up maintaining your code will be a violent
      psychopath who knows where you live. -- Rick Osborne
    • Show all 3 messages in this topic