velocious 1.0.495 → 1.0.496

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.
Files changed (60) hide show
  1. package/build/database/record/index.js +2 -0
  2. package/build/database/record/validation-messages.js +50 -0
  3. package/build/database/record/validators/length.js +52 -0
  4. package/build/database/record/validators/presence.js +4 -1
  5. package/build/database/record/validators/uniqueness.js +4 -1
  6. package/build/frontend-model-resource/base-resource.js +175 -5
  7. package/build/frontend-models/resource-definition.js +46 -0
  8. package/build/src/database/record/index.d.ts.map +1 -1
  9. package/build/src/database/record/index.js +3 -1
  10. package/build/src/database/record/validation-messages.d.ts +38 -0
  11. package/build/src/database/record/validation-messages.d.ts.map +1 -0
  12. package/build/src/database/record/validation-messages.js +45 -0
  13. package/build/src/database/record/validators/length.d.ts +12 -0
  14. package/build/src/database/record/validators/length.d.ts.map +1 -0
  15. package/build/src/database/record/validators/length.js +45 -0
  16. package/build/src/database/record/validators/presence.d.ts.map +1 -1
  17. package/build/src/database/record/validators/presence.js +4 -2
  18. package/build/src/database/record/validators/uniqueness.d.ts.map +1 -1
  19. package/build/src/database/record/validators/uniqueness.js +4 -2
  20. package/build/src/frontend-model-resource/base-resource.d.ts +184 -5
  21. package/build/src/frontend-model-resource/base-resource.d.ts.map +1 -1
  22. package/build/src/frontend-model-resource/base-resource.js +155 -6
  23. package/build/src/frontend-models/resource-definition.d.ts +41 -0
  24. package/build/src/frontend-models/resource-definition.d.ts.map +1 -1
  25. package/build/src/frontend-models/resource-definition.js +42 -1
  26. package/build/src/sync/sync-envelope-replay-service.d.ts +166 -3
  27. package/build/src/sync/sync-envelope-replay-service.d.ts.map +1 -1
  28. package/build/src/sync/sync-envelope-replay-service.js +304 -12
  29. package/build/src/sync/sync-replay-upsert-applier.d.ts +1 -0
  30. package/build/src/sync/sync-replay-upsert-applier.d.ts.map +1 -1
  31. package/build/src/sync/sync-replay-upsert-applier.js +2 -1
  32. package/build/src/sync/sync-resource-base.d.ts +16 -32
  33. package/build/src/sync/sync-resource-base.d.ts.map +1 -1
  34. package/build/src/sync/sync-resource-base.js +31 -43
  35. package/build/src/testing/test-runner.d.ts +12 -9
  36. package/build/src/testing/test-runner.d.ts.map +1 -1
  37. package/build/src/testing/test-runner.js +30 -9
  38. package/build/sync/sync-envelope-replay-service.js +350 -10
  39. package/build/sync/sync-replay-upsert-applier.js +1 -0
  40. package/build/sync/sync-resource-base.js +32 -45
  41. package/build/testing/test-runner.js +30 -8
  42. package/build/tsconfig.tsbuildinfo +1 -1
  43. package/package.json +1 -1
  44. package/scripts/run-tests.js +6 -0
  45. package/src/database/record/index.js +2 -0
  46. package/src/database/record/validation-messages.js +50 -0
  47. package/src/database/record/validators/length.js +52 -0
  48. package/src/database/record/validators/presence.js +4 -1
  49. package/src/database/record/validators/uniqueness.js +4 -1
  50. package/src/frontend-model-resource/base-resource.js +175 -5
  51. package/src/frontend-models/resource-definition.js +46 -0
  52. package/src/sync/sync-envelope-replay-service.js +350 -10
  53. package/src/sync/sync-replay-upsert-applier.js +1 -0
  54. package/src/sync/sync-resource-base.js +32 -45
  55. package/src/testing/test-runner.js +30 -8
  56. package/build/src/sync/sync-attribute-normalizer.d.ts +0 -105
  57. package/build/src/sync/sync-attribute-normalizer.d.ts.map +0 -1
  58. package/build/src/sync/sync-attribute-normalizer.js +0 -172
  59. package/build/sync/sync-attribute-normalizer.js +0 -186
  60. package/src/sync/sync-attribute-normalizer.js +0 -186
@@ -32,11 +32,16 @@ export default class SyncEnvelopeReplayService {
32
32
  * @param {?} [args.authenticationTokenModel] - Token model enabling the default token-lookup authenticateReplay.
33
33
  * @param {string} [args.authenticationTokenColumn] - Token model column holding the token. Defaults to "token".
34
34
  * @param {string} [args.authenticationTokenParam] - Request param carrying the token. Defaults to "authenticationToken".
35
- * @param {Record<string, ((args: Record<string, ?>) => Promise<?>) | ConstructorParameters<typeof SyncReplayUpsertApplier>[0]>} [args.applyHandlers] - Per-resourceType apply handlers (functions or declarative upsert-applier specs) enabling the default applyReplayMutation dispatch.
35
+ * @param {Record<string, ((args: Record<string, ?>) => Promise<?>) | ConstructorParameters<typeof SyncReplayUpsertApplier>[0]>} [args.applyHandlers] - Per-resourceType apply handlers (functions or declarative upsert-applier specs) enabling the default applyReplayMutation dispatch. Deprecated: prefer resource routing via `configuration`/`resourceTypeOverrides`; applyHandlers remain for released adopters and will be removed after their migration.
36
36
  * @param {(args: Record<string, ?>) => Record<string, ?>} [args.persistExtraAttributes] - Extra attributes merged into the model-backed persisted row (e.g. an event scope column).
37
37
  * @param {(args: {mutation: ?, applyResult: ?}) => ?} [args.persistSerializedData] - Overrides the persisted data payload (object results are JSON stringified).
38
38
  * @param {(broadcast: {channel: string, params: Record<string, ?>, body: ?}) => Promise<void>} [args.broadcaster] - Delivers declarative broadcasts. Required when broadcasts are configured.
39
39
  * @param {SyncReplayBroadcast[]} [args.broadcasts] - Broadcasts fanned out by the default afterReplayMutation.
40
+ * @param {{getBackendProjects: () => import("../configuration-types.js").BackendProjectConfiguration[]}} [args.configuration] - Configuration whose frontend-model registry routes mutations to resource classes.
41
+ * @param {Record<string, import("../configuration-types.js").FrontendModelResourceClassType | string>} [args.resourceTypeOverrides] - Per-resourceType routing overrides: a resource class, or a string alias resolved through the registry.
42
+ * @param {import("../authorization/ability.js").default} [args.ability] - Ability scoping routed record lookups and create membership checks.
43
+ * @param {Record<string, ?>} [args.abilityContext] - Ability context passed to routed resources.
44
+ * @param {Record<string, ?>} [args.locals] - Locals passed to routed resources.
40
45
  */
41
46
  constructor(args?: {
42
47
  logger?: {
@@ -87,6 +92,13 @@ export default class SyncEnvelopeReplayService {
87
92
  body: unknown;
88
93
  }) => Promise<void>) | undefined;
89
94
  broadcasts?: SyncReplayBroadcast[] | undefined;
95
+ configuration?: {
96
+ getBackendProjects: () => import("../configuration-types.js").BackendProjectConfiguration[];
97
+ } | undefined;
98
+ resourceTypeOverrides?: Record<string, string | import("../configuration-types.js").FrontendModelResourceClassType> | undefined;
99
+ ability?: import("../authorization/ability.js").default | undefined;
100
+ abilityContext?: Record<string, any> | undefined;
101
+ locals?: Record<string, any> | undefined;
90
102
  });
91
103
  logger: {
92
104
  debug?: (...args: Array<unknown>) => void;
@@ -109,6 +121,15 @@ export default class SyncEnvelopeReplayService {
109
121
  }) => Promise<void>) | null;
110
122
  broadcasts: SyncReplayBroadcast[] | null;
111
123
  applyHandlers: Record<string, (args: Record<string, unknown>) => Promise<unknown>> | null;
124
+ configuration: {
125
+ getBackendProjects: () => import("../configuration-types.js").BackendProjectConfiguration[];
126
+ } | null;
127
+ resourceTypeOverrides: Record<string, string | import("../configuration-types.js").FrontendModelResourceClassType> | null;
128
+ ability: import("../authorization/ability.js").default | null;
129
+ abilityContext: Record<string, any> | null;
130
+ locals: Record<string, any> | null;
131
+ /** @type {Map<string, SyncReplayResourceRegistration | null>} */
132
+ _replayResourceRegistrations: Map<string, SyncReplayResourceRegistration | null>;
112
133
  /**
113
134
  * Wraps declarative apply-handler specs in upsert appliers.
114
135
  * @param {Record<string, ?>} applyHandlers - Raw apply handlers.
@@ -238,8 +259,10 @@ export default class SyncEnvelopeReplayService {
238
259
  /**
239
260
  * Applies one normalized mutation to domain models.
240
261
  *
241
- * Defaults to dispatching through the configured apply-handler registry;
242
- * mutations without a registered handler fail loudly.
262
+ * Dispatches through the configured apply-handler registry first (compat
263
+ * precedence); mutations without a matching handler fall through to
264
+ * resource routing when a configuration or resourceTypeOverrides are
265
+ * configured, and otherwise fail loudly.
243
266
  * @param {{actor: ?, context: Record<string, ?>, existingSync: ?, mutation: import("./sync-envelope-replay-service.js").SyncReplayMutation}} args - Actor, batch context, existing sync row, and mutation.
244
267
  * @returns {Promise<?>} Project-specific apply result.
245
268
  */
@@ -249,6 +272,129 @@ export default class SyncEnvelopeReplayService {
249
272
  existingSync: unknown;
250
273
  mutation: import("./sync-envelope-replay-service.js").SyncReplayMutation;
251
274
  }): Promise<unknown>;
275
+ /**
276
+ * Returns whether resource routing is configured on this service.
277
+ * @returns {boolean} Whether mutations route to frontend-model resources.
278
+ */
279
+ routingConfigured(): boolean;
280
+ /**
281
+ * Resolves the routed resource registration for a resource type, memoized
282
+ * per replay service. Overrides win over the configuration registry; string
283
+ * overrides are aliases resolved through the registry.
284
+ * @param {string} resourceType - Mutation resource type.
285
+ * @returns {SyncReplayResourceRegistration | null} Resolved registration or null when unroutable.
286
+ */
287
+ replayResourceRegistration(resourceType: string): SyncReplayResourceRegistration | null;
288
+ /**
289
+ * Uncached routed-resource resolution behind {@link SyncEnvelopeReplayService#replayResourceRegistration}.
290
+ * @param {string} resourceType - Mutation resource type.
291
+ * @returns {SyncReplayResourceRegistration | null} Resolved registration or null when unroutable.
292
+ */
293
+ resolveReplayResourceRegistration(resourceType: string): SyncReplayResourceRegistration | null;
294
+ /**
295
+ * Builds the routed resource instance handling one mutation.
296
+ * @param {object} args - Options.
297
+ * @param {import("./sync-envelope-replay-service.js").SyncReplayMutation} args.mutation - Normalized replay mutation.
298
+ * @param {SyncReplayResourceRegistration} args.registration - Resolved resource registration.
299
+ * @returns {import("../frontend-model-resource/base-resource.js").default} Routed resource instance.
300
+ */
301
+ buildReplayResource({ mutation, registration }: {
302
+ mutation: import("./sync-envelope-replay-service.js").SyncReplayMutation;
303
+ registration: SyncReplayResourceRegistration;
304
+ }): import("../frontend-model-resource/base-resource.js").default;
305
+ /**
306
+ * Applies one mutation through its routed frontend-model resource:
307
+ * authorization, ability-scoped record lookup, schema normalization and
308
+ * assign/save for updates, save-then-check membership creates, destroys for
309
+ * deletes, and the resource's afterSyncApply tail. Client-safe failures
310
+ * throw safe errors that fail the single sync.
311
+ * @param {{actor: ?, context: Record<string, ?>, existingSync: ?, mutation: import("./sync-envelope-replay-service.js").SyncReplayMutation}} args - Actor, batch context, existing sync row, and mutation.
312
+ * @returns {Promise<Record<string, ?>>} Apply result with record, created/deleted flags, and afterSyncApply extras.
313
+ */
314
+ applyRoutedReplayMutation({ context, existingSync, mutation }: {
315
+ actor: unknown;
316
+ context: Record<string, unknown>;
317
+ existingSync: unknown;
318
+ mutation: import("./sync-envelope-replay-service.js").SyncReplayMutation;
319
+ }): Promise<Record<string, unknown>>;
320
+ /**
321
+ * Applies a routed delete mutation.
322
+ * @param {object} args - Options.
323
+ * @param {import("./sync-envelope-replay-service.js").SyncReplayMutation} args.mutation - Normalized replay mutation.
324
+ * @param {import("../frontend-model-resource/base-resource.js").default} args.resource - Routed resource instance.
325
+ * @returns {Promise<Record<string, ?>>} Apply result with the deleted flag.
326
+ */
327
+ applyRoutedReplayDelete({ mutation, resource }: {
328
+ mutation: import("./sync-envelope-replay-service.js").SyncReplayMutation;
329
+ resource: import("../frontend-model-resource/base-resource.js").default;
330
+ }): Promise<Record<string, unknown>>;
331
+ /**
332
+ * Applies a routed upsert mutation: permitted payload attributes are
333
+ * assigned and saved onto the found record (the record layer owns value
334
+ * casting and validation), and missing records are created with the
335
+ * client-generated primary key plus a save-then-check membership check.
336
+ * Model validation failures become client-safe per-sync failures carrying
337
+ * the translated validation message.
338
+ * @param {object} args - Options.
339
+ * @param {Record<string, ?>} args.context - Replay context.
340
+ * @param {import("./sync-envelope-replay-service.js").SyncReplayMutation} args.mutation - Normalized replay mutation.
341
+ * @param {import("../frontend-model-resource/base-resource.js").default} args.resource - Routed resource instance.
342
+ * @returns {Promise<Record<string, ?>>} Apply result with record, created flag, and afterSyncApply extras.
343
+ */
344
+ applyRoutedReplayUpsert({ context, mutation, resource }: {
345
+ context: Record<string, unknown>;
346
+ mutation: import("./sync-envelope-replay-service.js").SyncReplayMutation;
347
+ resource: import("../frontend-model-resource/base-resource.js").default;
348
+ }): Promise<Record<string, unknown>>;
349
+ /**
350
+ * Filters a routed mutation payload down to the resource's declared
351
+ * writable-attribute permit list. Accepted keys per permitted attribute are
352
+ * the camelCase attribute name plus the model's actual column name; unknown
353
+ * keys fail the sync loudly. The primary key is dropped when permitted
354
+ * (snapshot payloads) — the envelope's resourceId is the authoritative
355
+ * record identity, so a payload id can never retarget the row.
356
+ * @param {object} args - Options.
357
+ * @param {import("./sync-envelope-replay-service.js").SyncReplayMutation} args.mutation - Normalized replay mutation.
358
+ * @param {import("../frontend-model-resource/base-resource.js").default} args.resource - Routed resource instance.
359
+ * @returns {Record<string, ?>} Permitted attributes for record.assign.
360
+ */
361
+ permittedRoutedAttributes({ mutation, resource }: {
362
+ mutation: import("./sync-envelope-replay-service.js").SyncReplayMutation;
363
+ resource: import("../frontend-model-resource/base-resource.js").default;
364
+ }): Record<string, unknown>;
365
+ /**
366
+ * Creates the routed record with the client-generated primary key, then
367
+ * verifies create-scope membership when an ability is configured: records
368
+ * outside the ability's create scope are destroyed again and fail the sync
369
+ * with the resource-declared reason. A record that already exists outside
370
+ * the resource's lookup scope fails the sync as an authorization denial
371
+ * instead of colliding on the primary key.
372
+ * @param {object} args - Options.
373
+ * @param {Record<string, ?>} args.attributes - Permitted payload attributes.
374
+ * @param {import("./sync-envelope-replay-service.js").SyncReplayMutation} args.mutation - Normalized replay mutation.
375
+ * @param {import("../frontend-model-resource/base-resource.js").default} args.resource - Routed resource instance.
376
+ * @returns {Promise<import("../database/record/index.js").default>} Created record.
377
+ */
378
+ createRoutedReplayRecord({ attributes, mutation, resource }: {
379
+ attributes: Record<string, unknown>;
380
+ mutation: import("./sync-envelope-replay-service.js").SyncReplayMutation;
381
+ resource: import("../frontend-model-resource/base-resource.js").default;
382
+ }): Promise<import("../database/record/index.js").default>;
383
+ /**
384
+ * Saves a routed record, converting model validation failures into
385
+ * client-safe per-sync errors carrying the translated validation message.
386
+ * @param {import("../database/record/index.js").default} record - Record to save.
387
+ * @returns {Promise<void>} Resolves when saved.
388
+ */
389
+ saveRoutedReplayRecord(record: import("../database/record/index.js").default): Promise<void>;
390
+ /**
391
+ * Maps a routed save/create failure: model validation errors become
392
+ * client-safe errors with their translated messages, everything else
393
+ * propagates unchanged.
394
+ * @param {?} error - Thrown save/create error.
395
+ * @returns {Error} Error to rethrow.
396
+ */
397
+ routedReplaySaveError(error: unknown): Error;
252
398
  /**
253
399
  * Resolves an apply result for stale mutations that should not touch domain models.
254
400
  * @param {{actor: ?, context: Record<string, ?>, existingSync: ?, mutation: import("./sync-envelope-replay-service.js").SyncReplayMutation}} _args - Actor, batch context, existing sync row, and mutation.
@@ -323,6 +469,23 @@ export type SyncReplayBroadcast = {
323
469
  */
324
470
  when?: ((args: Record<string, unknown>) => boolean) | undefined;
325
471
  };
472
+ /**
473
+ * Resolved routed-resource registration for one replay resource type.
474
+ */
475
+ export type SyncReplayResourceRegistration = {
476
+ /**
477
+ * - Effective frontend model name.
478
+ */
479
+ modelName: string;
480
+ /**
481
+ * - Routed resource class.
482
+ */
483
+ resourceClass: import("../configuration-types.js").FrontendModelResourceClassType;
484
+ /**
485
+ * - Normalized resource configuration when registry-resolved.
486
+ */
487
+ resourceConfiguration: import("../configuration-types.js").NormalizedFrontendModelResourceConfiguration | null;
488
+ };
326
489
  export type SyncReplayMutation = {
327
490
  /**
328
491
  * - Client-side mutation timestamp.
@@ -1 +1 @@
1
- {"version":3,"file":"sync-envelope-replay-service.d.ts","sourceRoot":"","sources":["../../../src/sync/sync-envelope-replay-service.js"],"names":[],"mappings":"AAIA;;;;;;;GAOG;AAEH;;;;;;;;GAQG;AACH;IACE;;;;;;;;;;;;;;;;;;;;;OAqBG;IACH,mBAZG;QAAqG,MAAM;oBAA1F,CAAC,GAAG,IAAI,EAAE,KAAK,CAAC,OAAO,CAAC,KAAK,IAAI;mBAAS,CAAC,GAAG,IAAI,EAAE,KAAK,CAAC,OAAO,CAAC,KAAK,IAAI;;QAC3E,SAAS,GAAlB,OAAC;QACa,qBAAqB;QAC1B,wBAAwB,GAAjC,OAAC;QACa,yBAAyB;QACzB,wBAAwB;QACsF,aAAa;;;;sBAFnE,CAAC;;;;;;;;;;;;;;;;;;;;;;;oBAEhD,MAAM,CAAC,MAAM,EAAE,OAAC,CAAC,KAAK,OAAO,CAAC,OAAC,CAAC;QACD,sBAAsB,WAArE,MAAM,CAAC,MAAM,EAAE,OAAC,C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AAC;;;;qBAC9C,CAAC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAC,CAAC,KAAK,MAAM,CAAC,MAAM,EAAE,OAAC,CAAC;;;;UAC9C,CAAC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAC,CAAC,KAAK,OAAC;;;;mBACvB,MAAM,CAAC,MAAM,EAAE,OAAC,CAAC,KAAK,OAAO;;;;;;qBAsapC,IAAI;;;;UACJ,MAAM,CAAC,MAAM,EAAE,OAAC,CAAC;;;;QACjB,OAAC;;;;gBACD,MAAM;;;;kBACN,MAAM;;;;oBACN,MAAM;;;;cACN,MAAM"}
1
+ {"version":3,"file":"sync-envelope-replay-service.d.ts","sourceRoot":"","sources":["../../../src/sync/sync-envelope-replay-service.js"],"names":[],"mappings":"AAOA;;;;;;;GAOG;AAEH;;;;;;;;GAQG;AACH;IACE;;;;;;;;;;;;;;;;;;;;;;;;;;OA0BG;IACH,mBAjBG;QAAqG,MAAM;oBAA1F,CAAC,GAAG,IAAI,EAAE,KAAK,CAAC,OAAO,CAAC,KAAK,IAAI;mBAAS,CAAC,GAAG,IAAI,EAAE,KAAK,CAAC,OAAO,CAAC,KAAK,IAAI;;QAC3E,SAAS,GAAlB,OAAC;QACa,qBAAqB;QAC1B,wBAAwB,GAAjC,OAAC;QACa,yBAAyB;QACzB,wBAAwB;QACsF,aAAa;;;;sBAD3D,CAAC;;;;;;;;;;;;;;;;;;;;;;;oBACxD,MAAM,CAAC,MAAM,EAAE,OAAC,CAAC,KAAK,OAAO,CAAC,OAAC,CAAC;QACD,sBAAsB,WAArE,MAAM,CAAC,MAAM,EAAE,OAAC,CAAC,KAAK,MAAM,CAAC,MAAM,EAAE,OAAC,CAAC;QACI,qBAAqB,WAAhE;YAAC,QAAQ,EAAE,OAAC,CAAC;YAAC,WAAW,EAAE,OAAC,CAAA;SAAC,KAAK,OAAC;QACiD,WAAW,gBAA1F;YAAC,OAAO,EAAE,MAAM,CAAC;YAAC,MAAM,EAAE,M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