Skip to content

Commit 435cbaa

Browse files
authored
Merge pull request #95 from v-leonhou/master
worker记录状态函数变量名规范
2 parents 865237e + ba5ca33 commit 435cbaa

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Worker.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1207,15 +1207,15 @@ protected static function writeStatisticsToStatusFile()
12071207
// For child processes.
12081208
/** @var Worker $worker */
12091209
$worker = current(self::$_workers);
1210-
$wrker_status_str = posix_getpid() . "\t" . str_pad(round(memory_get_usage(true) / (1024 * 1024), 2) . "M",
1210+
$worker_status_str = posix_getpid() . "\t" . str_pad(round(memory_get_usage(true) / (1024 * 1024), 2) . "M",
12111211
7) . " " . str_pad($worker->getSocketName(),
12121212
self::$_maxSocketNameLength) . " " . str_pad(($worker->name === $worker->getSocketName() ? 'none' : $worker->name),
12131213
self::$_maxWorkerNameLength) . " ";
1214-
$wrker_status_str .= str_pad(ConnectionInterface::$statistics['connection_count'],
1214+
$worker_status_str .= str_pad(ConnectionInterface::$statistics['connection_count'],
12151215
11) . " " . str_pad(ConnectionInterface::$statistics['total_request'],
12161216
14) . " " . str_pad(ConnectionInterface::$statistics['send_fail'],
12171217
9) . " " . str_pad(ConnectionInterface::$statistics['throw_exception'], 15) . "\n";
1218-
file_put_contents(self::$_statisticsFile, $wrker_status_str, FILE_APPEND);
1218+
file_put_contents(self::$_statisticsFile, $worker_status_str, FILE_APPEND);
12191219
}
12201220

12211221
/**

0 commit comments

Comments
 (0)