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

XML::Parser Issue?

Expand Messages
  • fde101
    Hi, New to the group -- I m trying to configure a SOAP service using SOAP::Lite under mod_perl on Apache on one of our servers. * If I set up a standalone
    Message 1 of 1 , Dec 8, 2009
    View Source
    • 0 Attachment
      Hi,

      New to the group -- I'm trying to configure a SOAP service using SOAP::Lite under mod_perl on Apache on one of our servers.

      * If I set up a standalone server using "SOAP::Transport::HTTP::Daemon", it works just fine.

      * If I "bypass" SOAP::Lite by injecting my own simplistic protocol (not really an option for immediate use right now) between my module containing the service code and the mod_perl layer, this also works.

      * The same code and basic configuration are working on other servers (some module versions may be slightly different).

      When I try to use SOAP::Lite under Apache, however, on this one server, I get the following message returned to the client:


      Application failed during request deserialization:
      no element found at line 1, column 0, byte -1 at /usr/perl5/site_perl/5.8.4/sun4-solaris-64int/XML/Parser.pm line 187


      This happens consistently for any given request (identical, other than port number, to what I send to the standalone server, which works, using as much identical code as possible to what is running under Apache).


      Can anyone help me diagnose this issue?


      Some details:



      Apache/2.0.63 (Unix) DAV/2 mod_perl/2.0.0 Perl/v5.8.4 configured

      Summary of my perl5 (revision 5 version 8 subversion 4) configuration:
      Platform:
      osname=solaris, osvers=2.10, archname=sun4-solaris-64int



      package SOAP::Lite;

      use 5.005;
      use strict;
      use vars qw($VERSION);
      use version; $VERSION = qv('0.710.10');


      package XML::Parser;

      use Carp;

      BEGIN {
      require XML::Parser::Expat;
      $VERSION = '2.36';


      Partial httpd.conf (I removed a few things to protect specific internal details and such -- PerlSetEnv used to configure my code layer, and a PerlPostConfigRequire to help initialize something):

      PerlSwitches -I/usr/apache2/perl

      PerlModule Apache::DBI
      PerlModule ModPerl::Registry
      ScriptAlias /perl/ "/usr/apache2/perl/"
      <Location /perl>
      SetHandler perl-script
      PerlResponseHandler ModPerl::Registry
      PerlOptions +ParseHeaders
      Options +ExecCGI
      </Location>
      <Directory /usr/apache2/perl>
      AllowOverride None
      Options None
      Order allow,deny
      Allow from all
      </Directory>


      To run under Apache:

      use SOAP::Lite +trace;

      use SOAP::Transport::HTTP;

      use xxxx;


      SOAP::Transport::HTTP::CGI->dispatch_to('xxxx')->handle;



      Trace info:

      SOAP::Transport::new: ()
      SOAP::Serializer::new: ()
      SOAP::Deserializer::new: ()
      SOAP::Parser::new: ()
      SOAP::Server::new: ()
      SOAP::Transport::HTTP::Server::new: ()
      SOAP::Transport::HTTP::CGI::new: ()
      SOAP::Transport::HTTP::Server::handle:
      SOAP::Server::handle: ()
      SOAP::Deserializer::deserialize: ()
      SOAP::Parser::decode: ()
      SOAP::Serializer::envelope: ()
      SOAP::Serializer::envelope: Client Application failed during request deserialization:
      no element found at line 1, column 0, byte -1 at /usr/perl5/site_perl/5.8.4/sun4-solaris-64int/XML/Parser.pm line 187

      SOAP::Data::new: ()
      SOAP::Data::new: ()
      SOAP::Data::new: ()
      SOAP::Data::new: ()
      SOAP::Data::new: ()
      SOAP::Data::new: ()
      SOAP::Data::new: ()
      SOAP::Transport::HTTP::CGI::DESTROY: ()
      SOAP::Deserializer::DESTROY: ()
      SOAP::Parser::DESTROY: ()
      SOAP::Transport::DESTROY: ()
      SOAP::Serializer::DESTROY: ()
      SOAP::Data::DESTROY: ()
      SOAP::Data::DESTROY: ()
      SOAP::Data::DESTROY: ()
      SOAP::Data::DESTROY: ()
      SOAP::Data::DESTROY: ()
      SOAP::Data::DESTROY: ()
      SOAP::Data::DESTROY: ()




      For the standalone:

      use SOAP::Lite +trace;
      use SOAP::Transport::HTTP;

      use xxxx;


      my $daemon = SOAP::Transport::HTTP::Daemon->new(LocalPort => #####)
      ->dispatch_to('xxxx');

      print "Server responds to ", $daemon->url, "\n";
      $daemon->handle;


      (where ##### is actually a port number :-)
    Your message has been successfully submitted and would be delivered to recipients shortly.