@cratis/chronicle 6.31.4 → 6.32.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/dist/testing/ConstraintScope.d.ts +9 -0
- package/dist/testing/ConstraintScope.d.ts.map +1 -0
- package/dist/testing/ConstraintScope.js +36 -0
- package/dist/testing/ConstraintScope.js.map +1 -0
- package/dist/testing/EventScenario.d.ts.map +1 -1
- package/dist/testing/EventScenario.js +10 -0
- package/dist/testing/EventScenario.js.map +1 -1
- package/dist/testing/InProcessConstraints.d.ts +1 -1
- package/dist/testing/InProcessConstraints.d.ts.map +1 -1
- package/dist/testing/InProcessConstraints.js +23 -13
- package/dist/testing/InProcessConstraints.js.map +1 -1
- package/dist/testing/InProcessEventSequence.d.ts +1 -0
- package/dist/testing/InProcessEventSequence.d.ts.map +1 -1
- package/dist/testing/InProcessEventSequence.js +23 -8
- package/dist/testing/InProcessEventSequence.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +2 -2
- package/testing/ConstraintScope.ts +32 -0
- package/testing/EventScenario.batches.spec.ts +2 -5
- package/testing/EventScenario.constraints.spec.ts +1 -4
- package/testing/EventScenario.fixtures.spec.ts +1 -1
- package/testing/EventScenario.ts +12 -0
- package/testing/InProcessConstraints.ts +29 -16
- package/testing/InProcessEventSequence.ts +24 -8
- package/testing/for_EventScenario/when_appending_scoped_constraints/scope_scenario_behaviors.fixture.ts +139 -0
- package/testing/for_EventScenario/when_appending_scoped_constraints/with_legacy_decorators.legacy.spec.ts +57 -0
- package/testing/for_EventScenario/when_appending_scoped_constraints/with_standard_decorators.standard.spec.ts +56 -0
- package/testing/for_EventScenario/when_appending_scoped_constraints/with_unproven_cycles.spec.ts +48 -0
- package/testing/for_EventScenario/when_appending_scoped_constraints/with_unproven_operations.spec.ts +119 -0
- package/testing/for_ReactorScenario/when_enforcing_scoped_constraints/with_default_input_routes.spec.ts +70 -0
- package/testing/for_ReactorScenario/when_enforcing_scoped_constraints/with_routed_service_appends.spec.ts +65 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":"7.0.2","root":["../ChronicleClient.ts","../ChronicleOptions.ts","../EventStore.ts","../EventStoreName.ts","../EventStoreNamespaceName.ts","../IChronicleClient.ts","../IEventStore.ts","../Metrics.ts","../Tracing.ts","../index.ts","../artifacts/ActivatedArtifact.ts","../artifacts/ArtifactActivationContext.ts","../artifacts/ArtifactCompletionFailed.ts","../artifacts/ArtifactDelivery.ts","../artifacts/ArtifactInvocationContext.ts","../artifacts/ArtifactKind.ts","../artifacts/ClientArtifactsActivator.ts","../artifacts/DefaultClientArtifactsProvider.ts","../artifacts/IClientArtifactsProvider.ts","../artifacts/index.ts","../artifacts/validateArtifactSchemas.ts","../artifacts/withActivatedArtifact.ts","../auditing/Causation.ts","../auditing/CausationManager.ts","../auditing/CausationType.ts","../auditing/ICausationManager.ts","../auditing/index.ts","../compliance/ComplianceContracts.ts","../compliance/ComplianceMetadata.ts","../compliance/ComplianceMetadataResolver.ts","../compliance/ComplianceMetadataType.ts","../compliance/IPIIManager.ts","../compliance/PIIManager.ts","../compliance/PIINotSupportedOnEventSourceId.ts","../compliance/index.ts","../compliance/pii.ts","../compliance/subject.ts","../confidentiality/EncryptedNotSupportedOnEventSourceId.ts","../confidentiality/EncryptionScope.ts","../confidentiality/PIIAndEncryptedCombinedNotSupported.ts","../confidentiality/SecurityMetadata.ts","../confidentiality/SecurityMetadataResolver.ts","../confidentiality/SecurityMetadataType.ts","../confidentiality/encrypted.ts","../confidentiality/index.ts","../connection/ChronicleConnection.ts","../connection/ChronicleConnectionString.ts","../connection/ChronicleServerAddressResolver.ts","../connection/ChronicleServices.ts","../connection/ChronicleSrvResolutionError.ts","../connection/ChronicleSrvResolver.ts","../connection/CompatibilityPreflight.ts","../connection/ConnectionLifecycle.ts","../connection/DateTimeOffset.ts","../connection/Guid.ts","../connection/ILoadBalancerStrategy.ts","../connection/IncompatibleChronicleServer.ts","../connection/KernelKeepAlive.ts","../connection/LeastConnectionsLoadBalancerStrategy.ts","../connection/LoadBalancerMode.ts","../connection/LoadBalancerStrategyFactory.ts","../connection/RandomLoadBalancerStrategy.ts","../connection/RejectedChronicleCredentials.ts","../connection/RoundRobinLoadBalancerStrategy.ts","../connection/TokenProvider.ts","../connection/callResults.ts","../connection/clientVersion.ts","../connection/encodeExplicitFalse.ts","../connection/fetchOAuthAccessToken.ts","../connection/formatServerAddress.ts","../connection/index.ts","../connection/for_encodeExplicitFalse/wireFields.ts","../correlation/CorrelationId.ts","../correlation/CorrelationIdManager.ts","../correlation/ICorrelationIdAccessor.ts","../correlation/ICorrelationIdSetter.ts","../correlation/index.ts","../eventSequences/AppendError.ts","../eventSequences/AppendOperationsBroadcaster.ts","../eventSequences/AppendOptions.ts","../eventSequences/AppendResult.ts","../eventSequences/AppendedEventWithResult.ts","../eventSequences/CompleteStreamError.ts","../eventSequences/CompleteStreamResult.ts","../eventSequences/ConcurrencyScope.ts","../eventSequences/ConcurrencyViolation.ts","../eventSequences/ConstraintViolation.ts","../eventSequences/EventForEventSourceId.ts","../eventSequences/EventLog.ts","../eventSequences/EventSequence.ts","../eventSequences/EventSequenceId.ts","../eventSequences/EventSequenceNumber.ts","../eventSequences/IEventLog.ts","../eventSequences/IEventSequence.ts","../eventSequences/ITransactionalEventSequence.ts","../eventSequences/TransactionalEventSequence.ts","../eventSequences/WaitForCompletionOptions.ts","../eventSequences/WaitForCompletionResult.ts","../eventSequences/createAppendNotification.ts","../eventSequences/createAppendResult.ts","../eventSequences/index.ts","../eventSequences/prepareBatchAppend.ts","../eventSequences/prepareSingleAppend.ts","../eventStoreSubscriptions/EventStoreSubscriptionBuilder.ts","../eventStoreSubscriptions/EventStoreSubscriptionDefinition.ts","../eventStoreSubscriptions/EventStoreSubscriptionId.ts","../eventStoreSubscriptions/EventStoreSubscriptions.ts","../eventStoreSubscriptions/IEventStoreSubscriptionBuilder.ts","../eventStoreSubscriptions/IEventStoreSubscriptions.ts","../eventStoreSubscriptions/contracts.ts","../eventStoreSubscriptions/index.ts","../events/AppendedEvent.ts","../events/CausationEntry.ts","../events/EventContext.ts","../events/EventType.ts","../events/EventTypeGeneration.ts","../events/EventTypeId.ts","../events/EventTypes.ts","../events/IEventTypes.ts","../events/Tag.ts","../events/WireEventContext.ts","../events/eventTypeDecorator.ts","../events/filterEventsByTagDecorator.ts","../events/index.ts","../events/isRegisteredEvent.ts","../events/mergeTags.ts","../events/tagDecorator.ts","../events/toClientEventContext.ts","../events/constraints/ConstraintBuilder.ts","../events/constraints/ConstraintId.ts","../events/constraints/Constraints.ts","../events/constraints/IConstraint.ts","../events/constraints/IConstraintBuilder.ts","../events/constraints/IConstraints.ts","../events/constraints/IUniqueConstraintBuilder.ts","../events/constraints/UniqueConstraintBuilder.ts","../events/constraints/constraint.ts","../events/constraints/index.ts","../events/constraints/removeConstraint.ts","../events/constraints/unique.ts","../events/migrations/EventMigrationBuilder.ts","../events/migrations/EventMigrationPropertyBuilder.ts","../events/migrations/EventTypeMigrators.ts","../events/migrations/IEventMigrationBuilder.ts","../events/migrations/IEventMigrationPropertyBuilder.ts","../events/migrations/IEventTypeMigration.ts","../events/migrations/IEventTypeMigrators.ts","../events/migrations/InvalidMigrationGenerationGap.ts","../events/migrations/eventTypeMigration.ts","../events/migrations/index.ts","../externalServices/ExternalServiceBuilder.ts","../externalServices/ExternalServices.ts","../externalServices/IExternalServiceBuilder.ts","../externalServices/IExternalServices.ts","../externalServices/index.ts","../identities/IIdentityManager.ts","../identities/IdentityManager.ts","../identities/index.ts","../identity/IIdentityProvider.ts","../identity/Identity.ts","../identity/IdentityProvider.ts","../identity/index.ts","../jobs/IJobs.ts","../jobs/JobId.ts","../jobs/Jobs.ts","../jobs/index.ts","../observation/FailedPartition.ts","../observation/FailedPartitionAttempt.ts","../observation/FailedPartitions.ts","../observation/ICanBeNotifiedWhenPartitionReplayed.ts","../observation/ICanBeNotifiedWhenReplay.ts","../observation/IFailedPartitions.ts","../observation/IObservers.ts","../observation/ObserverId.ts","../observation/ObserverInformation.ts","../observation/ObserverRemovalOutcome.ts","../observation/ObserverRemovalResult.ts","../observation/ObserverRunningState.ts","../observation/ObserverType.ts","../observation/Observers.ts","../observation/index.ts","../observation/notifyReplayLifecycle.ts","../observation/toClientFailedPartition.ts","../observation/toObserverInformation.ts","../observation/toObserverRemovalResult.ts","../observation/toObserverRunningState.ts","../projections/CompiledProjectionDefinitions.ts","../projections/GlobalHandlerPropertyNotOnVariant.ts","../projections/IProjections.ts","../projections/InvalidEventContextPropertyError.ts","../projections/ProjectionCapabilityProvenance.ts","../projections/ProjectionDefinitionCompiler.ts","../projections/ProjectionEventSchema.ts","../projections/ProjectionId.ts","../projections/ProjectionQueryResult.ts","../projections/ProjectionState.ts","../projections/Projections.ts","../projections/ResolvedModelBoundMetadata.ts","../projections/UnableToQueryProjection.ts","../projections/VariantMustDeclareEntersOnEvent.ts","../projections/VariantReclassifier.ts","../projections/canonicalStringify.ts","../projections/captureProjectionProvenance.ts","../projections/constantValueExpression.ts","../projections/eventContextPropertyExpression.ts","../projections/eventContractPath.ts","../projections/index.ts","../projections/invalidEventContextPropertyInProjection.ts","../projections/notSetPropertyPath.ts","../projections/declarative/AddBuilder.ts","../projections/declarative/AddChildBuilder.ts","../projections/declarative/AllSetBuilder.ts","../projections/declarative/ChildrenBuilder.ts","../projections/declarative/CompositeKeyBuilder.ts","../projections/declarative/FromBuilder.ts","../projections/declarative/FromEveryBuilder.ts","../projections/declarative/IAddBuilder.ts","../projections/declarative/IAddChildBuilder.ts","../projections/declarative/IAllSetBuilder.ts","../projections/declarative/IChildrenBuilder.ts","../projections/declarative/ICompositeKeyBuilder.ts","../projections/declarative/IFromBuilder.ts","../projections/declarative/IFromEveryBuilder.ts","../projections/declarative/IJoinBuilder.ts","../projections/declarative/INestedBuilder.ts","../projections/declarative/IProjectionBuilder.ts","../projections/declarative/IProjectionBuilderFor.ts","../projections/declarative/IProjectionFor.ts","../projections/declarative/IReadModelPropertiesBuilder.ts","../projections/declarative/IRemovedWithBuilder.ts","../projections/declarative/IRemovedWithJoinBuilder.ts","../projections/declarative/ISetBuilder.ts","../projections/declarative/ISubtractBuilder.ts","../projections/declarative/JoinBuilder.ts","../projections/declarative/NestedBuilder.ts","../projections/declarative/ProjectionBuilderCore.ts","../projections/declarative/ProjectionBuilderFor.ts","../projections/declarative/RemovedWithBuilder.ts","../projections/declarative/RemovedWithJoinBuilder.ts","../projections/declarative/SetBuilder.ts","../projections/declarative/SubtractBuilder.ts","../projections/declarative/index.ts","../projections/declarative/projection.ts","../projections/declarative/projectionBuilderProvenance.ts","../projections/modelBound/FromEventMetadata.ts","../projections/modelBound/FromEventOptions.ts","../projections/modelBound/addFrom.ts","../projections/modelBound/childrenAndNestedBuilder.ts","../projections/modelBound/childrenFrom.ts","../projections/modelBound/clearWith.ts","../projections/modelBound/count.ts","../projections/modelBound/decrement.ts","../projections/modelBound/entersOn.ts","../projections/modelBound/eventSequence.ts","../projections/modelBound/fromAll.ts","../projections/modelBound/fromEvent.ts","../projections/modelBound/fromEvery.ts","../projections/modelBound/globalFor.ts","../projections/modelBound/increment.ts","../projections/modelBound/index.ts","../projections/modelBound/isModelBoundProjection.ts","../projections/modelBound/join.ts","../projections/modelBound/nested.ts","../projections/modelBound/noAutoMap.ts","../projections/modelBound/notRewindable.ts","../projections/modelBound/passive.ts","../projections/modelBound/removedWith.ts","../projections/modelBound/removedWithJoin.ts","../projections/modelBound/setFrom.ts","../projections/modelBound/setFromContext.ts","../projections/modelBound/setValue.ts","../projections/modelBound/subtractFrom.ts","../projections/modelBound/variantOf.ts","../reactors/IReactors.ts","../reactors/ReactorDispatcher.ts","../reactors/ReactorId.ts","../reactors/ReactorResultHandler.ts","../reactors/ReactorServices.ts","../reactors/ReactorSideEffects.ts","../reactors/Reactors.ts","../reactors/index.ts","../reactors/onceOnly.ts","../reactors/reactor.ts","../reactors/replay.ts","../readModels/IMaterializedReadModels.ts","../readModels/IReadModels.ts","../readModels/MaterializedReadModels.ts","../readModels/ReadModelChangeset.ts","../readModels/ReadModelId.ts","../readModels/ReadModelNamingPolicy.ts","../readModels/ReadModelSnapshot.ts","../readModels/ReadModelSubjectResolver.ts","../readModels/ReadModels.ts","../readModels/assertUniqueReadModelIds.ts","../readModels/buildReadModelDefinition.ts","../readModels/deserializeReadModel.ts","../readModels/index.ts","../readModels/indexDecorator.ts","../readModels/readModel.ts","../readModels/rootReadModelTypes.ts","../readModels/for_ReadModelNamingPolicy/given/registered_read_models.ts","../reducers/IReducers.ts","../reducers/ReducerEventDispatcher.ts","../reducers/ReducerEventHandler.ts","../reducers/ReducerId.ts","../reducers/Reducers.ts","../reducers/index.ts","../reducers/reducer.ts","../schemas/JsonSchema.ts","../schemas/JsonSchemaGenerator.ts","../schemas/createDeferredSchema.ts","../schemas/index.ts","../schemas/jsonSchemaProperty.ts","../seeding/EventSeeding.ts","../seeding/ICanSeedEvents.ts","../seeding/IEventSeeding.ts","../seeding/IEventSeedingBuilder.ts","../seeding/IEventSeedingScopeBuilder.ts","../seeding/index.ts","../seeding/seeder.ts","../sinks/WellKnownSinks.ts","../sinks/index.ts","../testing/EventScenario.ts","../testing/EventScenarioGiven.ts","../testing/EventScenarioGivenBuilder.ts","../testing/EventScenarioOptions.ts","../testing/EventScenarioSeed.ts","../testing/EventScenarioWhen.ts","../testing/EventScenarioWhenBuilder.ts","../testing/IReadModelProcessor.ts","../testing/InProcessConstraints.ts","../testing/InProcessEventSequence.ts","../testing/ReactorDeliveryResult.ts","../testing/ReactorScenario.ts","../testing/ReactorScenarioOptions.ts","../testing/ReadModelScenario.ts","../testing/ReadModelScenarioGiven.ts","../testing/ReadModelScenarioGivenBuilder.ts","../testing/ReadModelState.ts","../testing/RecordedReactorSideEffect.ts","../testing/ReducerReadModelProcessor.ts","../testing/ScenarioEvent.ts","../testing/UnsupportedEventSequenceOperation.ts","../testing/UnsupportedReactorOperation.ts","../testing/index.ts","../testing/projections/ProjectionCapabilities.ts","../testing/projections/ProjectionChildrenCapabilities.ts","../testing/projections/ProjectionExpressionEvaluator.ts","../testing/projections/ProjectionReadModelProcessor.ts","../testing/projections/ProjectionValueConverter.ts","../testing/projections/UnsupportedProjectionOperation.ts","../testing/projections/for_ProjectionCapabilities/given/Changed.ts","../testing/projections/for_ProjectionCapabilities/given/Model.ts","../testing/projections/for_ProjectionCapabilities/given/Removed.ts","../testing/projections/for_ProjectionCapabilities/given/compile.ts","../transactions/IUnitOfWork.ts","../transactions/IUnitOfWorkManager.ts","../transactions/NoUnitOfWorkHasBeenStarted.ts","../transactions/UnitOfWork.ts","../transactions/UnitOfWorkManager.ts","../transactions/index.ts","../types/DecoratorType.ts","../types/TypeDiscoverer.ts","../types/TypeIntrospector.ts","../types/conceptValueType.ts","../types/index.ts","../types/modelBoundProperty.ts","../types/modelBoundPropertyMetadata.ts","../types/propertyDecoratorMetadata.ts","../types/standardDecoratorMetadata.ts","../webhooks/IWebhook.ts","../webhooks/IWebhookDefinitionBuilder.ts","../webhooks/IWebhooks.ts","../webhooks/WebhookDefinitionBuilder.ts","../webhooks/WebhookId.ts","../webhooks/WebhookTargetUrl.ts","../webhooks/Webhooks.ts","../webhooks/index.ts","../webhooks/webhook.ts"],"packageJsons":["../package.json","../../node_modules/@bufbuild/protobuf/dist/esm/package.json","../../node_modules/@bufbuild/protobuf/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/dist/esm/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/package.json","../../node_modules/@cratis/chronicle.contracts/package.json","../../node_modules/@cratis/fundamentals/dist/esm/package.json","../../node_modules/@cratis/fundamentals/package.json","../../node_modules/@grpc/grpc-js/package.json","../../node_modules/@grpc/proto-loader/package.json","../../node_modules/@js-sdsl/ordered-map/package.json","../../node_modules/@opentelemetry/api/package.json","../../node_modules/@types/chai/package.json","../../node_modules/@types/deep-eql/package.json","../../node_modules/@types/node/package.json","../../node_modules/@vitest/mocker/package.json","../../node_modules/assertion-error/package.json","../../node_modules/chai/package.json","../../node_modules/esbuild/package.json","../../node_modules/expect-type/package.json","../../node_modules/glob/dist/esm/package.json","../../node_modules/glob/package.json","../../node_modules/long/package.json","../../node_modules/long/umd/package.json","../../node_modules/lru-cache/dist/esm/package.json","../../node_modules/lru-cache/package.json","../../node_modules/minimatch/dist/esm/package.json","../../node_modules/minimatch/package.json","../../node_modules/minipass/dist/esm/package.json","../../node_modules/minipass/package.json","../../node_modules/nice-grpc-common/package.json","../../node_modules/nice-grpc/package.json","../../node_modules/path-scurry/dist/esm/package.json","../../node_modules/path-scurry/package.json","../../node_modules/protobufjs/package.json","../../node_modules/reflect-metadata/package.json","../../node_modules/tinybench/package.json","../../node_modules/ts-error/package.json","../../node_modules/tsx/package.json","../../node_modules/undici-types/package.json","../../node_modules/undici/package.json","../../node_modules/vite/package.json","../../node_modules/vitest/package.json","../../node_modules/yaml/package.json"],"missingPackageJsons":["../../node_modules/@bufbuild/protobuf/dist/esm/codegenv1/package.json","../../node_modules/@bufbuild/protobuf/dist/esm/codegenv2/package.json","../../node_modules/@bufbuild/protobuf/dist/esm/reflect/package.json","../../node_modules/@bufbuild/protobuf/dist/esm/wire/package.json","../../node_modules/@bufbuild/protobuf/dist/esm/wkt/google/package.json","../../node_modules/@bufbuild/protobuf/dist/esm/wkt/google/protobuf/package.json","../../node_modules/@bufbuild/protobuf/dist/esm/wkt/package.json","../../node_modules/@bufbuild/protobuf/wire/package.json","../../node_modules/@cratis/chronicle.contracts/dist/esm/generated/google/package.json","../../node_modules/@cratis/chronicle.contracts/dist/esm/generated/google/protobuf/package.json","../../node_modules/@cratis/chronicle.contracts/dist/esm/generated/package.json","../../node_modules/@cratis/chronicle.contracts/dist/esm/generated/protobuf-net/package.json","../../node_modules/@cratis/chronicle.contracts/dist/esm/package.json","../../node_modules/@cratis/chronicle.contracts/dist/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/dist/esm/reflect/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/dist/esm/wire/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/dist/esm/wkt/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/wire/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/nice-grpc-common/package.json","../../node_modules/@cratis/fundamentals/dist/esm/geospatial/package.json","../../node_modules/@cratis/fundamentals/dist/esm/json/package.json","../../node_modules/@edge-runtime/vm/package.json","../../node_modules/@grpc/grpc-js/build/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/google/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/grpc/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/xds/data/orca/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/xds/data/orca/v3/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/xds/data/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/xds/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/xds/service/orca/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/xds/service/orca/v3/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/xds/service/package.json","../../node_modules/@grpc/grpc-js/build/src/package.json","../../node_modules/@grpc/proto-loader/build/package.json","../../node_modules/@grpc/proto-loader/build/src/package.json","../../node_modules/@js-sdsl/ordered-map/dist/esm/package.json","../../node_modules/@js-sdsl/ordered-map/dist/package.json","../../node_modules/@opentelemetry/api/build/package.json","../../node_modules/@opentelemetry/api/build/src/api/package.json","../../node_modules/@opentelemetry/api/build/src/baggage/internal/package.json","../../node_modules/@opentelemetry/api/build/src/baggage/package.json","../../node_modules/@opentelemetry/api/build/src/common/package.json","../../node_modules/@opentelemetry/api/build/src/context/package.json","../../node_modules/@opentelemetry/api/build/src/diag/package.json","../../node_modules/@opentelemetry/api/build/src/metrics/package.json","../../node_modules/@opentelemetry/api/build/src/package.json","../../node_modules/@opentelemetry/api/build/src/propagation/package.json","../../node_modules/@opentelemetry/api/build/src/trace/internal/package.json","../../node_modules/@opentelemetry/api/build/src/trace/package.json","../../node_modules/@types/assert/package.json","../../node_modules/@types/assert/strict/package.json","../../node_modules/@types/async_hooks/package.json","../../node_modules/@types/buffer/package.json","../../node_modules/@types/child_process/package.json","../../node_modules/@types/cluster/package.json","../../node_modules/@types/console/package.json","../../node_modules/@types/constants/package.json","../../node_modules/@types/crypto/package.json","../../node_modules/@types/dgram/package.json","../../node_modules/@types/diagnostics_channel/package.json","../../node_modules/@types/dns/package.json","../../node_modules/@types/dns/promises/package.json","../../node_modules/@types/domain/package.json","../../node_modules/@types/events/package.json","../../node_modules/@types/fs/package.json","../../node_modules/@types/fs/promises/package.json","../../node_modules/@types/http/package.json","../../node_modules/@types/http2/package.json","../../node_modules/@types/https/package.json","../../node_modules/@types/inspector/package.json","../../node_modules/@types/inspector/promises/package.json","../../node_modules/@types/module/package.json","../../node_modules/@types/net/package.json","../../node_modules/@types/node/assert/package.json","../../node_modules/@types/node/dns/package.json","../../node_modules/@types/node/fs/package.json","../../node_modules/@types/node/inspector/package.json","../../node_modules/@types/node/path/package.json","../../node_modules/@types/node/readline/package.json","../../node_modules/@types/node/stream/package.json","../../node_modules/@types/node/test/package.json","../../node_modules/@types/node/timers/package.json","../../node_modules/@types/node/util/package.json","../../node_modules/@types/node/web-globals/package.json","../../node_modules/@types/node/zlib/package.json","../../node_modules/@types/os/package.json","../../node_modules/@types/path/package.json","../../node_modules/@types/path/posix/package.json","../../node_modules/@types/path/win32/package.json","../../node_modules/@types/perf_hooks/package.json","../../node_modules/@types/process/package.json","../../node_modules/@types/punycode/package.json","../../node_modules/@types/querystring/package.json","../../node_modules/@types/readline/package.json","../../node_modules/@types/readline/promises/package.json","../../node_modules/@types/repl/package.json","../../node_modules/@types/stream/consumers/package.json","../../node_modules/@types/stream/iter/package.json","../../node_modules/@types/stream/package.json","../../node_modules/@types/stream/promises/package.json","../../node_modules/@types/stream/web/package.json","../../node_modules/@types/string_decoder/package.json","../../node_modules/@types/timers/package.json","../../node_modules/@types/timers/promises/package.json","../../node_modules/@types/tls/package.json","../../node_modules/@types/trace_events/package.json","../../node_modules/@types/tty/package.json","../../node_modules/@types/url/package.json","../../node_modules/@types/util/package.json","../../node_modules/@types/util/types/package.json","../../node_modules/@types/v8/package.json","../../node_modules/@types/vm/package.json","../../node_modules/@types/wasi/package.json","../../node_modules/@types/worker_threads/package.json","../../node_modules/@types/zlib/package.json","../../node_modules/@vitejs/devtools/package.json","../../node_modules/@vitest/browser-playwright/package.json","../../node_modules/@vitest/browser-preview/package.json","../../node_modules/@vitest/browser-webdriverio/package.json","../../node_modules/@vitest/coverage-istanbul/package.json","../../node_modules/@vitest/coverage-v8/package.json","../../node_modules/@vitest/mocker/dist/package.json","../../node_modules/@vitest/ui/package.json","../../node_modules/assert/package.json","../../node_modules/assert/strict/package.json","../../node_modules/async_hooks/package.json","../../node_modules/buffer/package.json","../../node_modules/child_process/package.json","../../node_modules/cluster/package.json","../../node_modules/console/package.json","../../node_modules/constants/package.json","../../node_modules/crypto/package.json","../../node_modules/deep-eql/package.json","../../node_modules/dgram/package.json","../../node_modules/diagnostics_channel/package.json","../../node_modules/dns/package.json","../../node_modules/dns/promises/package.json","../../node_modules/domain/package.json","../../node_modules/events/package.json","../../node_modules/expect-type/dist/package.json","../../node_modules/fs/package.json","../../node_modules/fs/promises/package.json","../../node_modules/happy-dom/package.json","../../node_modules/http/package.json","../../node_modules/http2/package.json","../../node_modules/https/package.json","../../node_modules/inspector/package.json","../../node_modules/inspector/promises/package.json","../../node_modules/jiti/package.json","../../node_modules/jsdom/package.json","../../node_modules/less/package.json","../../node_modules/module/package.json","../../node_modules/msw/package.json","../../node_modules/net/package.json","../../node_modules/nice-grpc-common/lib/client/package.json","../../node_modules/nice-grpc-common/lib/package.json","../../node_modules/nice-grpc-common/lib/server/package.json","../../node_modules/nice-grpc/lib/client/package.json","../../node_modules/nice-grpc/lib/package.json","../../node_modules/nice-grpc/lib/server/package.json","../../node_modules/nice-grpc/lib/service-definitions/package.json","../../node_modules/nice-grpc/lib/utils/package.json","../../node_modules/os/package.json","../../node_modules/path/package.json","../../node_modules/path/posix/package.json","../../node_modules/path/win32/package.json","../../node_modules/perf_hooks/package.json","../../node_modules/process/package.json","../../node_modules/protobufjs/ext/descriptor/package.json","../../node_modules/protobufjs/ext/package.json","../../node_modules/protobufjs/node_modules/@types/long/package.json","../../node_modules/protobufjs/node_modules/long/package.json","../../node_modules/punycode/package.json","../../node_modules/querystring/package.json","../../node_modules/readline/package.json","../../node_modules/readline/promises/package.json","../../node_modules/repl/package.json","../../node_modules/sass-embedded/package.json","../../node_modules/sass/package.json","../../node_modules/stream/consumers/package.json","../../node_modules/stream/iter/package.json","../../node_modules/stream/package.json","../../node_modules/stream/promises/package.json","../../node_modules/stream/web/package.json","../../node_modules/string_decoder/package.json","../../node_modules/stylus/package.json","../../node_modules/sugarss/package.json","../../node_modules/terser/package.json","../../node_modules/timers/package.json","../../node_modules/timers/promises/package.json","../../node_modules/tinybench/dist/package.json","../../node_modules/tls/package.json","../../node_modules/trace_events/package.json","../../node_modules/ts-error/lib/package.json","../../node_modules/tty/package.json","../../node_modules/undici/types/package.json","../../node_modules/url/package.json","../../node_modules/util/package.json","../../node_modules/util/types/package.json","../../node_modules/v8/package.json","../../node_modules/vite/dist/node/chunks/package.json","../../node_modules/vite/dist/node/package.json","../../node_modules/vite/dist/package.json","../../node_modules/vite/module-runner/package.json","../../node_modules/vite/types/package.json","../../node_modules/vitest/dist/chunks/package.json","../../node_modules/vitest/dist/package.json","../../node_modules/vm/package.json","../../node_modules/wasi/package.json","../../node_modules/worker_threads/package.json","../../node_modules/zlib/package.json"]}
|
|
1
|
+
{"version":"7.0.2","root":["../ChronicleClient.ts","../ChronicleOptions.ts","../EventStore.ts","../EventStoreName.ts","../EventStoreNamespaceName.ts","../IChronicleClient.ts","../IEventStore.ts","../Metrics.ts","../Tracing.ts","../index.ts","../artifacts/ActivatedArtifact.ts","../artifacts/ArtifactActivationContext.ts","../artifacts/ArtifactCompletionFailed.ts","../artifacts/ArtifactDelivery.ts","../artifacts/ArtifactInvocationContext.ts","../artifacts/ArtifactKind.ts","../artifacts/ClientArtifactsActivator.ts","../artifacts/DefaultClientArtifactsProvider.ts","../artifacts/IClientArtifactsProvider.ts","../artifacts/index.ts","../artifacts/validateArtifactSchemas.ts","../artifacts/withActivatedArtifact.ts","../auditing/Causation.ts","../auditing/CausationManager.ts","../auditing/CausationType.ts","../auditing/ICausationManager.ts","../auditing/index.ts","../compliance/ComplianceContracts.ts","../compliance/ComplianceMetadata.ts","../compliance/ComplianceMetadataResolver.ts","../compliance/ComplianceMetadataType.ts","../compliance/IPIIManager.ts","../compliance/PIIManager.ts","../compliance/PIINotSupportedOnEventSourceId.ts","../compliance/index.ts","../compliance/pii.ts","../compliance/subject.ts","../confidentiality/EncryptedNotSupportedOnEventSourceId.ts","../confidentiality/EncryptionScope.ts","../confidentiality/PIIAndEncryptedCombinedNotSupported.ts","../confidentiality/SecurityMetadata.ts","../confidentiality/SecurityMetadataResolver.ts","../confidentiality/SecurityMetadataType.ts","../confidentiality/encrypted.ts","../confidentiality/index.ts","../connection/ChronicleConnection.ts","../connection/ChronicleConnectionString.ts","../connection/ChronicleServerAddressResolver.ts","../connection/ChronicleServices.ts","../connection/ChronicleSrvResolutionError.ts","../connection/ChronicleSrvResolver.ts","../connection/CompatibilityPreflight.ts","../connection/ConnectionLifecycle.ts","../connection/DateTimeOffset.ts","../connection/Guid.ts","../connection/ILoadBalancerStrategy.ts","../connection/IncompatibleChronicleServer.ts","../connection/KernelKeepAlive.ts","../connection/LeastConnectionsLoadBalancerStrategy.ts","../connection/LoadBalancerMode.ts","../connection/LoadBalancerStrategyFactory.ts","../connection/RandomLoadBalancerStrategy.ts","../connection/RejectedChronicleCredentials.ts","../connection/RoundRobinLoadBalancerStrategy.ts","../connection/TokenProvider.ts","../connection/callResults.ts","../connection/clientVersion.ts","../connection/encodeExplicitFalse.ts","../connection/fetchOAuthAccessToken.ts","../connection/formatServerAddress.ts","../connection/index.ts","../connection/for_encodeExplicitFalse/wireFields.ts","../correlation/CorrelationId.ts","../correlation/CorrelationIdManager.ts","../correlation/ICorrelationIdAccessor.ts","../correlation/ICorrelationIdSetter.ts","../correlation/index.ts","../eventSequences/AppendError.ts","../eventSequences/AppendOperationsBroadcaster.ts","../eventSequences/AppendOptions.ts","../eventSequences/AppendResult.ts","../eventSequences/AppendedEventWithResult.ts","../eventSequences/CompleteStreamError.ts","../eventSequences/CompleteStreamResult.ts","../eventSequences/ConcurrencyScope.ts","../eventSequences/ConcurrencyViolation.ts","../eventSequences/ConstraintViolation.ts","../eventSequences/EventForEventSourceId.ts","../eventSequences/EventLog.ts","../eventSequences/EventSequence.ts","../eventSequences/EventSequenceId.ts","../eventSequences/EventSequenceNumber.ts","../eventSequences/IEventLog.ts","../eventSequences/IEventSequence.ts","../eventSequences/ITransactionalEventSequence.ts","../eventSequences/TransactionalEventSequence.ts","../eventSequences/WaitForCompletionOptions.ts","../eventSequences/WaitForCompletionResult.ts","../eventSequences/createAppendNotification.ts","../eventSequences/createAppendResult.ts","../eventSequences/index.ts","../eventSequences/prepareBatchAppend.ts","../eventSequences/prepareSingleAppend.ts","../eventStoreSubscriptions/EventStoreSubscriptionBuilder.ts","../eventStoreSubscriptions/EventStoreSubscriptionDefinition.ts","../eventStoreSubscriptions/EventStoreSubscriptionId.ts","../eventStoreSubscriptions/EventStoreSubscriptions.ts","../eventStoreSubscriptions/IEventStoreSubscriptionBuilder.ts","../eventStoreSubscriptions/IEventStoreSubscriptions.ts","../eventStoreSubscriptions/contracts.ts","../eventStoreSubscriptions/index.ts","../events/AppendedEvent.ts","../events/CausationEntry.ts","../events/EventContext.ts","../events/EventType.ts","../events/EventTypeGeneration.ts","../events/EventTypeId.ts","../events/EventTypes.ts","../events/IEventTypes.ts","../events/Tag.ts","../events/WireEventContext.ts","../events/eventTypeDecorator.ts","../events/filterEventsByTagDecorator.ts","../events/index.ts","../events/isRegisteredEvent.ts","../events/mergeTags.ts","../events/tagDecorator.ts","../events/toClientEventContext.ts","../events/constraints/ConstraintBuilder.ts","../events/constraints/ConstraintId.ts","../events/constraints/Constraints.ts","../events/constraints/IConstraint.ts","../events/constraints/IConstraintBuilder.ts","../events/constraints/IConstraints.ts","../events/constraints/IUniqueConstraintBuilder.ts","../events/constraints/UniqueConstraintBuilder.ts","../events/constraints/constraint.ts","../events/constraints/index.ts","../events/constraints/removeConstraint.ts","../events/constraints/unique.ts","../events/migrations/EventMigrationBuilder.ts","../events/migrations/EventMigrationPropertyBuilder.ts","../events/migrations/EventTypeMigrators.ts","../events/migrations/IEventMigrationBuilder.ts","../events/migrations/IEventMigrationPropertyBuilder.ts","../events/migrations/IEventTypeMigration.ts","../events/migrations/IEventTypeMigrators.ts","../events/migrations/InvalidMigrationGenerationGap.ts","../events/migrations/eventTypeMigration.ts","../events/migrations/index.ts","../externalServices/ExternalServiceBuilder.ts","../externalServices/ExternalServices.ts","../externalServices/IExternalServiceBuilder.ts","../externalServices/IExternalServices.ts","../externalServices/index.ts","../identities/IIdentityManager.ts","../identities/IdentityManager.ts","../identities/index.ts","../identity/IIdentityProvider.ts","../identity/Identity.ts","../identity/IdentityProvider.ts","../identity/index.ts","../jobs/IJobs.ts","../jobs/JobId.ts","../jobs/Jobs.ts","../jobs/index.ts","../observation/FailedPartition.ts","../observation/FailedPartitionAttempt.ts","../observation/FailedPartitions.ts","../observation/ICanBeNotifiedWhenPartitionReplayed.ts","../observation/ICanBeNotifiedWhenReplay.ts","../observation/IFailedPartitions.ts","../observation/IObservers.ts","../observation/ObserverId.ts","../observation/ObserverInformation.ts","../observation/ObserverRemovalOutcome.ts","../observation/ObserverRemovalResult.ts","../observation/ObserverRunningState.ts","../observation/ObserverType.ts","../observation/Observers.ts","../observation/index.ts","../observation/notifyReplayLifecycle.ts","../observation/toClientFailedPartition.ts","../observation/toObserverInformation.ts","../observation/toObserverRemovalResult.ts","../observation/toObserverRunningState.ts","../projections/CompiledProjectionDefinitions.ts","../projections/GlobalHandlerPropertyNotOnVariant.ts","../projections/IProjections.ts","../projections/InvalidEventContextPropertyError.ts","../projections/ProjectionCapabilityProvenance.ts","../projections/ProjectionDefinitionCompiler.ts","../projections/ProjectionEventSchema.ts","../projections/ProjectionId.ts","../projections/ProjectionQueryResult.ts","../projections/ProjectionState.ts","../projections/Projections.ts","../projections/ResolvedModelBoundMetadata.ts","../projections/UnableToQueryProjection.ts","../projections/VariantMustDeclareEntersOnEvent.ts","../projections/VariantReclassifier.ts","../projections/canonicalStringify.ts","../projections/captureProjectionProvenance.ts","../projections/constantValueExpression.ts","../projections/eventContextPropertyExpression.ts","../projections/eventContractPath.ts","../projections/index.ts","../projections/invalidEventContextPropertyInProjection.ts","../projections/notSetPropertyPath.ts","../projections/declarative/AddBuilder.ts","../projections/declarative/AddChildBuilder.ts","../projections/declarative/AllSetBuilder.ts","../projections/declarative/ChildrenBuilder.ts","../projections/declarative/CompositeKeyBuilder.ts","../projections/declarative/FromBuilder.ts","../projections/declarative/FromEveryBuilder.ts","../projections/declarative/IAddBuilder.ts","../projections/declarative/IAddChildBuilder.ts","../projections/declarative/IAllSetBuilder.ts","../projections/declarative/IChildrenBuilder.ts","../projections/declarative/ICompositeKeyBuilder.ts","../projections/declarative/IFromBuilder.ts","../projections/declarative/IFromEveryBuilder.ts","../projections/declarative/IJoinBuilder.ts","../projections/declarative/INestedBuilder.ts","../projections/declarative/IProjectionBuilder.ts","../projections/declarative/IProjectionBuilderFor.ts","../projections/declarative/IProjectionFor.ts","../projections/declarative/IReadModelPropertiesBuilder.ts","../projections/declarative/IRemovedWithBuilder.ts","../projections/declarative/IRemovedWithJoinBuilder.ts","../projections/declarative/ISetBuilder.ts","../projections/declarative/ISubtractBuilder.ts","../projections/declarative/JoinBuilder.ts","../projections/declarative/NestedBuilder.ts","../projections/declarative/ProjectionBuilderCore.ts","../projections/declarative/ProjectionBuilderFor.ts","../projections/declarative/RemovedWithBuilder.ts","../projections/declarative/RemovedWithJoinBuilder.ts","../projections/declarative/SetBuilder.ts","../projections/declarative/SubtractBuilder.ts","../projections/declarative/index.ts","../projections/declarative/projection.ts","../projections/declarative/projectionBuilderProvenance.ts","../projections/modelBound/FromEventMetadata.ts","../projections/modelBound/FromEventOptions.ts","../projections/modelBound/addFrom.ts","../projections/modelBound/childrenAndNestedBuilder.ts","../projections/modelBound/childrenFrom.ts","../projections/modelBound/clearWith.ts","../projections/modelBound/count.ts","../projections/modelBound/decrement.ts","../projections/modelBound/entersOn.ts","../projections/modelBound/eventSequence.ts","../projections/modelBound/fromAll.ts","../projections/modelBound/fromEvent.ts","../projections/modelBound/fromEvery.ts","../projections/modelBound/globalFor.ts","../projections/modelBound/increment.ts","../projections/modelBound/index.ts","../projections/modelBound/isModelBoundProjection.ts","../projections/modelBound/join.ts","../projections/modelBound/nested.ts","../projections/modelBound/noAutoMap.ts","../projections/modelBound/notRewindable.ts","../projections/modelBound/passive.ts","../projections/modelBound/removedWith.ts","../projections/modelBound/removedWithJoin.ts","../projections/modelBound/setFrom.ts","../projections/modelBound/setFromContext.ts","../projections/modelBound/setValue.ts","../projections/modelBound/subtractFrom.ts","../projections/modelBound/variantOf.ts","../reactors/IReactors.ts","../reactors/ReactorDispatcher.ts","../reactors/ReactorId.ts","../reactors/ReactorResultHandler.ts","../reactors/ReactorServices.ts","../reactors/ReactorSideEffects.ts","../reactors/Reactors.ts","../reactors/index.ts","../reactors/onceOnly.ts","../reactors/reactor.ts","../reactors/replay.ts","../readModels/IMaterializedReadModels.ts","../readModels/IReadModels.ts","../readModels/MaterializedReadModels.ts","../readModels/ReadModelChangeset.ts","../readModels/ReadModelId.ts","../readModels/ReadModelNamingPolicy.ts","../readModels/ReadModelSnapshot.ts","../readModels/ReadModelSubjectResolver.ts","../readModels/ReadModels.ts","../readModels/assertUniqueReadModelIds.ts","../readModels/buildReadModelDefinition.ts","../readModels/deserializeReadModel.ts","../readModels/index.ts","../readModels/indexDecorator.ts","../readModels/readModel.ts","../readModels/rootReadModelTypes.ts","../readModels/for_ReadModelNamingPolicy/given/registered_read_models.ts","../reducers/IReducers.ts","../reducers/ReducerEventDispatcher.ts","../reducers/ReducerEventHandler.ts","../reducers/ReducerId.ts","../reducers/Reducers.ts","../reducers/index.ts","../reducers/reducer.ts","../schemas/JsonSchema.ts","../schemas/JsonSchemaGenerator.ts","../schemas/createDeferredSchema.ts","../schemas/index.ts","../schemas/jsonSchemaProperty.ts","../seeding/EventSeeding.ts","../seeding/ICanSeedEvents.ts","../seeding/IEventSeeding.ts","../seeding/IEventSeedingBuilder.ts","../seeding/IEventSeedingScopeBuilder.ts","../seeding/index.ts","../seeding/seeder.ts","../sinks/WellKnownSinks.ts","../sinks/index.ts","../testing/ConstraintScope.ts","../testing/EventScenario.ts","../testing/EventScenarioGiven.ts","../testing/EventScenarioGivenBuilder.ts","../testing/EventScenarioOptions.ts","../testing/EventScenarioSeed.ts","../testing/EventScenarioWhen.ts","../testing/EventScenarioWhenBuilder.ts","../testing/IReadModelProcessor.ts","../testing/InProcessConstraints.ts","../testing/InProcessEventSequence.ts","../testing/ReactorDeliveryResult.ts","../testing/ReactorScenario.ts","../testing/ReactorScenarioOptions.ts","../testing/ReadModelScenario.ts","../testing/ReadModelScenarioGiven.ts","../testing/ReadModelScenarioGivenBuilder.ts","../testing/ReadModelState.ts","../testing/RecordedReactorSideEffect.ts","../testing/ReducerReadModelProcessor.ts","../testing/ScenarioEvent.ts","../testing/UnsupportedEventSequenceOperation.ts","../testing/UnsupportedReactorOperation.ts","../testing/index.ts","../testing/projections/ProjectionCapabilities.ts","../testing/projections/ProjectionChildrenCapabilities.ts","../testing/projections/ProjectionExpressionEvaluator.ts","../testing/projections/ProjectionReadModelProcessor.ts","../testing/projections/ProjectionValueConverter.ts","../testing/projections/UnsupportedProjectionOperation.ts","../testing/projections/for_ProjectionCapabilities/given/Changed.ts","../testing/projections/for_ProjectionCapabilities/given/Model.ts","../testing/projections/for_ProjectionCapabilities/given/Removed.ts","../testing/projections/for_ProjectionCapabilities/given/compile.ts","../transactions/IUnitOfWork.ts","../transactions/IUnitOfWorkManager.ts","../transactions/NoUnitOfWorkHasBeenStarted.ts","../transactions/UnitOfWork.ts","../transactions/UnitOfWorkManager.ts","../transactions/index.ts","../types/DecoratorType.ts","../types/TypeDiscoverer.ts","../types/TypeIntrospector.ts","../types/conceptValueType.ts","../types/index.ts","../types/modelBoundProperty.ts","../types/modelBoundPropertyMetadata.ts","../types/propertyDecoratorMetadata.ts","../types/standardDecoratorMetadata.ts","../webhooks/IWebhook.ts","../webhooks/IWebhookDefinitionBuilder.ts","../webhooks/IWebhooks.ts","../webhooks/WebhookDefinitionBuilder.ts","../webhooks/WebhookId.ts","../webhooks/WebhookTargetUrl.ts","../webhooks/Webhooks.ts","../webhooks/index.ts","../webhooks/webhook.ts"],"packageJsons":["../package.json","../../node_modules/@bufbuild/protobuf/dist/esm/package.json","../../node_modules/@bufbuild/protobuf/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/dist/esm/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/package.json","../../node_modules/@cratis/chronicle.contracts/package.json","../../node_modules/@cratis/fundamentals/dist/esm/package.json","../../node_modules/@cratis/fundamentals/package.json","../../node_modules/@grpc/grpc-js/package.json","../../node_modules/@grpc/proto-loader/package.json","../../node_modules/@js-sdsl/ordered-map/package.json","../../node_modules/@opentelemetry/api/package.json","../../node_modules/@types/chai/package.json","../../node_modules/@types/deep-eql/package.json","../../node_modules/@types/node/package.json","../../node_modules/@vitest/mocker/package.json","../../node_modules/assertion-error/package.json","../../node_modules/chai/package.json","../../node_modules/esbuild/package.json","../../node_modules/expect-type/package.json","../../node_modules/glob/dist/esm/package.json","../../node_modules/glob/package.json","../../node_modules/long/package.json","../../node_modules/long/umd/package.json","../../node_modules/lru-cache/dist/esm/package.json","../../node_modules/lru-cache/package.json","../../node_modules/minimatch/dist/esm/package.json","../../node_modules/minimatch/package.json","../../node_modules/minipass/dist/esm/package.json","../../node_modules/minipass/package.json","../../node_modules/nice-grpc-common/package.json","../../node_modules/nice-grpc/package.json","../../node_modules/path-scurry/dist/esm/package.json","../../node_modules/path-scurry/package.json","../../node_modules/protobufjs/package.json","../../node_modules/reflect-metadata/package.json","../../node_modules/tinybench/package.json","../../node_modules/ts-error/package.json","../../node_modules/tsx/package.json","../../node_modules/undici-types/package.json","../../node_modules/undici/package.json","../../node_modules/vite/package.json","../../node_modules/vitest/package.json","../../node_modules/yaml/package.json"],"missingPackageJsons":["../../node_modules/@bufbuild/protobuf/dist/esm/codegenv1/package.json","../../node_modules/@bufbuild/protobuf/dist/esm/codegenv2/package.json","../../node_modules/@bufbuild/protobuf/dist/esm/reflect/package.json","../../node_modules/@bufbuild/protobuf/dist/esm/wire/package.json","../../node_modules/@bufbuild/protobuf/dist/esm/wkt/google/package.json","../../node_modules/@bufbuild/protobuf/dist/esm/wkt/google/protobuf/package.json","../../node_modules/@bufbuild/protobuf/dist/esm/wkt/package.json","../../node_modules/@bufbuild/protobuf/wire/package.json","../../node_modules/@cratis/chronicle.contracts/dist/esm/generated/google/package.json","../../node_modules/@cratis/chronicle.contracts/dist/esm/generated/google/protobuf/package.json","../../node_modules/@cratis/chronicle.contracts/dist/esm/generated/package.json","../../node_modules/@cratis/chronicle.contracts/dist/esm/generated/protobuf-net/package.json","../../node_modules/@cratis/chronicle.contracts/dist/esm/package.json","../../node_modules/@cratis/chronicle.contracts/dist/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/dist/esm/reflect/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/dist/esm/wire/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/dist/esm/wkt/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/@bufbuild/protobuf/wire/package.json","../../node_modules/@cratis/chronicle.contracts/node_modules/nice-grpc-common/package.json","../../node_modules/@cratis/fundamentals/dist/esm/geospatial/package.json","../../node_modules/@cratis/fundamentals/dist/esm/json/package.json","../../node_modules/@edge-runtime/vm/package.json","../../node_modules/@grpc/grpc-js/build/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/google/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/google/protobuf/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/grpc/channelz/v1/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/grpc/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/xds/data/orca/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/xds/data/orca/v3/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/xds/data/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/xds/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/xds/service/orca/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/xds/service/orca/v3/package.json","../../node_modules/@grpc/grpc-js/build/src/generated/xds/service/package.json","../../node_modules/@grpc/grpc-js/build/src/package.json","../../node_modules/@grpc/proto-loader/build/package.json","../../node_modules/@grpc/proto-loader/build/src/package.json","../../node_modules/@js-sdsl/ordered-map/dist/esm/package.json","../../node_modules/@js-sdsl/ordered-map/dist/package.json","../../node_modules/@opentelemetry/api/build/package.json","../../node_modules/@opentelemetry/api/build/src/api/package.json","../../node_modules/@opentelemetry/api/build/src/baggage/internal/package.json","../../node_modules/@opentelemetry/api/build/src/baggage/package.json","../../node_modules/@opentelemetry/api/build/src/common/package.json","../../node_modules/@opentelemetry/api/build/src/context/package.json","../../node_modules/@opentelemetry/api/build/src/diag/package.json","../../node_modules/@opentelemetry/api/build/src/metrics/package.json","../../node_modules/@opentelemetry/api/build/src/package.json","../../node_modules/@opentelemetry/api/build/src/propagation/package.json","../../node_modules/@opentelemetry/api/build/src/trace/internal/package.json","../../node_modules/@opentelemetry/api/build/src/trace/package.json","../../node_modules/@types/assert/package.json","../../node_modules/@types/assert/strict/package.json","../../node_modules/@types/async_hooks/package.json","../../node_modules/@types/buffer/package.json","../../node_modules/@types/child_process/package.json","../../node_modules/@types/cluster/package.json","../../node_modules/@types/console/package.json","../../node_modules/@types/constants/package.json","../../node_modules/@types/crypto/package.json","../../node_modules/@types/dgram/package.json","../../node_modules/@types/diagnostics_channel/package.json","../../node_modules/@types/dns/package.json","../../node_modules/@types/dns/promises/package.json","../../node_modules/@types/domain/package.json","../../node_modules/@types/events/package.json","../../node_modules/@types/fs/package.json","../../node_modules/@types/fs/promises/package.json","../../node_modules/@types/http/package.json","../../node_modules/@types/http2/package.json","../../node_modules/@types/https/package.json","../../node_modules/@types/inspector/package.json","../../node_modules/@types/inspector/promises/package.json","../../node_modules/@types/module/package.json","../../node_modules/@types/net/package.json","../../node_modules/@types/node/assert/package.json","../../node_modules/@types/node/dns/package.json","../../node_modules/@types/node/fs/package.json","../../node_modules/@types/node/inspector/package.json","../../node_modules/@types/node/path/package.json","../../node_modules/@types/node/readline/package.json","../../node_modules/@types/node/stream/package.json","../../node_modules/@types/node/test/package.json","../../node_modules/@types/node/timers/package.json","../../node_modules/@types/node/util/package.json","../../node_modules/@types/node/web-globals/package.json","../../node_modules/@types/node/zlib/package.json","../../node_modules/@types/os/package.json","../../node_modules/@types/path/package.json","../../node_modules/@types/path/posix/package.json","../../node_modules/@types/path/win32/package.json","../../node_modules/@types/perf_hooks/package.json","../../node_modules/@types/process/package.json","../../node_modules/@types/punycode/package.json","../../node_modules/@types/querystring/package.json","../../node_modules/@types/readline/package.json","../../node_modules/@types/readline/promises/package.json","../../node_modules/@types/repl/package.json","../../node_modules/@types/stream/consumers/package.json","../../node_modules/@types/stream/iter/package.json","../../node_modules/@types/stream/package.json","../../node_modules/@types/stream/promises/package.json","../../node_modules/@types/stream/web/package.json","../../node_modules/@types/string_decoder/package.json","../../node_modules/@types/timers/package.json","../../node_modules/@types/timers/promises/package.json","../../node_modules/@types/tls/package.json","../../node_modules/@types/trace_events/package.json","../../node_modules/@types/tty/package.json","../../node_modules/@types/url/package.json","../../node_modules/@types/util/package.json","../../node_modules/@types/util/types/package.json","../../node_modules/@types/v8/package.json","../../node_modules/@types/vm/package.json","../../node_modules/@types/wasi/package.json","../../node_modules/@types/worker_threads/package.json","../../node_modules/@types/zlib/package.json","../../node_modules/@vitejs/devtools/package.json","../../node_modules/@vitest/browser-playwright/package.json","../../node_modules/@vitest/browser-preview/package.json","../../node_modules/@vitest/browser-webdriverio/package.json","../../node_modules/@vitest/coverage-istanbul/package.json","../../node_modules/@vitest/coverage-v8/package.json","../../node_modules/@vitest/mocker/dist/package.json","../../node_modules/@vitest/ui/package.json","../../node_modules/assert/package.json","../../node_modules/assert/strict/package.json","../../node_modules/async_hooks/package.json","../../node_modules/buffer/package.json","../../node_modules/child_process/package.json","../../node_modules/cluster/package.json","../../node_modules/console/package.json","../../node_modules/constants/package.json","../../node_modules/crypto/package.json","../../node_modules/deep-eql/package.json","../../node_modules/dgram/package.json","../../node_modules/diagnostics_channel/package.json","../../node_modules/dns/package.json","../../node_modules/dns/promises/package.json","../../node_modules/domain/package.json","../../node_modules/events/package.json","../../node_modules/expect-type/dist/package.json","../../node_modules/fs/package.json","../../node_modules/fs/promises/package.json","../../node_modules/happy-dom/package.json","../../node_modules/http/package.json","../../node_modules/http2/package.json","../../node_modules/https/package.json","../../node_modules/inspector/package.json","../../node_modules/inspector/promises/package.json","../../node_modules/jiti/package.json","../../node_modules/jsdom/package.json","../../node_modules/less/package.json","../../node_modules/module/package.json","../../node_modules/msw/package.json","../../node_modules/net/package.json","../../node_modules/nice-grpc-common/lib/client/package.json","../../node_modules/nice-grpc-common/lib/package.json","../../node_modules/nice-grpc-common/lib/server/package.json","../../node_modules/nice-grpc/lib/client/package.json","../../node_modules/nice-grpc/lib/package.json","../../node_modules/nice-grpc/lib/server/package.json","../../node_modules/nice-grpc/lib/service-definitions/package.json","../../node_modules/nice-grpc/lib/utils/package.json","../../node_modules/os/package.json","../../node_modules/path/package.json","../../node_modules/path/posix/package.json","../../node_modules/path/win32/package.json","../../node_modules/perf_hooks/package.json","../../node_modules/process/package.json","../../node_modules/protobufjs/ext/descriptor/package.json","../../node_modules/protobufjs/ext/package.json","../../node_modules/protobufjs/node_modules/@types/long/package.json","../../node_modules/protobufjs/node_modules/long/package.json","../../node_modules/punycode/package.json","../../node_modules/querystring/package.json","../../node_modules/readline/package.json","../../node_modules/readline/promises/package.json","../../node_modules/repl/package.json","../../node_modules/sass-embedded/package.json","../../node_modules/sass/package.json","../../node_modules/stream/consumers/package.json","../../node_modules/stream/iter/package.json","../../node_modules/stream/package.json","../../node_modules/stream/promises/package.json","../../node_modules/stream/web/package.json","../../node_modules/string_decoder/package.json","../../node_modules/stylus/package.json","../../node_modules/sugarss/package.json","../../node_modules/terser/package.json","../../node_modules/timers/package.json","../../node_modules/timers/promises/package.json","../../node_modules/tinybench/dist/package.json","../../node_modules/tls/package.json","../../node_modules/trace_events/package.json","../../node_modules/ts-error/lib/package.json","../../node_modules/tty/package.json","../../node_modules/undici/types/package.json","../../node_modules/url/package.json","../../node_modules/util/package.json","../../node_modules/util/types/package.json","../../node_modules/v8/package.json","../../node_modules/vite/dist/node/chunks/package.json","../../node_modules/vite/dist/node/package.json","../../node_modules/vite/dist/package.json","../../node_modules/vite/module-runner/package.json","../../node_modules/vite/types/package.json","../../node_modules/vitest/dist/chunks/package.json","../../node_modules/vitest/dist/package.json","../../node_modules/vm/package.json","../../node_modules/wasi/package.json","../../node_modules/worker_threads/package.json","../../node_modules/zlib/package.json"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cratis/chronicle",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.32.0",
|
|
4
4
|
"description": "Event sourcing for TypeScript and Node.js — the idiomatic client for Cratis Chronicle, the open-source event-sourcing database",
|
|
5
5
|
"author": "Cratis",
|
|
6
6
|
"license": "MIT",
|
|
@@ -168,7 +168,7 @@
|
|
|
168
168
|
"clean": "rm -rf dist",
|
|
169
169
|
"test": "vitest run",
|
|
170
170
|
"test:integration": "vitest run --config vitest.integration.config.ts",
|
|
171
|
-
"test:standard-types": "tsc --ignoreConfig --noEmit --target es2022 --module es2022 --moduleResolution bundler --lib es2022,esnext.decorators --types node --skipLibCheck --strict schemas/decorators.standard.spec.ts projections/declarative/addChildCompatibility.standard.spec.ts projections/modelBound/decorators.standard.spec.ts events/classDecorators.standard.spec.ts reactors/decorators.standard.spec.ts readModels/standardFallbacks.standard.spec.ts readModels/registration.standard.spec.ts for_ChronicleClient/when_registering_artifacts/with_standard_property_mappings.standard.spec.ts artifacts/validateArtifactSchemas.spec.ts testing/for_EventScenario/when_appending_concept_fields/with_standard_decorators.standard.spec.ts",
|
|
171
|
+
"test:standard-types": "tsc --ignoreConfig --noEmit --target es2022 --module es2022 --moduleResolution bundler --lib es2022,esnext.decorators --types node --skipLibCheck --strict schemas/decorators.standard.spec.ts projections/declarative/addChildCompatibility.standard.spec.ts projections/modelBound/decorators.standard.spec.ts events/classDecorators.standard.spec.ts reactors/decorators.standard.spec.ts readModels/standardFallbacks.standard.spec.ts readModels/registration.standard.spec.ts for_ChronicleClient/when_registering_artifacts/with_standard_property_mappings.standard.spec.ts artifacts/validateArtifactSchemas.spec.ts testing/for_EventScenario/when_appending_concept_fields/with_standard_decorators.standard.spec.ts testing/for_EventScenario/when_appending_scoped_constraints/with_standard_decorators.standard.spec.ts",
|
|
172
172
|
"test:native": "node ./scripts/check-native-esm.mjs"
|
|
173
173
|
},
|
|
174
174
|
"dependencies": {
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
// Copyright (c) Cratis. All rights reserved.
|
|
2
|
+
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
|
3
|
+
|
|
4
|
+
import type { EventContext } from '../events/EventContext.js';
|
|
5
|
+
import type { ConstraintScopeCapture } from '../events/constraints/ConstraintBuilder.js';
|
|
6
|
+
|
|
7
|
+
/** Property indexes use the kernel's unescaped flattened key, not a tuple. */
|
|
8
|
+
export function propertyScopeKey(scope: ConstraintScopeCapture, context: EventContext): string {
|
|
9
|
+
const parts: string[] = [];
|
|
10
|
+
if (scope.perEventSourceType) parts.push(`est:${context.eventSourceType}`);
|
|
11
|
+
if (scope.perEventStreamType) parts.push(`estt:${context.eventStreamType}`);
|
|
12
|
+
if (scope.perEventStreamId) parts.push(`esid:${context.eventStreamId}`);
|
|
13
|
+
return parts.join('|');
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
/** Event-type cycles compare selected dimensions exactly. Never flatten them like property keys. */
|
|
17
|
+
export function eventTypeScopeKey(scope: ConstraintScopeCapture, context: EventContext): string {
|
|
18
|
+
return JSON.stringify([
|
|
19
|
+
scope.perEventSourceType ? context.eventSourceType : null,
|
|
20
|
+
scope.perEventStreamType ? context.eventStreamType : null,
|
|
21
|
+
scope.perEventStreamId ? context.eventStreamId : null
|
|
22
|
+
]);
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
/** Keep definition names, scope keys and source IDs in separate map levels. */
|
|
26
|
+
export function scopeIndex<T>(indexes: Map<string, Map<string, T>>, name: string, scope: string, create: () => T): T {
|
|
27
|
+
let scopes = indexes.get(name);
|
|
28
|
+
if (!scopes) { scopes = new Map<string, T>(); indexes.set(name, scopes); }
|
|
29
|
+
let index = scopes.get(scope);
|
|
30
|
+
if (index === undefined) { index = create(); scopes.set(scope, index); }
|
|
31
|
+
return index;
|
|
32
|
+
}
|
|
@@ -138,8 +138,8 @@ describe('when appending batches against committed kernel fixtures', () => {
|
|
|
138
138
|
expected: { sequences: string[]; routes: Array<{ source: string; sourceType: string; streamType: string; streamId: string }> };
|
|
139
139
|
};
|
|
140
140
|
const scenario = create();
|
|
141
|
-
//
|
|
142
|
-
const supported = routeCases
|
|
141
|
+
// Scoped wire fixtures additionally prove ts-proto omission of explicit empty routes.
|
|
142
|
+
const supported = routeCases;
|
|
143
143
|
const results = await scenario.appendMany(supported.map(item => ({ eventSourceId: item.source,
|
|
144
144
|
event: new OracleEventRecorded(item.name, item.active), eventSourceType: item.sourceType,
|
|
145
145
|
eventStreamType: item.streamType, eventStreamId: item.streamId })));
|
|
@@ -450,9 +450,6 @@ describe('when appending batches against committed kernel fixtures', () => {
|
|
|
450
450
|
['appendMany.correlationId', () => scenario.appendMany('B', [event()], { correlationId: 'bad-guid' })],
|
|
451
451
|
['appendMany.entry', () => scenario.appendMany([entry({ unknown: 'value' })])],
|
|
452
452
|
['appendMany.sourceType', () => scenario.appendMany([entry({ eventSourceType: 'bad source' })])],
|
|
453
|
-
['appendMany.sourceType', () => scenario.appendMany([entry({ eventSourceType: '' })], { sourceType: 'Group' })],
|
|
454
|
-
['appendMany.streamType', () => scenario.appendMany('B', [event()], { streamType: '' })],
|
|
455
|
-
['appendMany.streamId', () => scenario.appendMany([entry({ eventStreamId: '' })], { streamId: 'stream1' })],
|
|
456
453
|
['appendMany.subject', () => scenario.appendMany([entry({ subject: '' })], { subject: 'shared' })],
|
|
457
454
|
['appendMany.streamType', () => scenario.appendMany([entry({ eventStreamType: 'bad stream' })])],
|
|
458
455
|
['appendMany.streamId', () => scenario.appendMany([entry({ eventStreamId: 'bad stream' })])],
|
|
@@ -355,7 +355,7 @@ describe('fixture-backed unscoped constraints', () => {
|
|
|
355
355
|
subject.results.length.should.equal(1);
|
|
356
356
|
});
|
|
357
357
|
|
|
358
|
-
it('rejects
|
|
358
|
+
it('rejects malformed or overlapping configurations and unsupported keys before mutation', async () => {
|
|
359
359
|
const scoped = (configure: (builder: IConstraintBuilder) => void) => {
|
|
360
360
|
class InvalidConstraint implements IConstraint {
|
|
361
361
|
define(builder: IConstraintBuilder) { configure(builder); }
|
|
@@ -363,9 +363,6 @@ describe('fixture-backed unscoped constraints', () => {
|
|
|
363
363
|
constraint('ScopedOrComposite')(InvalidConstraint);
|
|
364
364
|
unsupported(() => new EventScenario({ artifacts: { eventTypes: types, constraints: [InvalidConstraint] } }), 'artifacts.constraints');
|
|
365
365
|
};
|
|
366
|
-
scoped(builder => builder.perEventStreamId().unique(key => key.on(OracleKeyClaimed, event => event.key)));
|
|
367
|
-
scoped(builder => builder.perEventStreamType().unique(key => key.on(OracleKeyClaimed, event => event.key)));
|
|
368
|
-
scoped(builder => builder.perEventSourceType().unique(key => key.on(OracleKeyClaimed, event => event.key)));
|
|
369
366
|
scoped(builder => builder.unique(key => key.on(OracleKeyClaimed, event => event.key, event => event.key)));
|
|
370
367
|
scoped(builder => builder.perEventStreamId().unique(key => key.on(OracleKeyClaimed, event => event.key).ignoreCasing()));
|
|
371
368
|
scoped(builder => builder.unique(key => key.on(OracleKeyClaimed, event => event.key))
|
|
@@ -59,7 +59,7 @@ const fixtures = readdirSync(directory).filter(name => name.endsWith('.json') &&
|
|
|
59
59
|
!['batches.json', 'batch-omitted-routes.json', 'batch-rollback.json', 'builders.json', 'constraints.json', 'constraints-isolation.json', 'constraints-key-domain.json',
|
|
60
60
|
'constraints-property-lifecycle.json', 'constraints-property-covered-removal.json', 'constraints-event-type-cycles.json',
|
|
61
61
|
'constraints-event-type-siblings.json', 'constraints-composite.json',
|
|
62
|
-
'constraints-ignore-casing.json'].includes(name)).map(name => ({
|
|
62
|
+
'constraints-ignore-casing.json', 'constraints-scopes.json'].includes(name)).map(name => ({
|
|
63
63
|
name, fixture: JSON.parse(readFileSync(new URL(name, directory), 'utf8')) as Fixture
|
|
64
64
|
}));
|
|
65
65
|
const artifacts = { eventTypes: [OracleEventRecorded, AlternateRecorded, BoundaryRecorded], constraints: [] };
|
package/testing/EventScenario.ts
CHANGED
|
@@ -96,9 +96,21 @@ export class EventScenario {
|
|
|
96
96
|
throw new UnsupportedEventSequenceOperation('artifacts.constraints', name,
|
|
97
97
|
'Every constrained event type must be in the selected catalog. Claiming and removal references must be complete.');
|
|
98
98
|
}
|
|
99
|
+
const scoped = Object.values(capture.scope).some(Boolean);
|
|
100
|
+
if (scoped && removedWith.some(id => {
|
|
101
|
+
const type = eventTypes.find(type => getEventTypeFor(type).id.value === id);
|
|
102
|
+
return type && Object.keys(getEventTypeMetadata(type)?.schema.properties ?? {}).length === 0;
|
|
103
|
+
})) {
|
|
104
|
+
throw new UnsupportedEventSequenceOperation('artifacts.constraints', name,
|
|
105
|
+
'Scoped fieldless removal events are not fixture-backed.');
|
|
106
|
+
}
|
|
99
107
|
for (const entry of capture.uniqueConstraint?.eventDefinitions ?? []) {
|
|
100
108
|
const type = eventTypes.find(type => getEventTypeFor(type).id.value === entry.eventTypeId)!;
|
|
101
109
|
const schemaTypes = entry.properties.map(property => getEventTypeMetadata(type)?.schema.properties?.[property]?.type ?? '');
|
|
110
|
+
if (scoped && schemaTypes.some(schemaType => schemaType !== 'string')) {
|
|
111
|
+
throw new UnsupportedEventSequenceOperation('artifacts.constraints', name,
|
|
112
|
+
'Scoped property keys must be schema-backed strings.');
|
|
113
|
+
}
|
|
102
114
|
if (entry.properties.length === 1 && !['string', 'boolean'].includes(schemaTypes[0])) {
|
|
103
115
|
throw new UnsupportedEventSequenceOperation('artifacts.constraints', name,
|
|
104
116
|
'The constrained property must be a schema-backed string or boolean.');
|
|
@@ -8,6 +8,7 @@ import type { ConstraintCapture } from '../events/constraints/ConstraintBuilder.
|
|
|
8
8
|
import { resolveConstraintMessage } from '../events/constraints/Constraints.js';
|
|
9
9
|
import type { ConstraintViolation } from '../eventSequences/ConstraintViolation.js';
|
|
10
10
|
import { UnsupportedEventSequenceOperation } from './UnsupportedEventSequenceOperation.js';
|
|
11
|
+
import { eventTypeScopeKey, propertyScopeKey, scopeIndex } from './ConstraintScope.js';
|
|
11
12
|
|
|
12
13
|
export type WireConstraintViolation = ContractsConstraintViolation;
|
|
13
14
|
|
|
@@ -49,7 +50,7 @@ function claimOf(name: string, unique: UniqueCapture, eventTypeId: string, conte
|
|
|
49
50
|
return { key: keyHash(joined.replace(/[A-Z]/g, letter => String.fromCharCode(letter.charCodeAt(0) + 32))), parts };
|
|
50
51
|
}
|
|
51
52
|
|
|
52
|
-
/** Narrow, fixture-backed
|
|
53
|
+
/** Narrow, fixture-backed constraint validation over serialized event snapshots. */
|
|
53
54
|
export class InProcessConstraints {
|
|
54
55
|
private readonly _constrainedProperties = new Map<string, Set<string>>();
|
|
55
56
|
private readonly _removalTypes = new Set<string>();
|
|
@@ -62,11 +63,15 @@ export class InProcessConstraints {
|
|
|
62
63
|
if (capture.uniqueConstraint && capture.uniqueEventType) {
|
|
63
64
|
throw this.unsupported(name, 'A definition with both constraint kinds is not fixture-backed.');
|
|
64
65
|
}
|
|
65
|
-
|
|
66
|
-
|
|
66
|
+
const scoped = Object.values(capture.scope).some(Boolean);
|
|
67
|
+
if (scoped && _definitions.size !== 1) {
|
|
68
|
+
throw this.unsupported(name, 'Scoped constraints alongside other definitions are not fixture-backed.');
|
|
67
69
|
}
|
|
68
70
|
if (capture.uniqueConstraint) {
|
|
69
71
|
const unique = capture.uniqueConstraint;
|
|
72
|
+
if (scoped && (unique.ignoreCasing || unique.eventDefinitions.some(entry => entry.properties.length !== 1))) {
|
|
73
|
+
throw this.unsupported(name, 'Scoped composite or case-insensitive property keys are not fixture-backed.');
|
|
74
|
+
}
|
|
70
75
|
// constraints-composite.json installs one, two and three flat properties per event type.
|
|
71
76
|
// The kernel keys properties by path with ToDictionary, so duplicate paths are not a key shape.
|
|
72
77
|
if (unique.eventDefinitions.length === 0 || unique.eventDefinitions.some(entry =>
|
|
@@ -85,6 +90,10 @@ export class InProcessConstraints {
|
|
|
85
90
|
this._removalTypes.add(id);
|
|
86
91
|
this._propertyRemovalTypes.add(id);
|
|
87
92
|
}
|
|
93
|
+
if (scoped && unique.eventDefinitions.some(entry =>
|
|
94
|
+
entry.eventTypeId === unique.removedWithEventTypeId || unique.removedWithEventTypeIds?.includes(entry.eventTypeId))) {
|
|
95
|
+
throw this.unsupported(name, 'Scoped covered-and-removal property events are not fixture-backed.');
|
|
96
|
+
}
|
|
88
97
|
for (const entry of unique.eventDefinitions) {
|
|
89
98
|
const properties = this._constrainedProperties.get(entry.eventTypeId) ?? new Set<string>();
|
|
90
99
|
entry.properties.forEach(property => properties.add(property));
|
|
@@ -104,6 +113,9 @@ export class InProcessConstraints {
|
|
|
104
113
|
!(ids.length === 3 && removals.length === 3 && shared === 1)) {
|
|
105
114
|
throw this.unsupported(name, 'This unique event type set and removal combination is not fixture-backed.');
|
|
106
115
|
}
|
|
116
|
+
if (scoped && shared !== 0) {
|
|
117
|
+
throw this.unsupported(name, 'Scoped covered-and-removal event cycles are not fixture-backed.');
|
|
118
|
+
}
|
|
107
119
|
// Each cycle fixture installs its definition alone; interaction with other definitions is unproven.
|
|
108
120
|
if (removals.length && _definitions.size !== 1) {
|
|
109
121
|
throw this.unsupported(name, 'Unique event cycles alongside other definitions are not fixture-backed.');
|
|
@@ -145,15 +157,16 @@ export class InProcessConstraints {
|
|
|
145
157
|
const violations: WireConstraintViolation[] = [];
|
|
146
158
|
// Durable ownership is one claim per source, not one entry per historical value.
|
|
147
159
|
// Rebuild it from committed history; batch claims below remain independent and are never released.
|
|
148
|
-
const owners = new Map<string, Map<string, { key: string; sequence: string }
|
|
160
|
+
const owners = new Map<string, Map<string, Map<string, { key: string; sequence: string }>>>();
|
|
149
161
|
for (const [name, definition] of this._definitions) {
|
|
150
162
|
if (!definition.uniqueConstraint) continue;
|
|
151
|
-
const claims = new Map<string, { key: string; sequence: string }>();
|
|
152
163
|
const unique = definition.uniqueConstraint;
|
|
153
164
|
const removals = new Set([unique.removedWithEventTypeId, ...(unique.removedWithEventTypeIds ?? [])]);
|
|
154
165
|
for (const prior of history) {
|
|
155
166
|
const type = prior.eventType.id.value;
|
|
156
167
|
const source = prior.context.eventSourceId;
|
|
168
|
+
const claims = scopeIndex(owners, name, propertyScopeKey(definition.scope, prior.context),
|
|
169
|
+
() => new Map<string, { key: string; sequence: string }>());
|
|
157
170
|
if (removals.has(type)) {
|
|
158
171
|
claims.delete(source);
|
|
159
172
|
continue;
|
|
@@ -166,10 +179,9 @@ export class InProcessConstraints {
|
|
|
166
179
|
claims.set(source, { key: claimOf(name, unique, type, prior.content)!.key,
|
|
167
180
|
sequence: prior.context.sequenceNumber.toString() });
|
|
168
181
|
}
|
|
169
|
-
owners.set(name, claims);
|
|
170
182
|
}
|
|
171
|
-
const stagedKeys = new Map<string, Map<string, string
|
|
172
|
-
const stagedCycles = new Map<string, Map<string, 'open' | 'released'
|
|
183
|
+
const stagedKeys = new Map<string, Map<string, Map<string, string>>>();
|
|
184
|
+
const stagedCycles = new Map<string, Map<string, Map<string, 'open' | 'released'>>>();
|
|
173
185
|
for (const event of incoming) {
|
|
174
186
|
const type = event.eventType.id.value;
|
|
175
187
|
const source = event.context.eventSourceId;
|
|
@@ -178,8 +190,10 @@ export class InProcessConstraints {
|
|
|
178
190
|
const claim = definition.uniqueConstraint && claimOf(name, definition.uniqueConstraint, type, event.content);
|
|
179
191
|
if (claim) {
|
|
180
192
|
const key = claim.key;
|
|
181
|
-
const
|
|
182
|
-
const
|
|
193
|
+
const scope = propertyScopeKey(definition.scope, event.context);
|
|
194
|
+
const durableClaims = owners.get(name)?.get(scope);
|
|
195
|
+
const existing = [...(durableClaims?.entries() ?? [])].find(([, claim]) => claim.key === key);
|
|
196
|
+
const batchClaims = scopeIndex(stagedKeys, name, scope, () => new Map<string, string>());
|
|
183
197
|
const batchOwner = batchClaims.get(key);
|
|
184
198
|
if (existing && existing[0] !== source || batchOwner !== undefined && batchOwner !== source) {
|
|
185
199
|
// One violation per declared property, in declared order, each with its own original value.
|
|
@@ -192,7 +206,6 @@ export class InProcessConstraints {
|
|
|
192
206
|
}
|
|
193
207
|
} else {
|
|
194
208
|
batchClaims.set(key, source);
|
|
195
|
-
stagedKeys.set(name, batchClaims);
|
|
196
209
|
}
|
|
197
210
|
}
|
|
198
211
|
const uniqueType = definition.uniqueEventType;
|
|
@@ -200,14 +213,15 @@ export class InProcessConstraints {
|
|
|
200
213
|
const covered = uniqueType.eventTypeIds ?? [uniqueType.eventTypeId];
|
|
201
214
|
const removals = uniqueType.removedWithEventTypeIds ?? [];
|
|
202
215
|
// Durable answer: the earliest covered event after the latest removal for this source.
|
|
216
|
+
const scope = eventTypeScopeKey(definition.scope, event.context);
|
|
203
217
|
let first: AppendedEvent | undefined;
|
|
204
218
|
for (const prior of history) {
|
|
205
|
-
if (prior.context.eventSourceId !== source) continue;
|
|
219
|
+
if (prior.context.eventSourceId !== source || eventTypeScopeKey(definition.scope, prior.context) !== scope) continue;
|
|
206
220
|
const priorType = prior.eventType.id.value;
|
|
207
221
|
if (removals.includes(priorType)) first = undefined;
|
|
208
222
|
else if (!first && covered.includes(priorType)) first = prior;
|
|
209
223
|
}
|
|
210
|
-
const cycles = stagedCycles
|
|
224
|
+
const cycles = scopeIndex(stagedCycles, name, scope, () => new Map<string, 'open' | 'released'>());
|
|
211
225
|
const state = cycles.get(source);
|
|
212
226
|
// A cycle state recorded earlier in this append overrides durable history.
|
|
213
227
|
if (state === 'open' || state === undefined && first) {
|
|
@@ -219,7 +233,6 @@ export class InProcessConstraints {
|
|
|
219
233
|
Details: {} });
|
|
220
234
|
} else {
|
|
221
235
|
cycles.set(source, 'open');
|
|
222
|
-
stagedCycles.set(name, cycles);
|
|
223
236
|
}
|
|
224
237
|
}
|
|
225
238
|
}
|
|
@@ -228,9 +241,9 @@ export class InProcessConstraints {
|
|
|
228
241
|
if (violations.length === violationCount) {
|
|
229
242
|
for (const [name, definition] of this._definitions) {
|
|
230
243
|
if (definition.uniqueEventType?.removedWithEventTypeIds?.includes(type)) {
|
|
231
|
-
const cycles = stagedCycles
|
|
244
|
+
const cycles = scopeIndex(stagedCycles, name, eventTypeScopeKey(definition.scope, event.context),
|
|
245
|
+
() => new Map<string, 'open' | 'released'>());
|
|
232
246
|
cycles.set(source, 'released');
|
|
233
|
-
stagedCycles.set(name, cycles);
|
|
234
247
|
}
|
|
235
248
|
}
|
|
236
249
|
}
|
|
@@ -169,12 +169,7 @@ export class InProcessEventSequence implements IEventSequence {
|
|
|
169
169
|
try {
|
|
170
170
|
if (!event || typeof event !== 'object') throw this.unsupported('append.event', this.id.value, 'Only registered event instances are supported.');
|
|
171
171
|
if (!/^[A-Za-z0-9_-]+$/.test(eventSourceId)) throw this.unsupported('append.source', eventSourceId, 'Only simple source identifiers are fixture-backed.');
|
|
172
|
-
|
|
173
|
-
options.streamType !== undefined || options.streamId !== undefined || options.subject !== undefined ||
|
|
174
|
-
options.occurred !== undefined || options.eventSourceId !== undefined || options.concurrencyScope !== undefined ||
|
|
175
|
-
options.tags !== undefined || options.concurrencyScopes !== undefined)) {
|
|
176
|
-
throw this.unsupported('append.options', event.constructor.name, 'Append metadata, routing and concurrency are not fixture-backed.');
|
|
177
|
-
}
|
|
172
|
+
const route = this.singleAppendRoute(options, event.constructor.name);
|
|
178
173
|
const metadata = this._catalog.get(event.constructor);
|
|
179
174
|
if (!metadata) throw this.unsupported('append.event', event.constructor.name, 'Event is not in the selected, validated catalog.');
|
|
180
175
|
let prepared: ReturnType<typeof prepareSingleAppend>;
|
|
@@ -212,7 +207,7 @@ export class InProcessEventSequence implements IEventSequence {
|
|
|
212
207
|
context: {
|
|
213
208
|
eventStore: this._store, namespace: this._namespace,
|
|
214
209
|
sequenceNumber: sequenceNumber.value, eventSourceId,
|
|
215
|
-
eventSourceType:
|
|
210
|
+
eventSourceType: route.sourceType, eventStreamType: route.streamType, eventStreamId: route.streamId,
|
|
216
211
|
subject: eventSourceId, hash, causedBy: prepared.identity, observationState: EventObservationState.Initial,
|
|
217
212
|
eventType: prepared.eventType, occurred, correlationId: prepared.correlationId.toString(),
|
|
218
213
|
causation: prepared.causationChain.map(item => ({ type: item.type.name, occurred: item.occurred, properties: { ...item.properties } })),
|
|
@@ -295,7 +290,8 @@ export class InProcessEventSequence implements IEventSequence {
|
|
|
295
290
|
const wire = eventsToAppend[index];
|
|
296
291
|
for (const [name, value] of Object.entries({ sourceType: wire.EventSourceType, streamType: wire.EventStreamType,
|
|
297
292
|
streamId: wire.EventStreamId, subject: wire.Subject })) {
|
|
298
|
-
|
|
293
|
+
const identifiers = name === 'subject' ? /^[A-Za-z0-9_-]+$/ : /^[A-Za-z0-9_-]*$/;
|
|
294
|
+
if (value !== undefined && (typeof value !== 'string' || !identifiers.test(value))) {
|
|
299
295
|
throw this.unsupported(`appendMany.${name}`, String(value), 'Only simple metadata identifiers are fixture-backed.');
|
|
300
296
|
}
|
|
301
297
|
}
|
|
@@ -403,6 +399,26 @@ export class InProcessEventSequence implements IEventSequence {
|
|
|
403
399
|
}
|
|
404
400
|
}
|
|
405
401
|
|
|
402
|
+
private singleAppendRoute(options: AppendOptions | undefined, artifact: string): { sourceType: string; streamType: string; streamId: string } {
|
|
403
|
+
if (options !== undefined && (!options || typeof options !== 'object' || Array.isArray(options))) {
|
|
404
|
+
throw this.unsupported('append.options', artifact, 'Append options must be an object.');
|
|
405
|
+
}
|
|
406
|
+
if (options && (Reflect.ownKeys(options).some(key => !['sourceType', 'streamType', 'streamId'].includes(String(key))) ||
|
|
407
|
+
options.correlationId !== undefined || options.subject !== undefined || options.occurred !== undefined ||
|
|
408
|
+
options.eventSourceId !== undefined || options.concurrencyScope !== undefined || options.tags !== undefined ||
|
|
409
|
+
options.concurrencyScopes !== undefined)) {
|
|
410
|
+
throw this.unsupported('append.options', artifact, 'Only sourceType, streamType and streamId routing options are fixture-backed for single append.');
|
|
411
|
+
}
|
|
412
|
+
const route = { sourceType: options?.sourceType, streamType: options?.streamType, streamId: options?.streamId };
|
|
413
|
+
for (const [name, value] of Object.entries(route)) {
|
|
414
|
+
if (value !== undefined && (typeof value !== 'string' || !/^[A-Za-z0-9_-]*$/.test(value))) {
|
|
415
|
+
throw this.unsupported(`append.${name}`, String(value), 'Only simple routing identifiers or empty defaults are fixture-backed.');
|
|
416
|
+
}
|
|
417
|
+
}
|
|
418
|
+
// ts-proto omits empty strings; the append pipeline resolves omissions to these exact values.
|
|
419
|
+
return { sourceType: route.sourceType || 'Default', streamType: route.streamType || 'All', streamId: route.streamId || 'Default' };
|
|
420
|
+
}
|
|
421
|
+
|
|
406
422
|
private validateBatchOptions(options?: AppendOptions): void {
|
|
407
423
|
if (options === undefined) return;
|
|
408
424
|
if (!options || typeof options !== 'object' || Array.isArray(options)) {
|