mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-26 00:32:42 +01:00
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
This commit is contained in:
parent
2707681b48
commit
f13637627d
2 changed files with 10 additions and 6 deletions
|
@ -125,12 +125,10 @@ final class PhabricatorDaemonLogViewController
|
|||
case PhabricatorDaemonLog::STATUS_WAIT:
|
||||
$details = pht(
|
||||
'This daemon is running normally and reported a status update '.
|
||||
'recently (within %s). However, it encountered an error while '.
|
||||
'doing work and is waiting a little while (%s) to resume '.
|
||||
'processing. After encountering an error, daemons wait before '.
|
||||
'resuming work to avoid overloading services.',
|
||||
phutil_format_relative_time($unknown_time),
|
||||
phutil_format_relative_time($wait_time));
|
||||
'recently (within %s). The process is currently waiting to '.
|
||||
'restart, either because it is hibernating or because it '.
|
||||
'encountered an error.',
|
||||
phutil_format_relative_time($unknown_time));
|
||||
break;
|
||||
case PhabricatorDaemonLog::STATUS_EXITING:
|
||||
$details = pht('This daemon is shutting down gracefully.');
|
||||
|
|
|
@ -48,6 +48,12 @@ final class PhabricatorDaemonOverseerModule
|
|||
|
||||
$this->configVersion = $new_version;
|
||||
|
||||
// Don't trigger a reload if we're loading the config for the very
|
||||
// first time.
|
||||
if ($old_version === null) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return ($old_version != $new_version);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue