@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator

Improve daemon "waiting" message, config reload behavior

Summary:
Ref T12298. Two minor daemon improvements:

- Make the "waiting" message reflect hibernation.
- Don't trigger a reload right after launching.

Test Plan:
- Read "waiting" message.
- Ran "bin/phd start", didn't see an immediate SIGHUP in the log.

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T12298

Differential Revision: https://secure.phabricator.com/D17550

+10 -6
+4 -6
src/applications/daemon/controller/PhabricatorDaemonLogViewController.php
··· 125 125 case PhabricatorDaemonLog::STATUS_WAIT: 126 126 $details = pht( 127 127 'This daemon is running normally and reported a status update '. 128 - 'recently (within %s). However, it encountered an error while '. 129 - 'doing work and is waiting a little while (%s) to resume '. 130 - 'processing. After encountering an error, daemons wait before '. 131 - 'resuming work to avoid overloading services.', 132 - phutil_format_relative_time($unknown_time), 133 - phutil_format_relative_time($wait_time)); 128 + 'recently (within %s). The process is currently waiting to '. 129 + 'restart, either because it is hibernating or because it '. 130 + 'encountered an error.', 131 + phutil_format_relative_time($unknown_time)); 134 132 break; 135 133 case PhabricatorDaemonLog::STATUS_EXITING: 136 134 $details = pht('This daemon is shutting down gracefully.');
+6
src/infrastructure/daemon/overseer/PhabricatorDaemonOverseerModule.php
··· 48 48 49 49 $this->configVersion = $new_version; 50 50 51 + // Don't trigger a reload if we're loading the config for the very 52 + // first time. 53 + if ($old_version === null) { 54 + return false; 55 + } 56 + 51 57 return ($old_version != $new_version); 52 58 } 53 59