see we are using Catalyst and it run under mod_perl2. we're planning to
use Geo::IP in our Controller.
I'm wondering which code is better as following.
1)
use vars qw/$geo_ip/;
sub ip_to_location {
my ( $ip ) = @_;
$geo_ip ||= Geo::IP->open("/usr/local/share/GeoIP/GeoLiteCity.dat",
GEO
>>> http://modperlbook.org/html/21-5-8-Noninteractive-Perl-Debugging-Under-mod_perl.html
>>
>> OK, I'm doing this, but it seems that the file it produces only ever
>> gets up to 7.3M and that's it.
OK, the reason the file only ever got to 7.3M was indeed because
apache would of course fork a bunch