Skip to content

Rulvar API reference


Rulvar API reference / @rulvar/store-postgres / QuotaGenerationError

Class: QuotaGenerationError ​

Defined in: packages/store-postgres/src/quota.ts:146

Thrown by an admission whose booted rule identity no longer matches the schema's (RV608): another deployment rotated the recorded rules fingerprint and generation after this host booted, so admitting under the retired rules would silently split the budget across mismatched bucket keys. The refused host must restart with the current rule set; its outstanding reservations age out with their window (the same bounded residue a crashed process leaves), and the rotation carried current-window consumption conservatively. Like every limiter throw, it lands in the engine's onLimiterError policy.

Extends ​

  • Error

Constructors ​

Constructor ​

ts
new QuotaGenerationError(
   schema, 
   booted, 
   recorded): QuotaGenerationError;

Defined in: packages/store-postgres/src/quota.ts:154

Parameters ​

ParameterType
schemastring
booted{ fingerprint: string; generation: number; }
booted.fingerprintstring
booted.generationnumber
recorded{ fingerprint: string | undefined; generation: number | undefined; }
recorded.fingerprintstring | undefined
recorded.generationnumber | undefined

Returns ​

QuotaGenerationError

Overrides ​

ts
Error.constructor

Properties ​

PropertyModifierTypeDescriptionDefined in
bootedreadonly{ fingerprint: string; generation: number; }What this instance booted with.packages/store-postgres/src/quota.ts:150
booted.fingerprintpublicstring-packages/store-postgres/src/quota.ts:150
booted.generationpublicnumber-packages/store-postgres/src/quota.ts:150
recordedreadonly{ fingerprint: string | undefined; generation: number | undefined; }What the schema records now (absent fields mean a wiped meta row).packages/store-postgres/src/quota.ts:152
recorded.fingerprintpublicstring | undefined-packages/store-postgres/src/quota.ts:152
recorded.generationpublicnumber | undefined-packages/store-postgres/src/quota.ts:152
schemareadonlystringThe schema whose recorded identity moved.packages/store-postgres/src/quota.ts:148