From 883e11f761fd1d2fc189fbd5101afc3d3366a640 Mon Sep 17 00:00:00 2001 From: Owen Jacobson Date: Tue, 17 Jul 2012 13:44:15 -0400 Subject: [PATCH] Retain pid files for dead daemons in 'phd status'. 'phd status' should have a stable result when invoked multiple times. Automatically removing PID files for dead daemons every time 'phd status' is invoked prevents tools from noticing that a daemon has died if something happens to invoke 'phd status' before the tool looks. This affects Puppet noticably, since it probably runs the status command every half hour. --- src/infrastructure/daemon/PhabricatorDaemonControl.php | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/infrastructure/daemon/PhabricatorDaemonControl.php b/src/infrastructure/daemon/PhabricatorDaemonControl.php index b2b2f0cd79..f4b6f80508 100644 --- a/src/infrastructure/daemon/PhabricatorDaemonControl.php +++ b/src/infrastructure/daemon/PhabricatorDaemonControl.php @@ -55,9 +55,6 @@ final class PhabricatorDaemonControl { if (!$daemon->isRunning()) { $status = 2; $name = ' '.$name; - if ($daemon->getPIDFile()) { - Filesystem::remove($daemon->getPIDFile()); - } } printf( "%5s\t%-24s\t%s\n",