Hello all,

In light of the recent "performance monger" thread, I am interested in
information about transitioning from Registry scripts to Apache
handlers. Here is my situation, which I'm guessing is pretty common.

I have a series of scripts (search.pl for instance) which determines the
action to perform based on QUERY_STRING/POST params. It then calls the
appropriate method in an OO Perl Module, which does it's stuff and
prints the page using HTML::Template. So a typical request looks like
"/cgi-bin/search.pl?A=R&blah=1&foo=2". The initial script does something
like this:

use Search; 
use CGI;
my $q = new CGI;
my $action = $q->param('A');
my $object = Search->($CGI);
if ($action eq 'R') {
        $object->searchResults;
} elsif ($action eq 'S') {
        $object->Search;
}


I understand the speed/memory benefits of not setting up CGI
environment, but how do I go about making the transition? I have a (I
hope) good understanding of writing a pure Apache module, but am unsure
of how to transfer the functionality. Should I just use Apache::Request
instead of CGI.pm? (I do use the cookie & checkbox/pulldown
functionality often). If there are any tutorials out there, I'd love
some links. I love to document my journey for the benefit of others as
well.

Here's hoping for some good pointers/hints. :-)

-- 
Drew Taylor
Vialogix Communications, Inc.
501 N. College Street
Charlotte, NC 28202
704.370.0550
http://www.vialogix.com

Reply via email to