On Mon, 24 Mar 2003, Stas Bekman wrote:

> Jie Gao wrote:
> > Hi All,
> >
> > I am getting the following error mesg:
> >
> > Can't locate object method "run_access_checker" via package "Apache::RequestRec" 
> > at /usr/local/perl-5.8.0_threaded/lib/site_perl/5.8.0/xxx/.....pm
> >
> > for the section:
> >
> > sub handler {
> >     my Apache::Connection $c = shift;
> >     my APR::Socket $socket = $c->client_socket;
> >     my $r = Apache::RequestRec->new($c);
> >     $r->location_merge(__PACKAGE__);
> >     my $rc = $r->run_access_checker();
> > ......
> >
> >
> > Any idea why?
> >
> > I am using 2.0.44 with mp2 from cvs.
>
> Guessing that you haven't loaded Apache::HookRun.
>
> % lookup run_access_checker
> to use method 'run_access_checker' add:
>          use Apache::HookRun ();

Thanks, that worked.

I have run into another problem, though. I am writing a
PerlProcessConnectionHandler based on the example in "overview of
mod_perl-2.0". It's going to listen on two ports, and I need to know
which port is being used in order to set up other things. But I could
not get get_server_port work.

I have tried:

    my $s = $r->server;
    my $port = $s->get_server_port;

but got error message:

Can't locate object method "get_server_port" via package "Apache::Server" at 
/usr/local/perl-5.8.0_threaded/lib/site_perl/5.8.0/xxx.pm

I haven't been able to find relevant documentation.


Regards,



Jie

Reply via email to