nicolasff / webdis

A Redis HTTP interface with JSON output
https://webd.is
BSD 2-Clause "Simplified" License
2.83k stars 304 forks source link

Pidfile creation and signal handling #10

Closed jollyroger closed 10 years ago

jollyroger commented 13 years ago

Hello, Nicolas!

It would be great if webdis could receive signals and write its pidfile somewhere.

Pidfiles are great tools which help to maintain running process and identify the correct process among several servers with the same name.

Signal handling is one of the commonly used features for such things like log rotating. For example, when SIGHUP is received, the deamon commonly should reread it's config file (e.g. reload) and reopen log files. This is common technique used by logrotate.

nicolasff commented 13 years ago

Hello,

Good ideas. I'll take a look at the way logrotate works and add it this week.

Nicolas