@effectstream/utils 0.100.20 → 0.100.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/config.ts +10 -10
package/package.json
CHANGED
package/src/config.ts
CHANGED
|
@@ -239,6 +239,13 @@ const definitions: Record<string, ConfigDefinition> = {
|
|
|
239
239
|
defaultValue: undefined,
|
|
240
240
|
description: "Enable PGLite Debug/Verbose mode. Example: '1'",
|
|
241
241
|
},
|
|
242
|
+
ALLOW_NO_PG_IVM: {
|
|
243
|
+
key: "ALLOW_NO_PG_IVM",
|
|
244
|
+
type: "boolean",
|
|
245
|
+
defaultValue: false,
|
|
246
|
+
description:
|
|
247
|
+
"Permits the engine to start when the pg_ivm extension is not installed, falling back to plain SQL views over the trigger-maintained intermediate tables. Intended for dev/test and low-volume apps only — the fallback degrades sharply on high-cardinality data. Production deployments should install pg_ivm. ('true' or 'false')",
|
|
248
|
+
},
|
|
242
249
|
OTEL_COLLECTOR_PORT: {
|
|
243
250
|
key: "OTEL_COLLECTOR_PORT",
|
|
244
251
|
type: "number",
|
|
@@ -307,13 +314,6 @@ const definitions: Record<string, ConfigDefinition> = {
|
|
|
307
314
|
description:
|
|
308
315
|
"Snapshot retention: keep one snapshot per day for this many days. Snapshots older than this are deleted. Default: 7.",
|
|
309
316
|
},
|
|
310
|
-
EFFECTSTREAM_COALESCE_EMPTY_BLOCKS: {
|
|
311
|
-
key: "EFFECTSTREAM_COALESCE_EMPTY_BLOCKS",
|
|
312
|
-
type: "boolean",
|
|
313
|
-
defaultValue: false,
|
|
314
|
-
description:
|
|
315
|
-
"Fold consecutive empty catch-up blocks into one DB transaction when behind the chain tip. Default: false.",
|
|
316
|
-
},
|
|
317
317
|
} as const;
|
|
318
318
|
|
|
319
319
|
type ENV_TYPES = string | number | boolean | undefined;
|
|
@@ -412,6 +412,9 @@ export class ENV {
|
|
|
412
412
|
static get DEBUG_PGLITE(): number {
|
|
413
413
|
return ENV.getConfig(definitions.DEBUG_PGLITE);
|
|
414
414
|
}
|
|
415
|
+
static get ALLOW_NO_PG_IVM(): boolean {
|
|
416
|
+
return ENV.getConfig(definitions.ALLOW_NO_PG_IVM);
|
|
417
|
+
}
|
|
415
418
|
static get OTEL_COLLECTOR_PORT(): number {
|
|
416
419
|
return ENV.getConfig(definitions.OTEL_COLLECTOR_PORT);
|
|
417
420
|
}
|
|
@@ -448,9 +451,6 @@ export class ENV {
|
|
|
448
451
|
static get EFFECTSTREAM_SNAPSHOT_LAST_N_DAYS(): number {
|
|
449
452
|
return ENV.getConfig(definitions.EFFECTSTREAM_SNAPSHOT_LAST_N_DAYS);
|
|
450
453
|
}
|
|
451
|
-
static get EFFECTSTREAM_COALESCE_EMPTY_BLOCKS(): boolean {
|
|
452
|
-
return ENV.getConfig(definitions.EFFECTSTREAM_COALESCE_EMPTY_BLOCKS);
|
|
453
|
-
}
|
|
454
454
|
|
|
455
455
|
public static getConfig<T>(config: ConfigDefinition): T {
|
|
456
456
|
switch (config.type) {
|