pg-boss 12.35.0 → 12.36.0
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/README.md +1 -0
- package/dist/attorney.d.ts.map +1 -1
- package/dist/attorney.js +21 -0
- package/dist/boss.d.ts.map +1 -1
- package/dist/boss.js +35 -4
- package/dist/db.d.ts +1 -0
- package/dist/db.d.ts.map +1 -1
- package/dist/db.js +11 -0
- package/dist/index.d.ts +3 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +23 -5
- package/dist/latency.d.ts +15 -0
- package/dist/latency.d.ts.map +1 -0
- package/dist/latency.js +45 -0
- package/dist/manager.d.ts +2 -1
- package/dist/manager.d.ts.map +1 -1
- package/dist/manager.js +216 -73
- package/dist/migrationStore.d.ts.map +1 -1
- package/dist/migrationStore.js +67 -0
- package/dist/nurse.d.ts +20 -0
- package/dist/nurse.d.ts.map +1 -0
- package/dist/nurse.js +287 -0
- package/dist/plans.d.ts +20 -0
- package/dist/plans.d.ts.map +1 -1
- package/dist/plans.js +500 -50
- package/dist/registrar.d.ts +16 -0
- package/dist/registrar.d.ts.map +1 -0
- package/dist/registrar.js +221 -0
- package/dist/schema.json +480 -1
- package/dist/telemetry.d.ts +65 -0
- package/dist/telemetry.d.ts.map +1 -0
- package/dist/telemetry.js +349 -0
- package/dist/types.d.ts +201 -3
- package/dist/types.d.ts.map +1 -1
- package/package.json +17 -8
package/README.md
CHANGED
|
@@ -51,6 +51,7 @@ This will likely cater the most to teams already familiar with the simplicity of
|
|
|
51
51
|
* Pub/sub API for fan-out queue relationships
|
|
52
52
|
* SQL support for non-Node.js runtimes for most operations
|
|
53
53
|
* Serverless function compatible
|
|
54
|
+
* [OpenTelemetry](https://pgboss.io/opentelemetry) traces and metrics, with a job's trace continued from `send()` to the worker that processes it
|
|
54
55
|
* Multi-master compatible (for example, in a Kubernetes ReplicaSet)
|
|
55
56
|
* [Additional database backends](https://pgboss.io/database-backends) for Postgres-based databases such as CockroachDB, YugabyteDB and Citus. Or, use embedded PGlite for running entirely in-process.
|
|
56
57
|
|
package/dist/attorney.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"attorney.d.ts","sourceRoot":"","sources":["../src/attorney.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,KAAK,KAAK,MAAM,YAAY,CAAA;AAExC,QAAA,MAAM,MAAM;;;;CAIX,CAAA;AAKD,QAAA,MAAM,mBAAmB,6RAcf,CAAA;AA+EV,iBAAS,iBAAiB,CAAE,MAAM,GAAE,GAAQ,QAc3C;AAiBD,iBAAS,mBAAmB,CAAE,KAAK,EAAE,MAAM,UAE1C;AAED,iBAAS,aAAa,CAAE,IAAI,EAAE,GAAG,GAAG,KAAK,CAAC,OAAO,CAgDhD;AAOD,iBAAS,eAAe,CAAE,IAAI,EAAE,GAAG,EAAE,EAAE,MAAc,EAAE;;CAAK,GAAG,KAAK,CAAC,OAAO,CA4D3E;AAED,iBAAS,mBAAmB,CAAE,MAAM,EAAE,GAAG,QAOxC;AAED,iBAAS,gBAAgB,CAAE,IAAI,EAAE,KAAK,CAAC,OAAO,EAAE,QA2D/C;AA2GD,iBAAS,aAAa,CAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG;IAClD,OAAO,EAAE,KAAK,CAAC,mBAAmB,CAAA;IAClC,QAAQ,EAAE,KAAK,CAAC,WAAW,CAAC,GAAG,CAAC,CAAA;CACjC,CAgCA;AAqBD,iBAAS,cAAc,CAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,GAAG,QAQlD;AAED,iBAAS,SAAS,CAAE,KAAK,EAAE,MAAM,GAAG,KAAK,CAAC,kBAAkB,GAAG,KAAK,CAAC,0BAA0B,
|
|
1
|
+
{"version":3,"file":"attorney.d.ts","sourceRoot":"","sources":["../src/attorney.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,KAAK,KAAK,MAAM,YAAY,CAAA;AAExC,Q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js
CHANGED
|
@@ -422,7 +422,9 @@ function getConfig(value) {
|
|
|
422
422
|
applyScheduleConfig(config);
|
|
423
423
|
applyBamConfig(config);
|
|
424
424
|
applyFlowConfig(config);
|
|
425
|
+
applyInstanceConfig(config);
|
|
425
426
|
validateWarningConfig(config);
|
|
427
|
+
validateOpenTelemetryConfig(config);
|
|
426
428
|
return config;
|
|
427
429
|
}
|
|
428
430
|
const CLOCK_METHODS = ['now', 'setTimeout', 'clearTimeout', 'setInterval', 'clearInterval'];
|
|
@@ -441,6 +443,25 @@ function applySchemaConfig(config) {
|
|
|
441
443
|
}
|
|
442
444
|
config.schema = config.schema || DEFAULT_SCHEMA;
|
|
443
445
|
}
|
|
446
|
+
function applyInstanceConfig(config) {
|
|
447
|
+
config.registerInstance = ('registerInstance' in config) ? config.registerInstance !== false : true;
|
|
448
|
+
assert(!('instanceName' in config) || config.instanceName === undefined || (typeof config.instanceName === 'string' && config.instanceName.length > 0), 'configuration assert: instanceName must be a non-empty string');
|
|
449
|
+
assert(!('instanceHeartbeatSeconds' in config) || config.instanceHeartbeatSeconds === undefined ||
|
|
450
|
+
(Number.isInteger(config.instanceHeartbeatSeconds) && config.instanceHeartbeatSeconds >= 1 && config.instanceHeartbeatSeconds <= 3600), 'configuration assert: instanceHeartbeatSeconds must be an integer from 1 to 3600');
|
|
451
|
+
config.instanceHeartbeatSeconds = config.instanceHeartbeatSeconds || 30;
|
|
452
|
+
}
|
|
453
|
+
function validateOpenTelemetryConfig(config) {
|
|
454
|
+
const otel = config.openTelemetry;
|
|
455
|
+
if (otel == null)
|
|
456
|
+
return;
|
|
457
|
+
assert(typeof otel === 'object', 'configuration assert: openTelemetry must be an object');
|
|
458
|
+
for (const key of ['enabled', 'propagateContext']) {
|
|
459
|
+
assert(otel[key] === undefined || typeof otel[key] === 'boolean', `configuration assert: openTelemetry.${key} must be a boolean`);
|
|
460
|
+
}
|
|
461
|
+
assert(otel.tracerProvider === undefined || typeof otel.tracerProvider?.getTracer === 'function', 'configuration assert: openTelemetry.tracerProvider must implement getTracer()');
|
|
462
|
+
assert(otel.meterProvider === undefined || typeof otel.meterProvider?.getMeter === 'function', 'configuration assert: openTelemetry.meterProvider must implement getMeter()');
|
|
463
|
+
assert(otel.propagator === undefined || (typeof otel.propagator?.inject === 'function' && typeof otel.propagator?.extract === 'function'), 'configuration assert: openTelemetry.propagator must implement inject() and extract()');
|
|
464
|
+
}
|
|
444
465
|
function validateWarningConfig(config) {
|
|
445
466
|
assert(!('warningQueueSize' in config) || config.warningQueueSize >= 1, 'configuration assert: warningQueueSize must be at least 1');
|
|
446
467
|
assert(!('warningSlowQuerySeconds' in config) || config.warningSlowQuerySeconds >= 1, 'configuration assert: warningSlowQuerySeconds must be at least 1');
|
package/dist/boss.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"boss.d.ts","sourceRoot":"","sources":["../src/boss.ts"],"names":[],"mappings":"AAAA,OAAO,YAAY,MAAM,aAAa,CAAA;AAEtC,OAAO,KAAK,OAAO,MAAM,cAAc,CAAA;AAGvC,OAAO,KAAK,KAAK,MAAM,YAAY,CAAA;
|
|
1
|
+
{"version":3,"file":"boss.d.ts","sourceRoot":"","sources":["../src/boss.ts"],"names":[],"mappings":"AAAA,OAAO,YAAY,MAAM,aAAa,CAAA;AAEtC,OAAO,KAAK,OAAO,MAAM,cAAc,CAAA;AAGvC,OAAO,KAAK,KAAK,MAAM,YAAY,CAAA;AAkInC,cAAM,IAAK,SAAQ,YAAa,YAAW,KAAK,CAAC,WAAW;;IAsC1D,MAAM;;;MAAS;gBAGb,EAAE,EAAE,KAAK,CAAC,SAAS,EACnB,OAAO,EAAE,OAAO,EAChB,MAAM,EAAE,KAAK,CAAC,0BAA0B;IAa1C,IAAI,WAAW,IAAK,OAAO,CAE1B;IAIK,KAAK;IAiBL,IAAI;IAoHJ,SAAS,CAAE,KAAK,CAAC,EAAE,MAAM,GAAG,KAAK,CAAC,WAAW,EAAE,EAAE,OAAO,CAAC,EAAE,KAAK,CAAC,gBAAgB;IA2tBvF;;;;OAIG;IACG,kBAAkB,CAAE,OAAO,CAAC,EAAE,KAAK,CAAC,cAAc,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC;CAwB7E;AAED,eAAe,IAAI,CAAA"}
|
package/dist/boss.js
CHANGED
|
@@ -40,6 +40,22 @@ const XMIN_HOLDERS = {
|
|
|
40
40
|
standbys: 'a standby with hot_standby_feedback enabled',
|
|
41
41
|
prepared: 'a prepared transaction'
|
|
42
42
|
};
|
|
43
|
+
// The names pg-boss gives the pools it creates: 'pgboss:<id>' for a registered instance, and
|
|
44
|
+
// 'pgboss' for one that does not register or predates the registry.
|
|
45
|
+
function isPgBossName(name) {
|
|
46
|
+
return name === 'pgboss' || !!name?.startsWith('pgboss:');
|
|
47
|
+
}
|
|
48
|
+
// Whether a backend's application_name says it is pg-boss, as this connection is: the same name, or
|
|
49
|
+
// both one of pg-boss's own names. Either form on either side, so an instance still on 'pgboss'
|
|
50
|
+
// during a rolling upgrade reads as pg-boss to an upgraded one. Another pg-boss instance pinning the
|
|
51
|
+
// horizon takes the same fix as this one doing it.
|
|
52
|
+
function isPgBossHolder(app, self) {
|
|
53
|
+
if (!app)
|
|
54
|
+
return false;
|
|
55
|
+
if (app === self)
|
|
56
|
+
return true;
|
|
57
|
+
return isPgBossName(app) && isPgBossName(self);
|
|
58
|
+
}
|
|
43
59
|
// Name the holder as specifically as the catalog allowed. Falls back to the holder class when the
|
|
44
60
|
// source is not a backend (a replication slot has no pid to report) or when no backend row came
|
|
45
61
|
// back, so the warning never loses the description it had before.
|
|
@@ -64,7 +80,9 @@ function describeXminHolder(source, row) {
|
|
|
64
80
|
? 'a backend with no application_name'
|
|
65
81
|
: app === row.selfApplicationName
|
|
66
82
|
? "this application's own connection"
|
|
67
|
-
:
|
|
83
|
+
: isPgBossHolder(app, row.selfApplicationName)
|
|
84
|
+
? "another pg-boss instance's connection"
|
|
85
|
+
: 'another application';
|
|
68
86
|
return `${who} (${where}) has held a transaction open ${open}`;
|
|
69
87
|
}
|
|
70
88
|
// SQLSTATE 25001 (active_sql_transaction): "REINDEX CONCURRENTLY cannot run inside a transaction
|
|
@@ -204,6 +222,18 @@ class Boss extends EventEmitter {
|
|
|
204
222
|
const sql = plans.deleteOldWarnings(this.#config.schema, this.#config.warningRetentionDays);
|
|
205
223
|
await this.#executeQuery(sql);
|
|
206
224
|
}
|
|
225
|
+
// Whether or not this instance registers: the registry is the database's, not this instance's.
|
|
226
|
+
// Best effort: a failure is emitted and the pass goes on to the reindex, since a role granted
|
|
227
|
+
// privileges table by table may have none on the instance table yet.
|
|
228
|
+
async #maintainInstances() {
|
|
229
|
+
try {
|
|
230
|
+
await this.#executeQuery(plans.deleteOldInstances(this.#config.schema, plans.INSTANCE_RETENTION_DAYS));
|
|
231
|
+
await this.#executeQuery(plans.trimDeadInstances(this.#config.schema, plans.INSTANCE_DEAD_KEPT));
|
|
232
|
+
}
|
|
233
|
+
catch (err) {
|
|
234
|
+
this.emit(events.error, err);
|
|
235
|
+
}
|
|
236
|
+
}
|
|
207
237
|
async #ensureQueueStatsPartitions() {
|
|
208
238
|
const sql = plans.ensureQueueStatsPartitions(this.#config.schema);
|
|
209
239
|
await this.#executeQuery(sql);
|
|
@@ -286,6 +316,7 @@ class Boss extends EventEmitter {
|
|
|
286
316
|
await this.#checkVacuum();
|
|
287
317
|
await this.#maintainWarnings();
|
|
288
318
|
await this.#maintainQueueStats();
|
|
319
|
+
await this.#maintainInstances();
|
|
289
320
|
// Last in the pass: a rebuild is DDL that can run for seconds, so nothing time-sensitive
|
|
290
321
|
// (expiry, deletion, stats) should ever queue behind it.
|
|
291
322
|
await this.#reindex(Object.keys(queueGroups), options);
|
|
@@ -614,14 +645,14 @@ class Boss extends EventEmitter {
|
|
|
614
645
|
holder: describeXminHolder(holder.source, horizon.row),
|
|
615
646
|
holderClass: XMIN_HOLDERS[holder.source],
|
|
616
647
|
// Null unless the holder is a backend this role could read a row for. `self` says whether it
|
|
617
|
-
//
|
|
618
|
-
// external reporting tool pinning it have opposite fixes.
|
|
648
|
+
// is pg-boss: this connection's application_name, or another pg-boss instance's. A pg-boss
|
|
649
|
+
// instance pinning its own horizon and an external reporting tool pinning it have opposite fixes.
|
|
619
650
|
holderPid: backend?.pid ?? null,
|
|
620
651
|
holderApplicationName: backend?.applicationName ?? null,
|
|
621
652
|
holderUserName: backend?.userName ?? null,
|
|
622
653
|
holderState: backend?.state ?? null,
|
|
623
654
|
holderTransactionSeconds: backend?.xactSeconds ?? null,
|
|
624
|
-
self: backend ? backend.applicationName
|
|
655
|
+
self: backend ? isPgBossHolder(backend.applicationName || null, horizon.row.selfApplicationName) : null,
|
|
625
656
|
// Backends whose transaction this role is not allowed to time. Non-zero means the picture is
|
|
626
657
|
// partial, whether or not a holder was named.
|
|
627
658
|
opaqueBackends: opaque,
|
package/dist/db.d.ts
CHANGED
|
@@ -15,6 +15,7 @@ declare class Db extends EventEmitter implements types.IDatabase, types.EventsMi
|
|
|
15
15
|
};
|
|
16
16
|
open(): Promise<void>;
|
|
17
17
|
close(): Promise<void>;
|
|
18
|
+
poolCounts(): types.PoolCounts | null;
|
|
18
19
|
setSessionStatements(statements: string[]): Promise<void>;
|
|
19
20
|
executeSql(text: string, values?: unknown[]): Promise<import("pg").QueryResult<any>>;
|
|
20
21
|
listen(channel: string, onNotification: (payload: string) => void, onReconnect: () => void): Promise<types.ListenHandle>;
|
package/dist/db.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"db.d.ts","sourceRoot":"","sources":["../src/db.ts"],"names":[],"mappings":"AAAA,OAAO,YAAY,MAAM,aAAa,CAAA;AAItC,OAAO,KAAK,KAAK,KAAK,MAAM,YAAY,CAAA;AAaxC,eAAO,MAAM,+BAA+B,OAAO,CAAA;AAEnD,cAAM,EAAG,SAAQ,YAAa,YAAW,KAAK,CAAC,SAAS,EAAE,KAAK,CAAC,WAAW;IACzE,OAAO,CAAC,IAAI,C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iBAAiB,CAAC;IAsFrD,eAAe,CAAC,CAAC,EAAG,EAAE,EAAE,CAAC,EAAE,EAAE,KAAK,CAAC,SAAS,KAAK,OAAO,CAAC,CAAC,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC;CAY/E;AAED,eAAe,EAAE,CAAA"}
|
package/dist/db.js
CHANGED
|
@@ -55,6 +55,17 @@ class Db extends EventEmitter {
|
|
|
55
55
|
await this.pool.end();
|
|
56
56
|
}
|
|
57
57
|
}
|
|
58
|
+
// The pool's size and use, for the instance registry's heartbeat. Null before open() and after close().
|
|
59
|
+
poolCounts() {
|
|
60
|
+
if (!this.opened)
|
|
61
|
+
return null;
|
|
62
|
+
return {
|
|
63
|
+
max: this.pool.options.max ?? 10,
|
|
64
|
+
total: this.pool.totalCount,
|
|
65
|
+
idle: this.pool.idleCount,
|
|
66
|
+
waiting: this.pool.waitingCount
|
|
67
|
+
};
|
|
68
|
+
}
|
|
58
69
|
async setSessionStatements(statements) {
|
|
59
70
|
// Clearing is always safe: the statements it would have run are the ones already applied, and
|
|
60
71
|
// undoing them is the caller's job.
|
package/dist/index.d.ts
CHANGED
|
@@ -6,6 +6,7 @@ export { QUEUE_POLICIES as policies } from './plans.ts';
|
|
|
6
6
|
export { SCHEDULE_KINDS as scheduleKinds } from './plans.ts';
|
|
7
7
|
export { SCHEDULE_MISSED_POLICIES as scheduleMissedPolicies } from './plans.ts';
|
|
8
8
|
export { PREVIEW_MAX_COUNT as previewScheduleMaxCount } from './timekeeper.ts';
|
|
9
|
+
export { addBins, percentile } from './latency.ts';
|
|
9
10
|
export declare const events: types.Events;
|
|
10
11
|
export declare function getConstructionPlans(schema?: string, options?: types.ConstructionPlanOptions): string;
|
|
11
12
|
export declare function getMigrationPlans(schema?: string, version?: number, options?: types.MigrationPlanOptions): string;
|
|
@@ -72,6 +73,7 @@ export declare class PgBoss extends EventEmitter<types.PgBossEventMap> {
|
|
|
72
73
|
getQueues(names?: string[]): Promise<types.QueueResult[]>;
|
|
73
74
|
getQueue(name: string): Promise<types.QueueResult | null>;
|
|
74
75
|
getQueueStats(name: string, options?: types.QueueStatsOptions): Promise<types.QueueStats[]>;
|
|
76
|
+
getInstances(): Promise<types.Instance[]>;
|
|
75
77
|
isMaintaining(): boolean;
|
|
76
78
|
isBamWorking(): boolean;
|
|
77
79
|
isResolvingFlow(): boolean;
|
|
@@ -113,7 +115,7 @@ export declare class PgBoss extends EventEmitter<types.PgBossEventMap> {
|
|
|
113
115
|
}
|
|
114
116
|
export { systemClock, TestClock } from './clock.ts';
|
|
115
117
|
export { CLOCK_OVERRIDE_SETTING, enableClockOverride, disableClockOverride } from './plans.ts';
|
|
116
|
-
export type { BackendProfile, BackendOptions, AttachableClock, Clock, ClockTimer, BamEntry, BamEvent, BamStatusSummary, CommandResponse, CompleteOptions, ConnectionOptions, ConstructorOptions, DatabaseOptions, FetchGroupConcurrencyOptions, DependencyRef, FetchOptions, FindJobsOptions, FlowJob, GroupConcurrencyConfig, GroupOptions, IDatabase as Db, InsertOptions, IndexBloat, IndexBloatOptions, InvalidIndex, Job, JobFetchOptions, JobInsert, JobMatchStrategy, JobOptions, JobPollingOptions, JobResult, JobResultStatus, JobStates, Events, JobWithMetadata, MaintenanceOptions, ManagedIndex, MigrationPartition, AsyncMigrationCommand, MismatchedIndex, ManagedFunction, MismatchedFunction, TableColumnDrift, ConstraintDrift, EnumDrift, OffWorkOptions, PgBossEventMap, PreviewScheduleOptions, Queue, QueueOptions, QueuePolicy, QueueResult, QueueStats, QueueStatsOptions, RedriveFilter, RedriveOptions, RedrivePreview, ReindexOptions, Request, Schedule, ScheduleKind, ScheduleOptions, SchedulingOptions, SchemaDriftReport, SendOptions, StopOptions, SuperviseOptions, UpdateOptions, UpdateQueueOptions, UpdateRequest, UpdateResponse, UpsertResponse, Warning, WipData, WorkConcurrencyOptions, WorkerState, WorkHandler, WorkOptions, WorkWithMetadataHandler, WorkHandlerFor, PerJobWorkHandler, PerJobWorkWithMetadataHandler, } from './types.ts';
|
|
118
|
+
export type { BackendProfile, BackendOptions, AttachableClock, Clock, ClockTimer, BamEntry, BamEvent, BamStatusSummary, CommandResponse, CompleteOptions, ConnectionOptions, ConstructorOptions, DatabaseOptions, FetchGroupConcurrencyOptions, DependencyRef, FetchOptions, FindJobsOptions, FlowJob, GroupConcurrencyConfig, GroupOptions, IDatabase as Db, InsertOptions, IndexBloat, IndexBloatOptions, InvalidIndex, Job, JobAttempt, JobFetchOptions, JobInsert, JobMatchStrategy, JobOptions, JobPollingOptions, JobResult, JobResultStatus, JobStates, Events, JobWithMetadata, MaintenanceOptions, ManagedIndex, MigrationPartition, AsyncMigrationCommand, MismatchedIndex, ManagedFunction, MismatchedFunction, TableColumnDrift, ConstraintDrift, EnumDrift, OffWorkOptions, OpenTelemetryOptions, PgBossEventMap, PreviewScheduleOptions, Queue, QueueOptions, QueuePolicy, QueueResult, QueueStats, QueueStatsPercentile, Instance, InstanceMetrics, InstanceOptions, InstanceWorker, PoolCounts, QueueStatsOptions, RedriveFilter, RedriveOptions, RedrivePreview, ReindexOptions, Request, Schedule, ScheduleKind, ScheduleOptions, SchedulingOptions, SchemaDriftReport, SendOptions, StopOptions, SuperviseOptions, UpdateOptions, UpdateQueueOptions, UpdateRequest, UpdateResponse, UpsertResponse, Warning, WipData, WorkConcurrencyOptions, WorkerState, WorkHandler, WorkOptions, WorkWithMetadataHandler, WorkHandlerFor, PerJobWorkHandler, PerJobWorkWithMetadataHandler, } from './types.ts';
|
|
117
119
|
export type { JobSpyInterface, JobSpyState, JobDataSelector, JobSelector, SpyJob, } from './spy.ts';
|
|
118
120
|
export { fromKnex, fromKysely, fromDrizzle, fromPrisma, fromPglite, fromBunSql, } from './adapters/index.ts';
|
|
119
121
|
export type { KnexTransactionLike, KyselyTransactionLike, DrizzleTransactionLike, DrizzleSqlTagLike, PrismaTransactionLike, PGliteLike, BunSqlLike, BunReservedSqlLike, } from './adapters/index.ts';
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAEA,OAAO,YAAY,MAAM,aAAa,CAAA;AAatC,OAAO,KAAK,KAAK,KAAK,MAAM,YAAY,CAAA;AAGxC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,UAAU,CAAA;AAE/C,OAAO,EAAE,UAAU,IAAI,MAAM,EAAE,MAAM,YAAY,CAAA;AACjD,OAAO,EAAE,cAAc,IAAI,QAAQ,EAAE,MAAM,YAAY,CAAA;AACvD,OAAO,EAAE,cAAc,IAAI,aAAa,EAAE,MAAM,YAAY,CAAA;AAC5D,OAAO,EAAE,wBAAwB,IAAI,sBAAsB,EAAE,MAAM,YAAY,CAAA;AAC/E,OAAO,EAAE,iBAAiB,IAAI,uBAAuB,EAAE,MAAM,iBAAiB,CAAA;AAC9E,OAAO,EAAE,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AAElD,eAAO,MAAM,MAAM,EAAE,KAAK,CAAC,MAOzB,CAAA;AAEF,wBAAgB,oBAAoB,CAAE,MAAM,CAAC,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,KAAK,CAAC,uBAAuB,UAE7F;AAED,wBAAgB,iBAAiB,CAAE,MAAM,CAAC,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,KAAK,CAAC,oBAAoB,UAEzG;AAED;;;;GAIG;AACH,wBAAgB,kBAAkB,CAAE,MAAM,CAAC,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,KAAK,CAAC,iBAAiB,UAErF;AAED,wBAAgB,gBAAgB,CAAE,MAAM,CAAC,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,KAAK,CAAC,WAAW,UAE/F;AAED,qBAAa,MAAO,SAAQ,YA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9B,MAAM,YAAY,CAAA;AAEnB,YAAY,EACV,eAAe,EACf,WAAW,EACX,eAAe,EACf,WAAW,EACX,MAAM,GACP,MAAM,UAAU,CAAA;AAEjB,OAAO,EACL,QAAQ,EACR,UAAU,EACV,WAAW,EACX,UAAU,EACV,UAAU,EACV,UAAU,GACX,MAAM,qBAAqB,CAAA;AAE5B,YAAY,EACV,mBAAmB,EACnB,qBAAqB,EACrB,sBAAsB,EACtB,iBAAiB,EACjB,qBAAqB,EACrB,UAAU,EACV,UAAU,EACV,kBAAkB,GACnB,MAAM,qBAAqB,CAAA"}
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import assert from 'node:assert';
|
|
2
|
+
import { randomUUID } from 'node:crypto';
|
|
2
3
|
import EventEmitter from 'node:events';
|
|
3
4
|
import * as Attorney from "./attorney.js";
|
|
4
5
|
import Contractor from "./contractor.js";
|
|
@@ -8,6 +9,7 @@ import Boss from "./boss.js";
|
|
|
8
9
|
import Bam from "./bam.js";
|
|
9
10
|
import Navigator from "./navigator.js";
|
|
10
11
|
import Notifier from "./notifier.js";
|
|
12
|
+
import Registrar from "./registrar.js";
|
|
11
13
|
import { delay } from "./tools.js";
|
|
12
14
|
import { isAttachable } from "./clock.js";
|
|
13
15
|
import { trackActivity } from "./activity.js";
|
|
@@ -18,6 +20,7 @@ export { QUEUE_POLICIES as policies } from "./plans.js";
|
|
|
18
20
|
export { SCHEDULE_KINDS as scheduleKinds } from "./plans.js";
|
|
19
21
|
export { SCHEDULE_MISSED_POLICIES as scheduleMissedPolicies } from "./plans.js";
|
|
20
22
|
export { PREVIEW_MAX_COUNT as previewScheduleMaxCount } from "./timekeeper.js";
|
|
23
|
+
export { addBins, percentile } from "./latency.js";
|
|
21
24
|
export const events = Object.freeze({
|
|
22
25
|
error: 'error',
|
|
23
26
|
warning: 'warning',
|
|
@@ -59,11 +62,19 @@ export class PgBoss extends EventEmitter {
|
|
|
59
62
|
#bam;
|
|
60
63
|
#navigator;
|
|
61
64
|
#notifier;
|
|
65
|
+
#registrar;
|
|
62
66
|
constructor(value) {
|
|
63
67
|
super();
|
|
64
68
|
this.#stopped = true;
|
|
65
69
|
const config = Attorney.getConfig(value);
|
|
66
70
|
this.#config = config;
|
|
71
|
+
// Made here rather than at start(), since the pool is configured before it opens. Naming the
|
|
72
|
+
// connections after the instance is what lets pg_stat_activity join to its registry row. Only
|
|
73
|
+
// on a pool pg-boss creates, and never over a name the caller chose.
|
|
74
|
+
const instanceId = randomUUID();
|
|
75
|
+
if (config.registerInstance && !config.db && !config.application_name) {
|
|
76
|
+
config.application_name = `pgboss:${instanceId.slice(0, 8)}`;
|
|
77
|
+
}
|
|
67
78
|
let db = this.getDb();
|
|
68
79
|
// Before any component takes the db, so every statement they run is counted.
|
|
69
80
|
if (isAttachable(config.clock)) {
|
|
@@ -84,12 +95,14 @@ export class PgBoss extends EventEmitter {
|
|
|
84
95
|
const navigator = new Navigator(db, manager, config);
|
|
85
96
|
const notifier = new Notifier(db, manager, config);
|
|
86
97
|
manager.notifier = notifier;
|
|
98
|
+
const registrar = new Registrar(instanceId, db, manager, config);
|
|
87
99
|
this.#promoteEvents(manager);
|
|
88
100
|
this.#promoteEvents(boss);
|
|
89
101
|
this.#promoteEvents(timekeeper);
|
|
90
102
|
this.#promoteEvents(bam);
|
|
91
103
|
this.#promoteEvents(navigator);
|
|
92
104
|
this.#promoteEvents(notifier);
|
|
105
|
+
this.#promoteEvents(registrar);
|
|
93
106
|
this.#boss = boss;
|
|
94
107
|
this.#contractor = contractor;
|
|
95
108
|
this.#manager = manager;
|
|
@@ -97,6 +110,7 @@ export class PgBoss extends EventEmitter {
|
|
|
97
110
|
this.#bam = bam;
|
|
98
111
|
this.#navigator = navigator;
|
|
99
112
|
this.#notifier = notifier;
|
|
113
|
+
this.#registrar = registrar;
|
|
100
114
|
}
|
|
101
115
|
#promoteEvents(emitter) {
|
|
102
116
|
for (const event of Object.values(emitter?.events)) {
|
|
@@ -165,6 +179,7 @@ export class PgBoss extends EventEmitter {
|
|
|
165
179
|
if (this.#config.migrate) {
|
|
166
180
|
await this.#bam.start();
|
|
167
181
|
}
|
|
182
|
+
await this.#registrar.start();
|
|
168
183
|
this.#started = true;
|
|
169
184
|
return this;
|
|
170
185
|
}
|
|
@@ -233,6 +248,8 @@ export class PgBoss extends EventEmitter {
|
|
|
233
248
|
await this.#bam.stop();
|
|
234
249
|
const shutdown = async () => {
|
|
235
250
|
await this.#manager.failWip();
|
|
251
|
+
// After the drain, so a graceful stop reads as live until its workers have finished.
|
|
252
|
+
await this.#registrar.stop();
|
|
236
253
|
const attachment = this.#attachedClock;
|
|
237
254
|
this.#attachedClock = null;
|
|
238
255
|
try {
|
|
@@ -263,12 +280,10 @@ export class PgBoss extends EventEmitter {
|
|
|
263
280
|
}
|
|
264
281
|
// Real time, not the configured clock: the deadline bounds shutdown I/O, and under a test
|
|
265
282
|
// clock nothing would tick it while the test is blocked inside stop().
|
|
266
|
-
|
|
267
|
-
const
|
|
283
|
+
let deadlineTimer;
|
|
284
|
+
const deadline = new Promise(resolve => { deadlineTimer = setTimeout(resolve, timeout); });
|
|
268
285
|
try {
|
|
269
|
-
|
|
270
|
-
await delay(500);
|
|
271
|
-
}
|
|
286
|
+
await Promise.race([this.#manager.settleCleanups(), deadline]);
|
|
272
287
|
}
|
|
273
288
|
finally {
|
|
274
289
|
clearTimeout(deadlineTimer);
|
|
@@ -400,6 +415,9 @@ export class PgBoss extends EventEmitter {
|
|
|
400
415
|
getQueueStats(name, options) {
|
|
401
416
|
return this.#manager.getQueueStats(name, options);
|
|
402
417
|
}
|
|
418
|
+
getInstances() {
|
|
419
|
+
return this.#registrar.getInstances();
|
|
420
|
+
}
|
|
403
421
|
isMaintaining() {
|
|
404
422
|
return this.#boss.maintaining;
|
|
405
423
|
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
type Bins = number[] | null | undefined;
|
|
2
|
+
/**
|
|
3
|
+
* Combines two wait or run histograms into one by adding their counts bin by bin, as if all their
|
|
4
|
+
* jobs had been recorded together. A null histogram counts as empty; null only when both are.
|
|
5
|
+
* @see https://pgboss.io/api/utils#addbins-a-b
|
|
6
|
+
*/
|
|
7
|
+
export declare function addBins(a: Bins, b: Bins): number[] | null;
|
|
8
|
+
/**
|
|
9
|
+
* The time in seconds below which `p` percent (1 to 100) of a wait or run histogram's jobs fall,
|
|
10
|
+
* estimated within its bin, so `percentile(bins, 95)` is the p95. Null for an empty histogram.
|
|
11
|
+
* @see https://pgboss.io/api/utils#percentile-bins-p
|
|
12
|
+
*/
|
|
13
|
+
export declare function percentile(bins: Bins, p: number): number | null;
|
|
14
|
+
export {};
|
|
15
|
+
//# sourceMappingURL=latency.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"latency.d.ts","sourceRoot":"","sources":["../src/latency.ts"],"names":[],"mappings":"AAGA,KAAK,IAAI,GAAG,MAAM,EAAE,GAAG,IAAI,GAAG,SAAS,CAAA;AAMvC;;;;GAIG;AACH,wBAAgB,OAAO,CAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,GAAG,MAAM,EAAE,GAAG,IAAI,CAI1D;AAED;;;;GAIG;AACH,wBAAgB,UAAU,CAAE,IAAI,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAoBhE"}
|
package/dist/latency.js
ADDED
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import assert from 'node:assert';
|
|
2
|
+
import { LATENCY_MIN_SECONDS } from "./plans.js";
|
|
3
|
+
function total(bins) {
|
|
4
|
+
return bins.reduce((sum, n) => sum + n, 0);
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* Combines two wait or run histograms into one by adding their counts bin by bin, as if all their
|
|
8
|
+
* jobs had been recorded together. A null histogram counts as empty; null only when both are.
|
|
9
|
+
* @see https://pgboss.io/api/utils#addbins-a-b
|
|
10
|
+
*/
|
|
11
|
+
export function addBins(a, b) {
|
|
12
|
+
if (!b)
|
|
13
|
+
return a ? [...a] : null;
|
|
14
|
+
if (!a)
|
|
15
|
+
return [...b];
|
|
16
|
+
return a.map((n, i) => n + (b[i] ?? 0));
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* The time in seconds below which `p` percent (1 to 100) of a wait or run histogram's jobs fall,
|
|
20
|
+
* estimated within its bin, so `percentile(bins, 95)` is the p95. Null for an empty histogram.
|
|
21
|
+
* @see https://pgboss.io/api/utils#percentile-bins-p
|
|
22
|
+
*/
|
|
23
|
+
export function percentile(bins, p) {
|
|
24
|
+
assert(typeof p === 'number' && p >= 1 && p <= 100, 'percentile: p must be a percent from 1 to 100, such as 95');
|
|
25
|
+
if (!bins)
|
|
26
|
+
return null;
|
|
27
|
+
const n = total(bins);
|
|
28
|
+
if (n === 0)
|
|
29
|
+
return null;
|
|
30
|
+
// Walk to the slot holding the target job. A valid histogram always reaches it; the last slot
|
|
31
|
+
// stops the walk regardless, so counts that do not add up cannot run past the end.
|
|
32
|
+
const target = p / 100 * n;
|
|
33
|
+
let k = 0;
|
|
34
|
+
let seen = 0;
|
|
35
|
+
while (k < bins.length - 1 && !(bins[k] > 0 && seen + bins[k] >= target))
|
|
36
|
+
seen += bins[k++];
|
|
37
|
+
// Slot 0 has no lower edge, so a percentile in it is only known to be under 10 ms. The last slot
|
|
38
|
+
// has no upper edge, so a percentile in it is only known to be past its lower edge.
|
|
39
|
+
if (k === 0)
|
|
40
|
+
return LATENCY_MIN_SECONDS;
|
|
41
|
+
const lo = LATENCY_MIN_SECONDS * Math.SQRT2 ** (k - 1);
|
|
42
|
+
if (k === bins.length - 1)
|
|
43
|
+
return lo;
|
|
44
|
+
return lo * Math.SQRT2 ** ((target - seen) / bins[k]);
|
|
45
|
+
}
|
package/dist/manager.d.ts
CHANGED
|
@@ -44,7 +44,8 @@ declare class Manager extends EventEmitter implements types.EventsMixin {
|
|
|
44
44
|
getWipData(options?: {
|
|
45
45
|
includeInternal?: boolean;
|
|
46
46
|
}): types.WipData[];
|
|
47
|
-
|
|
47
|
+
trackCleanup(cleanup: Promise<unknown>): void;
|
|
48
|
+
settleCleanups(): Promise<void>;
|
|
48
49
|
offWork(name: string, options?: types.OffWorkOptions): Promise<void>;
|
|
49
50
|
notifyWorker(workerId: string): void;
|
|
50
51
|
notifyQueue(name: string): void;
|
package/dist/manager.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"manager.d.ts","sourceRoot":"","sources":["../src/manager.ts"],"names":[],"mappings":"AAEA,OAAO,YAAY,MAAM,aAAa,CAAA;AAItC,OAAO,KAAK,EAAE,MAAM,SAAS,CAAA;AAE7B,OAAO,KAAK,QAAQ,MAAM,eAAe,CAAA;
|
|
1
|
+
{"version":3,"file":"manager.d.ts","sourceRoot":"","sources":["../src/manager.ts"],"names":[],"mappings":"AAEA,OAAO,YAAY,MAAM,aAAa,CAAA;AAItC,OAAO,KAAK,EAAE,MAAM,SAAS,CAAA;AAE7B,OAAO,KAAK,QAAQ,MAAM,eAAe,CAAA;AAGzC,OAAO,KAAK,UAAU,MAAM,iBAAiB,CAAA;AAG7C,OAAO,KAAK,KAAK,MAAM,YAAY,CAAA;AACnC,OAAO,MAAM,MAAM,aAAa,CAAA;AAChC,OAAO,EAAU,KAAK,eAAe,EAAE,MAAM,UAAU,CAAA;AAgLvD,cAAM,OAAQ,SAAQ,YAAa,YAAW,KAAK,CAAC,WAAW;;IAC7D,MAAM;;;;MAAS;IAGf,EAAE,EAAE,CAAC,KAAK,CAAC,SAAS,GAAG;QAAE,MAAM,CAAC,EAAE,KAAK,CAAA;KAAE,CAAC,GAAG,EAAE,CAAA;IAC/C,MAAM,EAAE,KAAK,CAAC,0BAA0B,CAAA;IACxC,KAAK,EAAE,MAAM,CAAA;IACb,OAAO,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;IAC5B,OAAO,EAAE,OAAO,GAAG,SAAS,CAAA;IAC5B,kBA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