feat(worker): allow number of threads to be configured

This allows for more threads to be run. Care needs to be taken to ensure that database connection pool size is appropriate for this.
This commit is contained in:
Adam Cooke
2024-03-17 18:41:26 +00:00
parent ee8d829a85
commit 7e2acccd1e
4 changed files with 11 additions and 1 deletions
+1
View File
@@ -25,6 +25,7 @@ This document contains all the environment variables which are available for thi
| `WEB_SERVER_MAX_THREADS` | Integer | The maximum number of threads which can be used by the web server | 5 |
| `WORKER_DEFAULT_HEALTH_SERVER_PORT` | Integer | The default port for the worker health server to listen on | 9090 |
| `WORKER_DEFAULT_HEALTH_SERVER_BIND_ADDRESS` | String | The default bind address for the worker health server to listen on | 127.0.0.1 |
| `WORKER_THREADS` | Integer | The number of threads to execute within each worker | 2 |
| `MAIN_DB_HOST` | String | Hostname for the main MariaDB server | localhost |
| `MAIN_DB_PORT` | Integer | The MariaDB port to connect to | 3306 |
| `MAIN_DB_USERNAME` | String | The MariaDB username | postal |
+2
View File
@@ -47,6 +47,8 @@ worker:
default_health_server_port: 9090
# The default bind address for the worker health server to listen on
default_health_server_bind_address: 127.0.0.1
# The number of threads to execute within each worker
threads: 2
main_db:
# Hostname for the main MariaDB server