Reviews by


File-Pid (1.01) *****

Summary: A++++++, prompt solution. Pity about the SYNOPSIS. Will use again.

Version 1.01 doesn't document what the module does internally. It's easy enough to argue that a module shouldn't necessarily document its guts, but PID file manipulation is one of those basic tasks that's easy to do wrong. For my own confidence, I like to know whether a module does it right. Luckily this is Perl; anyone who wants to break conceptual encapsulation can easily view the source.

The documentation doesn't caution the user against using $pidfile->write() before checking $pidfile->running(), which would be common sense anyway, but the example in the SYNOPSIS shows write() being used before running(). Following the SYNOPSIS blindly leads to bad behavior.

Ignoring the documentation issues, the module's a joy to use and effective for common cases. I was able to add process locking (only run one of $0 at a time) to an existing program in just a few lines of code. I'll undoubtedly be using it again.