You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
|`connectionString`|`string`|`process.env.WORKFLOW_POSTGRES_URL` or `'postgres://world:world@localhost:5432/world'`| Used only when `pool` is omitted, to construct an internal pool |
69
+
|`maxPoolSize`|`number`|`process.env.WORKFLOW_POSTGRES_MAX_POOL_SIZE` or `pg.Pool` default (`10`) | Optional. Sets the internal `pg.Pool` max size when `createWorld()` creates the pool |
65
70
|`pool`|`pg.Pool`| — | Optional. When set, used for Drizzle, Graphile Worker, and stream writes. `world.close()` does not end it. |
66
71
|`jobPrefix`|`string`|`process.env.WORKFLOW_POSTGRES_JOB_PREFIX`| Optional prefix for queue job names |
67
72
|`queueConcurrency`|`number`|`10`| Number of concurrent active step executions per process |
@@ -74,6 +79,11 @@ const worldFromPool = createWorld({ pool });
|`WORKFLOW_POSTGRES_JOB_PREFIX`| Prefix for queue job names | - |
76
81
|`WORKFLOW_POSTGRES_WORKER_CONCURRENCY`| Number of concurrent workers |`10`|
82
+
|`WORKFLOW_POSTGRES_MAX_POOL_SIZE`| Internal `pg.Pool` max size |`10`|
83
+
84
+
When `pool` is omitted, `maxPoolSize` precedence is: `createWorld({ maxPoolSize })`, then `WORKFLOW_POSTGRES_MAX_POOL_SIZE`, then the `pg.Pool` default.
85
+
86
+
For higher worker concurrency, Graphile Worker recommends setting `maxPoolSize` to `10` or `queueConcurrency + 2`, whichever is larger.
0 commit comments