Have you considered looking at what awstats has to offer? It's written in Perl.
In reply to Re: Parsing tomcat access log by marto in thread Parsing tomcat access log by snra_perl