Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re: Convert SOAP service from CGI to Mod-Perl (ModPerl::Registry)

by jakeease (Friar)
on Oct 02, 2010 at 02:03 UTC ( #863032=note: print w/replies, xml ) Need Help??


in reply to Convert SOAP service from CGI to Mod-Perl (ModPerl::Registry)

handlers are commonly named "handler" but it's not required. Do you have a PerlModule directive in httpd.conf?

PerlModule Hello

Replies are listed 'Best First'.
Re^2: Convert SOAP service from CGI to Mod-Perl (ModPerl::Registry)
by halfcountplus (Hermit) on Oct 02, 2010 at 12:45 UTC
    >>handlers are commonly named "handler" but it's not required.

    Just to clarify -- I did not say the handler had to be called "handler". What I said was the handler must contain a primary function, handler(), the same way an object definition must contain a function, new(), in order to be instantantiated as such. This IS REQUIRED by Apache, and hence mod perl. If you DO NOT have such a function, you will get the following apache error, eg:

    failed to resolve handler Hello

    I was just guessing that the OP was looking at an example "package handler" that had the primary function, handler(), and decided to rename not just the package -- which can be called anything, but that will be the name you use to register it -- and the handler() function, which would be a mistake, because it MUST be called handler() for the module to work.

      >>the OP ... decided to rename not just the package -- which can be called >>anything, ... and the handler() function, which would be a mistake, because it >>MUST be called handler() for the module to work.

      I agree that he should have named it handler() for it to work with the configuration and suggested changes to it. But it is NOT required to name the handler routine "handler()". It can be called anything. To make the OP's handler work, something like the following directive would be needed:

      PerlHandler Hello::hello #or PerlHandler Hello->hello

      Since I didn't point that out, that part of my response was more of a distraction than solution, and yours a significant step toward a solution.

Re^2: Convert SOAP service from CGI to Mod-Perl (ModPerl::Registry)
by banco (Initiate) on Oct 02, 2010 at 14:16 UTC

    I wasn't aware of that particular directive. I'll check it out ... thanks for the reply.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://863032]
help
Chatterbox?
[Corion]: I found Android Studio quite nice as a Java IDE, but then, I didn't try anything serious with it
[chacham]: it is a nice ide. its just that upgrading it always causes issues with mismatched versions of whatever
[Corion]: chacham: Oh, yes, reinstalling all the SDK versions and Gradle and whatnot, yes, even in the short time I used it (2 weeks?) I felt that pain
[chacham]: right now im editing the versions in the applications gradle file to use a version it wants. sheesh.
[Corion]: Ow, "but you're not supposed to do that" ;)

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (13)
As of 2017-03-29 08:02 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Should Pluto Get Its Planethood Back?



    Results (344 votes). Check out past polls.