This commit is contained in:
2021-07-23 11:55:02 +08:00
parent 4fbbfb37e4
commit 93519c3c57
4 changed files with 15 additions and 14 deletions
+3 -3
View File
@@ -122,7 +122,7 @@ class ServerManager extends Abstracts\Server
if (Snowflake::getPlatform()->isLinux()) {
$soloProcess->name($system . '.' . $customProcess->getProcessName($soloProcess) . ' start.');
}
echo sprintf("\033[36m[init]\033[0m Process %s start.", $customProcess->getProcessName($soloProcess)) . PHP_EOL;
echo sprintf("\033[36m[" . date('Y-m-d H:i:s') . "]\033[0m Process %s start.", $customProcess->getProcessName($soloProcess)) . PHP_EOL;
$customProcess->onHandler($soloProcess);
},
$redirect_stdin_and_stdout, $pipe_type, $enable_coroutine));
@@ -213,7 +213,7 @@ class ServerManager extends Abstracts\Server
*/
private function addNewListener(string $type, string $host, int $port, int $mode, array $settings = [])
{
echo sprintf("\033[36m[init]\033[0m $type service %s::%d start.", $host, $port) . PHP_EOL;
echo sprintf("\033[36m[" . date('Y-m-d H:i:s') . "]\033[0m $type service %s::%d start.", $host, $port) . PHP_EOL;
switch ($type) {
case Constant::SERVER_TYPE_TCP:
$this->ports[$port] = TCPServerListener::instance($this->server, $host, $port, $mode, $settings);
@@ -271,7 +271,7 @@ class ServerManager extends Abstracts\Server
$settings['settings']
));
echo sprintf("\033[36m[init]\033[0m $type service %s::%d start.", $host, $port) . PHP_EOL;
echo sprintf("\033[36m[" . date('Y-m-d H:i:s') . "]\033[0m $type service %s::%d start.", $host, $port) . PHP_EOL;
$this->addDefaultListener($type, $settings);
}