[Catalyst] How to access $c->apache in 5.9?

Hailin Hu i at h2l.name
Fri Apr 20 02:42:49 GMT 2012

I'm trying to log username authenticated throught ldap into a log
file, and I use Apache/mod_perl.

In 5.8

$c->apache->user( $username );

works, which doesn't work in 5.9.

I checked source code of relevant modules like

It seems like that Catalyst::Engine::Apache is not used any more, isn't it?

Finally, something like below works for me.

my $apache = $c->engine->env->{'psgi.input'}; # Apache2::RequestRec
$apache->user( $username );

I supposed that an accessor of apache should be a method instead of a
key of hash.
Is this the right way to retrieve the apache/mod_perl object?


More information about the Catalyst mailing list