http://qs321.pair.com?node_id=728787


in reply to Re: In search of an efficient query abstractor
in thread In search of an efficient query abstractor

Thanks. There are two things scaring me away from doing it in C:

So, basically I'm scared. I want to stay in my comfortable safe Perl zone if I can.

It definitely has to be fast and I can't divide it up, alas. I work with Percona; we are consultants for hire. We log onto people's critical production database servers and figure out why they are slow. One of the top-five tools we use is a log analysis tool. We need something that can crunch the file without requiring installation or whatever. We can't even copy the file elsewhere in most cases, we pretty much just have to operate in read-only mode.

This code was originally written to be correct, not fast -- back in the good old days when I had the luxuries you mention (I was working on my own DB servers.) It handles a lot of special cases that the log-parsers-ad-nauseum out there don't. (Which is why I'm reinventing the wheel. No one has done this well yet.) Now I have to make it both correct, and fast.