You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by "b. nyec" <bn...@yahoo.com> on 2008/08/22 20:39:58 UTC

RE: mp2 + SOAP - SOAP calls fail randomly

Was there a solution to this, i'm having the same problem. 

Apache/2.2.4 
mod_perl/2.0.3 
Perl/v5.8.8
SOAP-Lite-0.710.08


Ive noticed that sometimes my soap requests will fail every 6th request which is the same number of httpd proccess' that are running. 

httpd.conf 
[....]

<Location /soap>
    SetHandler perl-script
    PerlSendHeader On
    PerlHandler Apache::SOAP
    PerlSetVar dispatch_to "/path/to/modules"
    PerlSetVar options "compress_threshold => 10000"
</Location>


$ ps -auxx | grep httpd | wc -l
6
$ ./test-client.pl
Resopnse: test
$ ./test-client.pl
Resopnse: test
$ ./test-client.pl
Resopnse: test
$ ./test-client.pl
Resopnse: test
$ ./test-client.pl
Resopnse: test
$ ./test-client.pl
<faultstring>Failed to locate method (my_meathod) in class (testing) at /usr/local/lib/perl5/site_perl/5.8.8/SOAP/Lite.pm line 2765.
</faultstring>
$ ./test-client.pl
Resopnse: test

[... next 5 and error occurs agian ...] 


- B

From	"Tom Shaw" <ac...@zerofiveone.com>
Subject	RE: mp2 + SOAP - SOAP calls fail randomly
Date	Thu, 26 Apr 2007 13:11:56 GMT

Ignore the test case...

It is actually:
TestSpace.pm
------------
package TestSpace;

sub getSession {
    return 1;
}

1;

-----Original Message-----
From: Tom Shaw [mailto:accounts@zerofiveone.com] 
Sent: 26 April 2007 14:11
To: 'modperl@perl.apache.org'
Subject: mp2 + SOAP - SOAP calls fail randomly

Im having some mod_perl2 wierdness. Im trying to run some SOAP requests and
Im getting odd things happening.

Is there any reason that I should be experiencing intermittant issues
dispatching SOAP methods to my class?

Sometimes the methods work fine and sometimes they don't.

When they don't I get the error returned in a fault string:
Failed to locate method (getSession) in class (TestSpace) at
/usr/local/lib/perl5/site_perl/5.8.8/SOAP/Lite.pm line 2586.

And then sometimes it all works perfectly.

Ive tried boiling all this down to a simple test case.

TestSpace.pm
------------
package MediaSpace;

sub getSession {
    return 1;
}

1;

I would estimate that 50% of the requests fail.

Im using Apache-2.2.4 PreforkMPM/Perl 5.8.8 with no threads support, and
mod_perl-2.0.3.

Any ideas would be welcomed at this point in time as Im out of ideas.

Cheers,
Tom






      

RE: mp2 + SOAP - SOAP calls fail randomly

Posted by "b. nyec" <bn...@yahoo.com>.
Discovered where the problem is,

If i add a new package/pm and make my requests to the new methods, i get the problem described in my first post. restarting apache (HUP) clears the problem. which is the correct way when adding/modifing any packages/methods, at least from what i understand.

- B


--- On Fri, 8/22/08, b. nyec <bn...@yahoo.com> wrote:

> From: b. nyec <bn...@yahoo.com>
> Subject: RE: mp2 + SOAP - SOAP calls fail randomly
> To: modperl@perl.apache.org
> Date: Friday, August 22, 2008, 1:39 PM
> Was there a solution to this, i'm having the same
> problem. 
> 
> Apache/2.2.4 
> mod_perl/2.0.3 
> Perl/v5.8.8
> SOAP-Lite-0.710.08
> 
> 
> Ive noticed that sometimes my soap requests will fail every
> 6th request which is the same number of httpd proccess'
> that are running. 
> 
> httpd.conf 
> [....]
> 
> <Location /soap>
>     SetHandler perl-script
>     PerlSendHeader On
>     PerlHandler Apache::SOAP
>     PerlSetVar dispatch_to "/path/to/modules"
>     PerlSetVar options "compress_threshold =>
> 10000"
> </Location>
> 
> 
> $ ps -auxx | grep httpd | wc -l
> 6
> $ ./test-client.pl
> Resopnse: test
> $ ./test-client.pl
> Resopnse: test
> $ ./test-client.pl
> Resopnse: test
> $ ./test-client.pl
> Resopnse: test
> $ ./test-client.pl
> Resopnse: test
> $ ./test-client.pl
> <faultstring>Failed to locate method (my_meathod) in
> class (testing) at
> /usr/local/lib/perl5/site_perl/5.8.8/SOAP/Lite.pm line 2765.
> </faultstring>
> $ ./test-client.pl
> Resopnse: test
> 
> [... next 5 and error occurs agian ...] 
> 
> 
> - B
> 
> From	"Tom Shaw" <ac...@zerofiveone.com>
> Subject	RE: mp2 + SOAP - SOAP calls fail randomly
> Date	Thu, 26 Apr 2007 13:11:56 GMT
> 
> Ignore the test case...
> 
> It is actually:
> TestSpace.pm
> ------------
> package TestSpace;
> 
> sub getSession {
>     return 1;
> }
> 
> 1;
> 
> -----Original Message-----
> From: Tom Shaw [mailto:accounts@zerofiveone.com] 
> Sent: 26 April 2007 14:11
> To: 'modperl@perl.apache.org'
> Subject: mp2 + SOAP - SOAP calls fail randomly
> 
> Im having some mod_perl2 wierdness. Im trying to run some
> SOAP requests and
> Im getting odd things happening.
> 
> Is there any reason that I should be experiencing
> intermittant issues
> dispatching SOAP methods to my class?
> 
> Sometimes the methods work fine and sometimes they
> don't.
> 
> When they don't I get the error returned in a fault
> string:
> Failed to locate method (getSession) in class (TestSpace)
> at
> /usr/local/lib/perl5/site_perl/5.8.8/SOAP/Lite.pm line
> 2586.
> 
> And then sometimes it all works perfectly.
> 
> Ive tried boiling all this down to a simple test case.
> 
> TestSpace.pm
> ------------
> package MediaSpace;
> 
> sub getSession {
>     return 1;
> }
> 
> 1;
> 
> I would estimate that 50% of the requests fail.
> 
> Im using Apache-2.2.4 PreforkMPM/Perl 5.8.8 with no threads
> support, and
> mod_perl-2.0.3.
> 
> Any ideas would be welcomed at this point in time as Im out
> of ideas.
> 
> Cheers,
> Tom