refactor: all-in-one docker deployment with auto-tuned resources and per-mode compose templates
This commit is contained in:
+12
-3
@@ -176,7 +176,10 @@ return [
|
||||
'balance' => 'auto',
|
||||
'autoScalingStrategy' => 'time',
|
||||
'minProcesses' => 1,
|
||||
'maxProcesses' => 8,
|
||||
'maxProcesses' => (int) env('HORIZON_DATA_PIPELINE_MAX', 8),
|
||||
'memory' => (int) env('HORIZON_WORKER_MEMORY_MB', 128),
|
||||
'maxTime' => (int) env('HORIZON_WORKER_MAX_TIME', 3600),
|
||||
'maxJobs' => (int) env('HORIZON_WORKER_MAX_JOBS', 1000),
|
||||
'balanceCooldown' => 1,
|
||||
'tries' => 3,
|
||||
'timeout' => 30,
|
||||
@@ -186,7 +189,10 @@ return [
|
||||
'queue' => ['default', 'order_handle'],
|
||||
'balance' => 'simple',
|
||||
'minProcesses' => 1,
|
||||
'maxProcesses' => 3,
|
||||
'maxProcesses' => (int) env('HORIZON_BUSINESS_MAX', 3),
|
||||
'memory' => (int) env('HORIZON_WORKER_MEMORY_MB', 128),
|
||||
'maxTime' => (int) env('HORIZON_WORKER_MAX_TIME', 3600),
|
||||
'maxJobs' => (int) env('HORIZON_WORKER_MAX_JOBS', 1000),
|
||||
'tries' => 3,
|
||||
'timeout' => 30,
|
||||
],
|
||||
@@ -196,7 +202,10 @@ return [
|
||||
'balance' => 'auto',
|
||||
'autoScalingStrategy' => 'size',
|
||||
'minProcesses' => 1,
|
||||
'maxProcesses' => 3,
|
||||
'maxProcesses' => (int) env('HORIZON_NOTIFICATION_MAX', 3),
|
||||
'memory' => (int) env('HORIZON_WORKER_MEMORY_MB', 128),
|
||||
'maxTime' => (int) env('HORIZON_WORKER_MAX_TIME', 3600),
|
||||
'maxJobs' => (int) env('HORIZON_WORKER_MAX_JOBS', 1000),
|
||||
'tries' => 3,
|
||||
'timeout' => 60,
|
||||
'backoff' => [3, 10, 30],
|
||||
|
||||
+8
-10
@@ -102,8 +102,8 @@ return [
|
||||
|
||||
OperationTerminated::class => [
|
||||
FlushTemporaryContainerInstances::class,
|
||||
DisconnectFromDatabases::class,
|
||||
CollectGarbage::class,
|
||||
// DisconnectFromDatabases::class,
|
||||
// CollectGarbage::class,
|
||||
],
|
||||
|
||||
WorkerErrorOccurred::class => [
|
||||
@@ -129,6 +129,7 @@ return [
|
||||
|
||||
'warm' => [
|
||||
...Octane::defaultServicesToWarm(),
|
||||
\App\Services\Plugin\PluginManager::class,
|
||||
],
|
||||
|
||||
'flush' => [
|
||||
@@ -147,8 +148,8 @@ return [
|
||||
*/
|
||||
|
||||
'cache' => [
|
||||
'rows' => 5000,
|
||||
'bytes' => 20000,
|
||||
'rows' => (int) env('OCTANE_CACHE_ROWS', 1000),
|
||||
'bytes' => (int) env('OCTANE_CACHE_BYTES', 8192),
|
||||
],
|
||||
|
||||
/*
|
||||
@@ -163,10 +164,7 @@ return [
|
||||
*/
|
||||
|
||||
'tables' => [
|
||||
'example:1000' => [
|
||||
'name' => 'string:1000',
|
||||
'votes' => 'int',
|
||||
],
|
||||
//
|
||||
],
|
||||
|
||||
/*
|
||||
@@ -203,7 +201,7 @@ return [
|
||||
|
|
||||
*/
|
||||
|
||||
'garbage' => 128,
|
||||
'garbage' => (int) env('OCTANE_GARBAGE_MB', 128),
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
@@ -216,6 +214,6 @@ return [
|
||||
|
|
||||
*/
|
||||
|
||||
'max_execution_time' => 60,
|
||||
'max_execution_time' => (int) env('OCTANE_MAX_EXECUTION_TIME', 60),
|
||||
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user