mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-03 16:45:13 +00:00
backport 23071d257
+ deprecations: Extract process-related functions from Utils into a separate Process class
This commit is contained in:
@ -26,6 +26,7 @@ namespace pocketmine\scheduler;
|
||||
use pocketmine\network\mcpe\protocol\ProtocolInfo;
|
||||
use pocketmine\Server;
|
||||
use pocketmine\utils\Internet;
|
||||
use pocketmine\utils\Process;
|
||||
use pocketmine\utils\Utils;
|
||||
use pocketmine\utils\UUID;
|
||||
use pocketmine\utils\VersionString;
|
||||
@ -135,12 +136,12 @@ class SendUsageTask extends AsyncTask{
|
||||
"historyList" => array_values($playerList)
|
||||
];
|
||||
|
||||
$info = Utils::getMemoryUsage(true);
|
||||
$info = Process::getMemoryUsage(true);
|
||||
$data["system"] = [
|
||||
"mainMemory" => $info[0],
|
||||
"totalMemory" => $info[1],
|
||||
"availableMemory" => $info[2],
|
||||
"threadCount" => Utils::getThreadCount()
|
||||
"threadCount" => Process::getThreadCount()
|
||||
];
|
||||
|
||||
break;
|
||||
|
Reference in New Issue
Block a user