mirror of
https://github.com/appwrite/appwrite
synced 2026-05-23 08:58:35 +00:00
chore: Updating workers
This commit is contained in:
parent
916f58cd9d
commit
2947d22392
3 changed files with 4 additions and 4 deletions
2
.env
2
.env
|
|
@ -1,7 +1,7 @@
|
|||
_APP_ENV=development
|
||||
_APP_EDITION=self-hosted
|
||||
_APP_LOCALE=en
|
||||
_APP_WORKER_PER_CORE=2
|
||||
_APP_WORKER_PER_CORE=6
|
||||
_APP_CONSOLE_WHITELIST_ROOT=disabled
|
||||
_APP_CONSOLE_WHITELIST_EMAILS=
|
||||
_APP_CONSOLE_SESSION_ALERTS=enabled
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ use Utopia\System\System;
|
|||
global $global, $container;
|
||||
|
||||
$payloadSize = 12 * (1024 * 1024); // 12MB - adding slight buffer for headers and other data that might be sent with the payload - update later with valid testing
|
||||
$workerNumber = swoole_cpu_num() * intval(System::getEnv('_APP_WORKER_PER_CORE', 2));
|
||||
$workerNumber = swoole_cpu_num() * intval(System::getEnv('_APP_WORKER_PER_CORE', 6));
|
||||
|
||||
$server = new Server('0.0.0.0', '80', [
|
||||
'open_http2_protocol' => true,
|
||||
|
|
@ -36,7 +36,7 @@ $server = new Server('0.0.0.0', '80', [
|
|||
'buffer_output_size' => $payloadSize,
|
||||
// Server
|
||||
// 'log_level' => 0,
|
||||
'dispatch_mode' => 1,
|
||||
'dispatch_mode' => 2,
|
||||
'worker_num' => $workerNumber,
|
||||
'reactor_num' => swoole_cpu_num() * 2,
|
||||
'open_cpu_affinity' => true,
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@ $stats->create();
|
|||
|
||||
$containerId = uniqid();
|
||||
$statsDocument = null;
|
||||
$workerNumber = swoole_cpu_num() * intval(System::getEnv('_APP_WORKER_PER_CORE', 2));
|
||||
$workerNumber = swoole_cpu_num() * intval(System::getEnv('_APP_WORKER_PER_CORE', 6));
|
||||
|
||||
$adapter = new Adapter\Swoole(port: System::getEnv('PORT', 80));
|
||||
$adapter
|
||||
|
|
|
|||
Loading…
Reference in a new issue