velocious 1.0.619 → 1.0.620
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/build/configuration.js +1 -1
- package/build/environment-handlers/base.js +8 -0
- package/build/environment-handlers/node.js +12 -0
- package/build/src/configuration.js +2 -2
- package/build/src/environment-handlers/base.d.ts +7 -0
- package/build/src/environment-handlers/base.d.ts.map +1 -1
- package/build/src/environment-handlers/base.js +8 -1
- package/build/src/environment-handlers/node.d.ts +7 -0
- package/build/src/environment-handlers/node.d.ts.map +1 -1
- package/build/src/environment-handlers/node.js +12 -1
- package/build/src/testing/shared-transaction-connection-coordinator.d.ts +2 -0
- package/build/src/testing/shared-transaction-connection-coordinator.d.ts.map +1 -1
- package/build/src/testing/shared-transaction-connection-coordinator.js +79 -12
- package/build/src/testing/test.d.ts +1 -1
- package/build/src/testing/test.d.ts.map +1 -1
- package/build/src/testing/test.js +2 -2
- package/build/testing/shared-transaction-connection-coordinator.js +83 -10
- package/build/testing/test.js +1 -1
- package/build/tsconfig.tsbuildinfo +1 -1
- package/package.json +2 -1
- package/src/configuration.js +1 -1
- package/src/environment-handlers/base.js +8 -0
- package/src/environment-handlers/node.js +12 -0
- package/src/testing/shared-transaction-connection-coordinator.js +83 -10
- package/src/testing/test.js +1 -1
- package/build/src/testing/wait-for-event.d.ts +0 -46
- package/build/src/testing/wait-for-event.d.ts.map +0 -1
- package/build/src/testing/wait-for-event.js +0 -64
- package/build/testing/wait-for-event.js +0 -72
- package/src/testing/wait-for-event.js +0 -72
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":"7.0.2","root":["../index.js","../bin/velocious.js","../src/application.js","../src/configuration-resolver.js","../src/configuration-types.js","../src/configuration.js","../src/controller.js","../src/current-configuration.js","../src/current.js","../src/error-logger.js","../src/frontend-model-controller.js","../src/initializer.js","../src/logger.js","../src/mailer.js","../src/record-payload-values.js","../src/time-zone.js","../src/velocious-error.js","../src/authorization/ability.js","../src/authorization/base-resource.js","../src/background-jobs/adapter-client.js","../src/background-jobs/adapter.js","../src/background-jobs/client.js","../src/background-jobs/cron-expression.js","../src/background-jobs/forked-runner-child.js","../src/background-jobs/job-record.js","../src/background-jobs/job-registry.js","../src/background-jobs/job-runner.js","../src/background-jobs/job-semantics.js","../src/background-jobs/job.js","../src/background-jobs/json-socket.js","../src/background-jobs/local-adapter.js","../src/background-jobs/local-dispatcher.js","../src/background-jobs/local-job-registry.js","../src/background-jobs/local-store.js","../src/background-jobs/main.js","../src/background-jobs/normalize-error.js","../src/background-jobs/perform-job.js","../src/background-jobs/platform-job.js","../src/background-jobs/pooled-runner-broker-identity.js","../src/background-jobs/pooled-runner-child.js","../src/background-jobs/reschedule-signal.js","../src/background-jobs/runner-graceful-shutdown.js","../src/background-jobs/runner-process-title.js","../src/background-jobs/runtime.js","../src/background-jobs/scheduler.js","../src/background-jobs/socket-request.js","../src/background-jobs/sql-adapter.js","../src/background-jobs/status-reporter.js","../src/background-jobs/store.js","../src/background-jobs/types.js","../src/background-jobs/worker.js","../src/background-jobs/web/authorization.js","../src/background-jobs/web/controller.js","../src/background-jobs/web/counts-channel.js","../src/background-jobs/web/index.js","../src/background-jobs/web/path-matcher.js","../src/background-jobs/web/registry.js","../src/beacon/client.js","../src/beacon/in-process-broker.js","../src/beacon/in-process-client.js","../src/beacon/server.js","../src/beacon/types.js","../src/cli/base-command.js","../src/cli/browser-cli.js","../src/cli/command-arguments.js","../src/cli/index.js","../src/cli/tenant-database-command-helper.js","../src/cli/use-browser-cli.js","../src/cli/commands/background-jobs-main.js","../src/cli/commands/background-jobs-runner.js","../src/cli/commands/background-jobs-worker.js","../src/cli/commands/beacon.js","../src/cli/commands/console.js","../src/cli/commands/init.js","../src/cli/commands/routes.js","../src/cli/commands/run-script.js","../src/cli/commands/runner.js","../src/cli/commands/server.js","../src/cli/commands/test.js","../src/cli/commands/db/base-command.js","../src/cli/commands/db/create.js","../src/cli/commands/db/drop.js","../src/cli/commands/db/migrate.js","../src/cli/commands/db/reset.js","../src/cli/commands/db/rollback.js","../src/cli/commands/db/seed.js","../src/cli/commands/db/schema/dump.js","../src/cli/commands/db/schema/load.js","../src/cli/commands/db/tenants/check.js","../src/cli/commands/db/tenants/create.js","../src/cli/commands/db/tenants/drop.js","../src/cli/commands/db/tenants/migrate.js","../src/cli/commands/db/tenants/migrations/pending.js","../src/cli/commands/destroy/migration.js","../src/cli/commands/generate/base-models.js","../src/cli/commands/generate/frontend-models.js","../src/cli/commands/generate/migration.js","../src/cli/commands/generate/model.js","../src/cli/commands/lint/relationships.js","../src/cli/commands/test/timing-manifest/merge.js","../src/database/advisory-lock-runner.js","../src/database/annotations-async-hooks.js","../src/database/annotations.js","../src/database/column-types.js","../src/database/datetime-storage.js","../src/database/generation-context.js","../src/database/handler.js","../src/database/initializer-from-require-context.js","../src/database/live-query.js","../src/database/migrations-ledger.js","../src/database/migrator.js","../src/database/operation-connection.js","../src/database/operation-lease.js","../src/database/operation.js","../src/database/query-aborted-error.js","../src/database/record-changes.js","../src/database/structure-sql-loader.js","../src/database/use-database.js","../src/database/use-live-query.js","../src/database/drivers/base-column.js","../src/database/drivers/base-columns-index.js","../src/database/drivers/base-foreign-key.js","../src/database/drivers/base-table.js","../src/database/drivers/base.js","../src/database/drivers/index-metadata.js","../src/database/drivers/mssql/column.js","../src/database/drivers/mssql/columns-index.js","../src/database/drivers/mssql/connect-connection.js","../src/database/drivers/mssql/foreign-key.js","../src/database/drivers/mssql/index.js","../src/database/drivers/mssql/options.js","../src/database/drivers/mssql/query-parser.js","../src/database/drivers/mssql/structure-sql.js","../src/database/drivers/mssql/table.js","../src/database/drivers/mssql/sql/alter-table.js","../src/database/drivers/mssql/sql/create-database.js","../src/database/drivers/mssql/sql/create-index.js","../src/database/drivers/mssql/sql/create-table.js","../src/database/drivers/mssql/sql/delete.js","../src/database/drivers/mssql/sql/drop-database.js","../src/database/drivers/mssql/sql/drop-table.js","../src/database/drivers/mssql/sql/insert.js","../src/database/drivers/mssql/sql/remove-index.js","../src/database/drivers/mssql/sql/update.js","../src/database/drivers/mssql/sql/upsert.js","../src/database/drivers/mysql/column.js","../src/database/drivers/mysql/columns-index.js","../src/database/drivers/mysql/deadlock-diagnostic-parser.js","../src/database/drivers/mysql/foreign-key.js","../src/database/drivers/mysql/index.js","../src/database/drivers/mysql/options.js","../src/database/drivers/mysql/query-parser.js","../src/database/drivers/mysql/query-stream.js","../src/database/drivers/mysql/query.js","../src/database/drivers/mysql/structure-sql.js","../src/database/drivers/mysql/table.js","../src/database/drivers/mysql/sql/alter-table.js","../src/database/drivers/mysql/sql/create-database.js","../src/database/drivers/mysql/sql/create-index.js","../src/database/drivers/mysql/sql/create-table.js","../src/database/drivers/mysql/sql/delete.js","../src/database/drivers/mysql/sql/drop-database.js","../src/database/drivers/mysql/sql/drop-table.js","../src/database/drivers/mysql/sql/insert.js","../src/database/drivers/mysql/sql/remove-index.js","../src/database/drivers/mysql/sql/update.js","../src/database/drivers/mysql/sql/upsert.js","../src/database/drivers/pgsql/column.js","../src/database/drivers/pgsql/columns-index.js","../src/database/drivers/pgsql/foreign-key.js","../src/database/drivers/pgsql/index.js","../src/database/drivers/pgsql/options.js","../src/database/drivers/pgsql/query-parser.js","../src/database/drivers/pgsql/structure-sql.js","../src/database/drivers/pgsql/table.js","../src/database/drivers/pgsql/sql/alter-table.js","../src/database/drivers/pgsql/sql/create-database.js","../src/database/drivers/pgsql/sql/create-index.js","../src/database/drivers/pgsql/sql/create-table.js","../src/database/drivers/pgsql/sql/delete.js","../src/database/drivers/pgsql/sql/drop-database.js","../src/database/drivers/pgsql/sql/drop-table.js","../src/database/drivers/pgsql/sql/insert.js","../src/database/drivers/pgsql/sql/remove-index.js","../src/database/drivers/pgsql/sql/update.js","../src/database/drivers/pgsql/sql/upsert.js","../src/database/drivers/sqlite/base.js","../src/database/drivers/sqlite/column.js","../src/database/drivers/sqlite/columns-index.js","../src/database/drivers/sqlite/connection-sql-js.js","../src/database/drivers/sqlite/foreign-key.js","../src/database/drivers/sqlite/index.js","../src/database/drivers/sqlite/index.native.js","../src/database/drivers/sqlite/index.web.js","../src/database/drivers/sqlite/options.js","../src/database/drivers/sqlite/query-parser.js","../src/database/drivers/sqlite/query.js","../src/database/drivers/sqlite/query.native.js","../src/database/drivers/sqlite/query.web.js","../src/database/drivers/sqlite/structure-sql.js","../src/database/drivers/sqlite/table-rebuilder.js","../src/database/drivers/sqlite/table.js","../src/database/drivers/sqlite/web-persistence.js","../src/database/drivers/sqlite/sql/alter-table.js","../src/database/drivers/sqlite/sql/create-index.js","../src/database/drivers/sqlite/sql/create-table.js","../src/database/drivers/sqlite/sql/delete.js","../src/database/drivers/sqlite/sql/drop-table.js","../src/database/drivers/sqlite/sql/insert.js","../src/database/drivers/sqlite/sql/remove-index.js","../src/database/drivers/sqlite/sql/update.js","../src/database/drivers/sqlite/sql/upsert.js","../src/database/drivers/structure-sql/utils.js","../src/database/migration/change-table.js","../src/database/migration/index.js","../src/database/migrator/files-finder.js","../src/database/migrator/types.js","../src/database/pool/async-tracked-multi-connection.js","../src/database/pool/base-methods-forward.js","../src/database/pool/base.js","../src/database/pool/single-multi-use.js","../src/database/query/alter-table-base.js","../src/database/query/base.js","../src/database/query/create-database-base.js","../src/database/query/create-index-base.js","../src/database/query/create-table-base.js","../src/database/query/delete-base.js","../src/database/query/drop-database-base.js","../src/database/query/drop-table-base.js","../src/database/query/from-base.js","../src/database/query/from-plain.js","../src/database/query/from-table.js","../src/database/query/index.js","../src/database/query/insert-base.js","../src/database/query/join-base.js","../src/database/query/join-object.js","../src/database/query/join-plain.js","../src/database/query/join-tracker.js","../src/database/query/model-class-query.js","../src/database/query/order-base.js","../src/database/query/order-column.js","../src/database/query/order-plain.js","../src/database/query/preloader.js","../src/database/query/query-data.js","../src/database/query/remove-index-base.js","../src/database/query/select-base.js","../src/database/query/select-plain.js","../src/database/query/select-table-and-column.js","../src/database/query/update-base.js","../src/database/query/upsert-base.js","../src/database/query/where-base.js","../src/database/query/where-combinator.js","../src/database/query/where-hash.js","../src/database/query/where-model-class-hash.js","../src/database/query/where-not.js","../src/database/query/where-plain.js","../src/database/query/with-count.js","../src/database/query/preloader/belongs-to.js","../src/database/query/preloader/ensure-model-class-initialized.js","../src/database/query/preloader/has-many.js","../src/database/query/preloader/has-one.js","../src/database/query/preloader/query-for-model.js","../src/database/query/preloader/selection.js","../src/database/query-parser/base-query-parser.js","../src/database/query-parser/from-parser.js","../src/database/query-parser/group-parser.js","../src/database/query-parser/joins-parser.js","../src/database/query-parser/limit-parser.js","../src/database/query-parser/options.js","../src/database/query-parser/order-parser.js","../src/database/query-parser/select-parser.js","../src/database/query-parser/where-parser.js","../src/database/record/acts-as-list.js","../src/database/record/auditing.js","../src/database/record/counter-cache-magnitude.js","../src/database/record/index.js","../src/database/record/record-not-found-error.js","../src/database/record/state-machine.js","../src/database/record/user-module.js","../src/database/record/validation-messages.js","../src/database/record/attachments/attachment-record.js","../src/database/record/attachments/download.js","../src/database/record/attachments/handle.js","../src/database/record/attachments/normalize-input.js","../src/database/record/attachments/store.js","../src/database/record/attachments/storage-drivers/filesystem.js","../src/database/record/attachments/storage-drivers/native.js","../src/database/record/attachments/storage-drivers/s3.js","../src/database/record/instance-relationships/base.js","../src/database/record/instance-relationships/belongs-to.js","../src/database/record/instance-relationships/has-many.js","../src/database/record/instance-relationships/has-one.js","../src/database/record/relationships/base.js","../src/database/record/relationships/belongs-to.js","../src/database/record/relationships/has-many.js","../src/database/record/relationships/has-one.js","../src/database/record/validators/base.js","../src/database/record/validators/format.js","../src/database/record/validators/length.js","../src/database/record/validators/presence.js","../src/database/record/validators/uniqueness.js","../src/database/table-data/index.js","../src/database/table-data/table-column.js","../src/database/table-data/table-foreign-key.js","../src/database/table-data/table-index.js","../src/database/table-data/table-reference.js","../src/database/tenants/data-copier.js","../src/database/tenants/migration-pending-inspector.js","../src/database/tenants/schema-cloner.js","../src/database/tenants/tenant-table-plan.js","../src/environment-handlers/base.js","../src/environment-handlers/browser.js","../src/environment-handlers/node.js","../src/environment-handlers/node/attachment-path-source.js","../src/environment-handlers/node/source-peer-package.js","../src/environment-handlers/node/cli/commands/background-jobs-main.js","../src/environment-handlers/node/cli/commands/background-jobs-runner.js","../src/environment-handlers/node/cli/commands/background-jobs-worker.js","../src/environment-handlers/node/cli/commands/beacon.js","../src/environment-handlers/node/cli/commands/cli-command-context.js","../src/environment-handlers/node/cli/commands/console.js","../src/environment-handlers/node/cli/commands/init.js","../src/environment-handlers/node/cli/commands/routes.js","../src/environment-handlers/node/cli/commands/run-script.js","../src/environment-handlers/node/cli/commands/runner.js","../src/environment-handlers/node/cli/commands/server.js","../src/environment-handlers/node/cli/commands/test.js","../src/environment-handlers/node/cli/commands/db/seed.js","../src/environment-handlers/node/cli/commands/db/schema/dump.js","../src/environment-handlers/node/cli/commands/db/schema/load.js","../src/environment-handlers/node/cli/commands/destroy/migration.js","../src/environment-handlers/node/cli/commands/generate/base-models.js","../src/environment-handlers/node/cli/commands/generate/frontend-models.js","../src/environment-handlers/node/cli/commands/generate/generated-file-banner.js","../src/environment-handlers/node/cli/commands/generate/migration.js","../src/environment-handlers/node/cli/commands/generate/model.js","../src/environment-handlers/node/cli/commands/lint/relationships.js","../src/environment-handlers/node/cli/commands/test/timing-manifest/merge.js","../src/error-reporting/request-details.js","../src/frontend-model-resource/base-resource.js","../src/frontend-model-resource/velocious-attachment-resource.js","../src/frontend-models/base.js","../src/frontend-models/built-in-resources.js","../src/frontend-models/clear-pending-debounced-callback.js","../src/frontend-models/event-hook-models.js","../src/frontend-models/model-registry.js","../src/frontend-models/outgoing-event-buffer.js","../src/frontend-models/preloader.js","../src/frontend-models/query.js","../src/frontend-models/resource-config-validation.js","../src/frontend-models/resource-definition.js","../src/frontend-models/transport-deadline.js","../src/frontend-models/transport-serialization.js","../src/frontend-models/use-created-event.js","../src/frontend-models/use-destroyed-event.js","../src/frontend-models/use-model-class-event.js","../src/frontend-models/use-updated-event.js","../src/frontend-models/websocket-channel.js","../src/frontend-models/websocket-publishers.js","../src/http-client/header.js","../src/http-client/index.js","../src/http-client/request.js","../src/http-client/response.js","../src/http-client/websocket-client.js","../src/http-client/websocket-url-from-http-base.js","../src/http-server/client-delivery-queue.js","../src/http-server/cookie.js","../src/http-server/development-reloader.js","../src/http-server/index.js","../src/http-server/remote-address.js","../src/http-server/server-client.js","../src/http-server/server-lock.js","../src/http-server/websocket-channel-subscribers.js","../src/http-server/websocket-channel.js","../src/http-server/websocket-connection.js","../src/http-server/websocket-event-log-store.js","../src/http-server/websocket-events-host.js","../src/http-server/websocket-events.js","../src/http-server/client/index.js","../src/http-server/client/params-to-object.js","../src/http-server/client/request-parser.js","../src/http-server/client/request-runner.js","../src/http-server/client/request-timing.js","../src/http-server/client/request.js","../src/http-server/client/response-compression.js","../src/http-server/client/response.js","../src/http-server/client/websocket-request.js","../src/http-server/client/websocket-session.js","../src/http-server/client/request-buffer/form-data-part.js","../src/http-server/client/request-buffer/header.js","../src/http-server/client/request-buffer/index.js","../src/http-server/client/uploaded-file/memory-uploaded-file.js","../src/http-server/client/uploaded-file/temporary-uploaded-file.js","../src/http-server/client/uploaded-file/uploaded-file.js","../src/http-server/worker-handler/channel-subscriber-dispatch.js","../src/http-server/worker-handler/in-process.js","../src/http-server/worker-handler/index.js","../src/http-server/worker-handler/worker-script.js","../src/http-server/worker-handler/worker-thread.js","../src/jobs/mail-delivery.js","../src/jobs/prune-terminal-background-jobs.js","../src/logger/base-logger.js","../src/logger/console-logger.js","../src/logger/file-logger.js","../src/logger/outputs/array-output.js","../src/logger/outputs/console-output.js","../src/logger/outputs/file-output.js","../src/logger/outputs/stdout-output.js","../src/mailer/base.js","../src/mailer/delivery-operation-store.js","../src/mailer/delivery-operation.js","../src/mailer/delivery.js","../src/mailer/index.js","../src/mailer/backends/resend-smtp.js","../src/mailer/backends/smtp.js","../src/packages/velocious-package.js","../src/plugins/sqljs-wasm-route-controller.js","../src/plugins/sqljs-wasm-route.js","../src/routes/app-routes.js","../src/routes/base-route.js","../src/routes/basic-route.js","../src/routes/get-route.js","../src/routes/index.js","../src/routes/namespace-route.js","../src/routes/plugin-routes.js","../src/routes/post-route.js","../src/routes/resolver.js","../src/routes/resource-route.js","../src/routes/root-route.js","../src/routes/built-in/api-manifest/controller.js","../src/routes/built-in/debug/controller.js","../src/routes/built-in/errors/controller.js","../src/routes/hooks/frontend-model-command-route-hook.js","../src/sync/conflict-strategy.js","../src/sync/device-identity.js","../src/sync/local-mutation-log.js","../src/sync/offline-grant.js","../src/sync/peer-mutation-bundle.js","../src/sync/query-scope.js","../src/sync/server-change-feed.js","../src/sync/server-sequence-allocator.js","../src/sync/signed-sync-envelope-replay-service.js","../src/sync/stable-json.js","../src/sync/sync-api-client-types.js","../src/sync/sync-api-client.js","../src/sync/sync-api-controller.js","../src/sync/sync-change-fanout.js","../src/sync/sync-channel-name.js","../src/sync/sync-client-registry.js","../src/sync/sync-client-types.js","../src/sync/sync-client.js","../src/sync/sync-envelope-replay-service.js","../src/sync/sync-model-change-feed-service.js","../src/sync/sync-publish-suppression.js","../src/sync/sync-publisher-types.js","../src/sync/sync-publisher.js","../src/sync/sync-realtime-bridge.js","../src/sync/sync-replay-persisted-data.js","../src/sync/sync-replay-upsert-applier.js","../src/sync/sync-resource-base.js","../src/sync/sync-scope-attributes.js","../src/sync/sync-scope-store.js","../src/sync/sync-upstream-importer.js","../src/sync/sync-websocket-channel.js","../src/tenants/default-tenant-database-provisioning.js","../src/tenants/frontend-tenant-sqlite-lifecycle.js","../src/tenants/tenant-aggregator.js","../src/tenants/tenant-handle.js","../src/tenants/tenant-iterator.js","../src/tenants/tenant-model-scope.js","../src/tenants/tenant.js","../src/testing/base-expect.js","../src/testing/browser-frontend-model-event-hook-scenarios.js","../src/testing/browser-test-app.js","../src/testing/browser-use-database-hook-scenarios.js","../src/testing/expect-to-change.js","../src/testing/expect-utils.js","../src/testing/expect.js","../src/testing/request-client.js","../src/testing/shared-transaction-broker-client.js","../src/testing/shared-transaction-broker.js","../src/testing/shared-transaction-codec.js","../src/testing/shared-transaction-connection-coordinator.js","../src/testing/shared-transaction-proxy-driver.js","../src/testing/test-files-finder.js","../src/testing/test-filter-parser.js","../src/testing/test-profile-activity.js","../src/testing/test-profile-context.js","../src/testing/test-profile-output.js","../src/testing/test-profiler.js","../src/testing/test-runner.js","../src/testing/test-suite-splitter.js","../src/testing/test-transaction-session.js","../src/testing/test.js","../src/testing/timing-manifest.js","../src/testing/wait-for-event.js","../src/testing/factory/association-declaration.js","../src/testing/factory/declarations.js","../src/testing/factory/definition-builder.js","../src/testing/factory/errors.js","../src/testing/factory/evaluation-context.js","../src/testing/factory/events.js","../src/testing/factory/factory-definition.js","../src/testing/factory/factory-registry.js","../src/testing/factory/factory-runner.js","../src/testing/factory/index.js","../src/testing/factory/linter.js","../src/testing/factory/model-contract.js","../src/testing/factory/sequence.js","../src/testing/factory/trait-definition.js","../src/testing/factory/node/definition-reload-policy.js","../src/testing/factory/node/load-definitions.js","../src/testing/factory/strategies/attributes-for.js","../src/testing/factory/strategies/base.js","../src/testing/factory/strategies/build.js","../src/testing/factory/strategies/create.js","../src/types/external-modules.d.ts","../src/utils/backtrace-cleaner-node.js","../src/utils/backtrace-cleaner.js","../src/utils/bearer-token.js","../src/utils/deburr-column-name.js","../src/utils/event-emitter.js","../src/utils/file-exists.js","../src/utils/format-value.js","../src/utils/is-date.js","../src/utils/model-scope.js","../src/utils/mount-prefix.js","../src/utils/nest-callbacks.js","../src/utils/plain-object.js","../src/utils/ransack.js","../src/utils/rest-args-error.js","../src/utils/sha256-hex.js","../src/utils/shutdown-lifecycle.js","../src/utils/singularize-model-name.js","../src/utils/split-sql-statements.js","../src/utils/stable-json.js","../src/utils/to-import-specifier.js","../src/utils/utf8-byte-length.js","../src/utils/with-tracked-stack-async-hooks.js","../src/utils/with-tracked-stack.js"],"packageJsons":["../node_modules/@azure/abort-controller/dist/commonjs/package.json","../node_modules/@azure/abort-controller/package.json","../node_modules/@azure/core-auth/dist/commonjs/package.json","../node_modules/@azure/core-auth/package.json","../node_modules/@azure/core-util/dist/commonjs/package.json","../node_modules/@azure/core-util/package.json","../node_modules/@js-temporal/polyfill/package.json","../node_modules/@types/ejs/package.json","../node_modules/@types/escape-string-regexp/package.json","../node_modules/@types/mssql/package.json","../node_modules/@types/mysql/package.json","../node_modules/@types/node/package.json","../node_modules/@types/pg/package.json","../node_modules/@types/proxy-addr/package.json","../node_modules/@types/react-dom/package.json","../node_modules/@types/react/package.json","../node_modules/@types/strftime/package.json","../node_modules/@types/ws/package.json","../node_modules/awaitery/package.json","../node_modules/bcryptjs/package.json","../node_modules/better-localstorage/package.json","../node_modules/buffer/package.json","../node_modules/csstype/package.json","../node_modules/debounce/package.json","../node_modules/diggerize/package.json","../node_modules/ejs/package.json","../node_modules/env-sense/package.json","../node_modules/epic-locks/package.json","../node_modules/escape-string-regexp/package.json","../node_modules/eventemitter3/package.json","../node_modules/events/package.json","../node_modules/expo-localization/package.json","../node_modules/gettext-universal/package.json","../node_modules/incorporator/package.json","../node_modules/inflection/package.json","../node_modules/is-plain-object/package.json","../node_modules/mssql/package.json","../node_modules/mysql/package.json","../node_modules/node-gyp/package.json","../node_modules/pg-protocol/package.json","../node_modules/pg-types/package.json","../node_modules/pg/package.json","../node_modules/picocolors/package.json","../node_modules/process/package.json","../node_modules/prop-types/package.json","../node_modules/proxy-addr/package.json","../node_modules/punycode/package.json","../node_modules/pure-uuid/package.json","../node_modules/react-dom/package.json","../node_modules/react/package.json","../node_modules/require-context/package.json","../node_modules/scoundrel-remote-eval/package.json","../node_modules/selenium-webdriver/package.json","../node_modules/set-state-compare/package.json","../node_modules/smtp-connection/package.json","../node_modules/snapreq/package.json","../node_modules/sql-escape-string/package.json","../node_modules/sql.js/package.json","../node_modules/sqlite/package.json","../node_modules/sqlite3/package.json","../node_modules/strftime/package.json","../node_modules/string_decoder/package.json","../node_modules/system-testing/package.json","../node_modules/tarn/package.json","../node_modules/tedious/package.json","../node_modules/typanic/package.json","../node_modules/undici-types/package.json","../node_modules/ws/package.json","../package.json"],"missingPackageJsons":["../node_modules/@types/assert/package.json","../node_modules/@types/assert/strict/package.json","../node_modules/@types/async_hooks/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/expo-sqlite/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/incorporator/package.json","../node_modules/@types/inspector/package.json","../node_modules/@types/inspector/promises/package.json","../node_modules/@types/is-plain-object/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/pg/lib/package.json","../node_modules/@types/process/package.json","../node_modules/@types/punycode/package.json","../node_modules/@types/querystring/package.json","../node_modules/@types/react-dom/client/package.json","../node_modules/@types/readline/package.json","../node_modules/@types/readline/promises/package.json","../node_modules/@types/repl/package.json","../node_modules/@types/require-context/package.json","../node_modules/@types/smtp-connection/package.json","../node_modules/@types/sql-escape-string/package.json","../node_modules/@types/sql.js/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/appium/package.json","../node_modules/assert/package.json","../node_modules/assert/strict/package.json","../node_modules/async_hooks/package.json","../node_modules/awaitery/build/package.json","../node_modules/awaitery/build/timeout.js/package.json","../node_modules/awaitery/build/wait.js/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/dgram/package.json","../node_modules/diagnostics_channel/package.json","../node_modules/diggerize/build/package.json","../node_modules/dns/package.json","../node_modules/dns/promises/package.json","../node_modules/domain/package.json","../node_modules/env-sense/build/package.json","../node_modules/env-sense/build/use-env-sense.js/package.json","../node_modules/epic-locks/build/mutex.js/package.json","../node_modules/epic-locks/build/package.json","../node_modules/expo-sqlite/package.json","../node_modules/fs/package.json","../node_modules/fs/promises/package.json","../node_modules/gettext-universal/build/package.json","../node_modules/gettext-universal/build/src/config.js/package.json","../node_modules/gettext-universal/build/src/package.json","../node_modules/gettext-universal/build/src/translate.js/package.json","../node_modules/http/package.json","../node_modules/http2/package.json","../node_modules/https/package.json","../node_modules/inflection/lib/package.json","../node_modules/inspector/package.json","../node_modules/inspector/promises/package.json","../node_modules/module/package.json","../node_modules/net/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/pg-protocol/dist/messages.js/package.json","../node_modules/pg-protocol/dist/package.json","../node_modules/querystring/package.json","../node_modules/react-dom/client/package.json","../node_modules/readline/package.json","../node_modules/readline/promises/package.json","../node_modules/repl/package.json","../node_modules/scoundrel-remote-eval/build/client/connections/package.json","../node_modules/scoundrel-remote-eval/build/client/connections/web-socket/index.js/package.json","../node_modules/scoundrel-remote-eval/build/client/connections/web-socket/package.json","../node_modules/scoundrel-remote-eval/build/client/index.js/package.json","../node_modules/scoundrel-remote-eval/build/client/package.json","../node_modules/scoundrel-remote-eval/build/package.json","../node_modules/set-state-compare/build/diff-utils.js/package.json","../node_modules/set-state-compare/build/package.json","../node_modules/snapreq/build/package.json","../node_modules/snapreq/build/websocket/package.json","../node_modules/snapreq/websocket/package.json","../node_modules/sqlite/build/package.json","../node_modules/sqlite3/lib/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/system-testing/build/package.json","../node_modules/system-testing/build/system-test-browser-helper.js/package.json","../node_modules/system-testing/node_modules/eventemitter3/package.json","../node_modules/system-testing/node_modules/scoundrel-remote-eval/build/client/connections/web-socket/index.js/package.json","../node_modules/system-testing/node_modules/scoundrel-remote-eval/build/client/index.js/package.json","../node_modules/system-testing/node_modules/scoundrel-remote-eval/package.json","../node_modules/tarn/dist/Pool/package.json","../node_modules/tarn/dist/package.json","../node_modules/tedious/lib/always-encrypted/package.json","../node_modules/tedious/lib/data-types/package.json","../node_modules/tedious/lib/package.json","../node_modules/tedious/lib/token/package.json","../node_modules/tedious/node_modules/@azure/core-auth/package.json","../node_modules/tedious/node_modules/events/package.json","../node_modules/tedious/node_modules/net/package.json","../node_modules/tedious/node_modules/stream/package.json","../node_modules/tedious/node_modules/tls/package.json","../node_modules/timers/package.json","../node_modules/timers/promises/package.json","../node_modules/tls/package.json","../node_modules/trace_events/package.json","../node_modules/tty/package.json","../node_modules/typanic/build/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/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":["../index.js","../bin/velocious.js","../src/application.js","../src/configuration-resolver.js","../src/configuration-types.js","../src/configuration.js","../src/controller.js","../src/current-configuration.js","../src/current.js","../src/error-logger.js","../src/frontend-model-controller.js","../src/initializer.js","../src/logger.js","../src/mailer.js","../src/record-payload-values.js","../src/time-zone.js","../src/velocious-error.js","../src/authorization/ability.js","../src/authorization/base-resource.js","../src/background-jobs/adapter-client.js","../src/background-jobs/adapter.js","../src/background-jobs/client.js","../src/background-jobs/cron-expression.js","../src/background-jobs/forked-runner-child.js","../src/background-jobs/job-record.js","../src/background-jobs/job-registry.js","../src/background-jobs/job-runner.js","../src/background-jobs/job-semantics.js","../src/background-jobs/job.js","../src/background-jobs/json-socket.js","../src/background-jobs/local-adapter.js","../src/background-jobs/local-dispatcher.js","../src/background-jobs/local-job-registry.js","../src/background-jobs/local-store.js","../src/background-jobs/main.js","../src/background-jobs/normalize-error.js","../src/background-jobs/perform-job.js","../src/background-jobs/platform-job.js","../src/background-jobs/pooled-runner-broker-identity.js","../src/background-jobs/pooled-runner-child.js","../src/background-jobs/reschedule-signal.js","../src/background-jobs/runner-graceful-shutdown.js","../src/background-jobs/runner-process-title.js","../src/background-jobs/runtime.js","../src/background-jobs/scheduler.js","../src/background-jobs/socket-request.js","../src/background-jobs/sql-adapter.js","../src/background-jobs/status-reporter.js","../src/background-jobs/store.js","../src/background-jobs/types.js","../src/background-jobs/worker.js","../src/background-jobs/web/authorization.js","../src/background-jobs/web/controller.js","../src/background-jobs/web/counts-channel.js","../src/background-jobs/web/index.js","../src/background-jobs/web/path-matcher.js","../src/background-jobs/web/registry.js","../src/beacon/client.js","../src/beacon/in-process-broker.js","../src/beacon/in-process-client.js","../src/beacon/server.js","../src/beacon/types.js","../src/cli/base-command.js","../src/cli/browser-cli.js","../src/cli/command-arguments.js","../src/cli/index.js","../src/cli/tenant-database-command-helper.js","../src/cli/use-browser-cli.js","../src/cli/commands/background-jobs-main.js","../src/cli/commands/background-jobs-runner.js","../src/cli/commands/background-jobs-worker.js","../src/cli/commands/beacon.js","../src/cli/commands/console.js","../src/cli/commands/init.js","../src/cli/commands/routes.js","../src/cli/commands/run-script.js","../src/cli/commands/runner.js","../src/cli/commands/server.js","../src/cli/commands/test.js","../src/cli/commands/db/base-command.js","../src/cli/commands/db/create.js","../src/cli/commands/db/drop.js","../src/cli/commands/db/migrate.js","../src/cli/commands/db/reset.js","../src/cli/commands/db/rollback.js","../src/cli/commands/db/seed.js","../src/cli/commands/db/schema/dump.js","../src/cli/commands/db/schema/load.js","../src/cli/commands/db/tenants/check.js","../src/cli/commands/db/tenants/create.js","../src/cli/commands/db/tenants/drop.js","../src/cli/commands/db/tenants/migrate.js","../src/cli/commands/db/tenants/migrations/pending.js","../src/cli/commands/destroy/migration.js","../src/cli/commands/generate/base-models.js","../src/cli/commands/generate/frontend-models.js","../src/cli/commands/generate/migration.js","../src/cli/commands/generate/model.js","../src/cli/commands/lint/relationships.js","../src/cli/commands/test/timing-manifest/merge.js","../src/database/advisory-lock-runner.js","../src/database/annotations-async-hooks.js","../src/database/annotations.js","../src/database/column-types.js","../src/database/datetime-storage.js","../src/database/generation-context.js","../src/database/handler.js","../src/database/initializer-from-require-context.js","../src/database/live-query.js","../src/database/migrations-ledger.js","../src/database/migrator.js","../src/database/operation-connection.js","../src/database/operation-lease.js","../src/database/operation.js","../src/database/query-aborted-error.js","../src/database/record-changes.js","../src/database/structure-sql-loader.js","../src/database/use-database.js","../src/database/use-live-query.js","../src/database/drivers/base-column.js","../src/database/drivers/base-columns-index.js","../src/database/drivers/base-foreign-key.js","../src/database/drivers/base-table.js","../src/database/drivers/base.js","../src/database/drivers/index-metadata.js","../src/database/drivers/mssql/column.js","../src/database/drivers/mssql/columns-index.js","../src/database/drivers/mssql/connect-connection.js","../src/database/drivers/mssql/foreign-key.js","../src/database/drivers/mssql/index.js","../src/database/drivers/mssql/options.js","../src/database/drivers/mssql/query-parser.js","../src/database/drivers/mssql/structure-sql.js","../src/database/drivers/mssql/table.js","../src/database/drivers/mssql/sql/alter-table.js","../src/database/drivers/mssql/sql/create-database.js","../src/database/drivers/mssql/sql/create-index.js","../src/database/drivers/mssql/sql/create-table.js","../src/database/drivers/mssql/sql/delete.js","../src/database/drivers/mssql/sql/drop-database.js","../src/database/drivers/mssql/sql/drop-table.js","../src/database/drivers/mssql/sql/insert.js","../src/database/drivers/mssql/sql/remove-index.js","../src/database/drivers/mssql/sql/update.js","../src/database/drivers/mssql/sql/upsert.js","../src/database/drivers/mysql/column.js","../src/database/drivers/mysql/columns-index.js","../src/database/drivers/mysql/deadlock-diagnostic-parser.js","../src/database/drivers/mysql/foreign-key.js","../src/database/drivers/mysql/index.js","../src/database/drivers/mysql/options.js","../src/database/drivers/mysql/query-parser.js","../src/database/drivers/mysql/query-stream.js","../src/database/drivers/mysql/query.js","../src/database/drivers/mysql/structure-sql.js","../src/database/drivers/mysql/table.js","../src/database/drivers/mysql/sql/alter-table.js","../src/database/drivers/mysql/sql/create-database.js","../src/database/drivers/mysql/sql/create-index.js","../src/database/drivers/mysql/sql/create-table.js","../src/database/drivers/mysql/sql/delete.js","../src/database/drivers/mysql/sql/drop-database.js","../src/database/drivers/mysql/sql/drop-table.js","../src/database/drivers/mysql/sql/insert.js","../src/database/drivers/mysql/sql/remove-index.js","../src/database/drivers/mysql/sql/update.js","../src/database/drivers/mysql/sql/upsert.js","../src/database/drivers/pgsql/column.js","../src/database/drivers/pgsql/columns-index.js","../src/database/drivers/pgsql/foreign-key.js","../src/database/drivers/pgsql/index.js","../src/database/drivers/pgsql/options.js","../src/database/drivers/pgsql/query-parser.js","../src/database/drivers/pgsql/structure-sql.js","../src/database/drivers/pgsql/table.js","../src/database/drivers/pgsql/sql/alter-table.js","../src/database/drivers/pgsql/sql/create-database.js","../src/database/drivers/pgsql/sql/create-index.js","../src/database/drivers/pgsql/sql/create-table.js","../src/database/drivers/pgsql/sql/delete.js","../src/database/drivers/pgsql/sql/drop-database.js","../src/database/drivers/pgsql/sql/drop-table.js","../src/database/drivers/pgsql/sql/insert.js","../src/database/drivers/pgsql/sql/remove-index.js","../src/database/drivers/pgsql/sql/update.js","../src/database/drivers/pgsql/sql/upsert.js","../src/database/drivers/sqlite/base.js","../src/database/drivers/sqlite/column.js","../src/database/drivers/sqlite/columns-index.js","../src/database/drivers/sqlite/connection-sql-js.js","../src/database/drivers/sqlite/foreign-key.js","../src/database/drivers/sqlite/index.js","../src/database/drivers/sqlite/index.native.js","../src/database/drivers/sqlite/index.web.js","../src/database/drivers/sqlite/options.js","../src/database/drivers/sqlite/query-parser.js","../src/database/drivers/sqlite/query.js","../src/database/drivers/sqlite/query.native.js","../src/database/drivers/sqlite/query.web.js","../src/database/drivers/sqlite/structure-sql.js","../src/database/drivers/sqlite/table-rebuilder.js","../src/database/drivers/sqlite/table.js","../src/database/drivers/sqlite/web-persistence.js","../src/database/drivers/sqlite/sql/alter-table.js","../src/database/drivers/sqlite/sql/create-index.js","../src/database/drivers/sqlite/sql/create-table.js","../src/database/drivers/sqlite/sql/delete.js","../src/database/drivers/sqlite/sql/drop-table.js","../src/database/drivers/sqlite/sql/insert.js","../src/database/drivers/sqlite/sql/remove-index.js","../src/database/drivers/sqlite/sql/update.js","../src/database/drivers/sqlite/sql/upsert.js","../src/database/drivers/structure-sql/utils.js","../src/database/migration/change-table.js","../src/database/migration/index.js","../src/database/migrator/files-finder.js","../src/database/migrator/types.js","../src/database/pool/async-tracked-multi-connection.js","../src/database/pool/base-methods-forward.js","../src/database/pool/base.js","../src/database/pool/single-multi-use.js","../src/database/query/alter-table-base.js","../src/database/query/base.js","../src/database/query/create-database-base.js","../src/database/query/create-index-base.js","../src/database/query/create-table-base.js","../src/database/query/delete-base.js","../src/database/query/drop-database-base.js","../src/database/query/drop-table-base.js","../src/database/query/from-base.js","../src/database/query/from-plain.js","../src/database/query/from-table.js","../src/database/query/index.js","../src/database/query/insert-base.js","../src/database/query/join-base.js","../src/database/query/join-object.js","../src/database/query/join-plain.js","../src/database/query/join-tracker.js","../src/database/query/model-class-query.js","../src/database/query/order-base.js","../src/database/query/order-column.js","../src/database/query/order-plain.js","../src/database/query/preloader.js","../src/database/query/query-data.js","../src/database/query/remove-index-base.js","../src/database/query/select-base.js","../src/database/query/select-plain.js","../src/database/query/select-table-and-column.js","../src/database/query/update-base.js","../src/database/query/upsert-base.js","../src/database/query/where-base.js","../src/database/query/where-combinator.js","../src/database/query/where-hash.js","../src/database/query/where-model-class-hash.js","../src/database/query/where-not.js","../src/database/query/where-plain.js","../src/database/query/with-count.js","../src/database/query/preloader/belongs-to.js","../src/database/query/preloader/ensure-model-class-initialized.js","../src/database/query/preloader/has-many.js","../src/database/query/preloader/has-one.js","../src/database/query/preloader/query-for-model.js","../src/database/query/preloader/selection.js","../src/database/query-parser/base-query-parser.js","../src/database/query-parser/from-parser.js","../src/database/query-parser/group-parser.js","../src/database/query-parser/joins-parser.js","../src/database/query-parser/limit-parser.js","../src/database/query-parser/options.js","../src/database/query-parser/order-parser.js","../src/database/query-parser/select-parser.js","../src/database/query-parser/where-parser.js","../src/database/record/acts-as-list.js","../src/database/record/auditing.js","../src/database/record/counter-cache-magnitude.js","../src/database/record/index.js","../src/database/record/record-not-found-error.js","../src/database/record/state-machine.js","../src/database/record/user-module.js","../src/database/record/validation-messages.js","../src/database/record/attachments/attachment-record.js","../src/database/record/attachments/download.js","../src/database/record/attachments/handle.js","../src/database/record/attachments/normalize-input.js","../src/database/record/attachments/store.js","../src/database/record/attachments/storage-drivers/filesystem.js","../src/database/record/attachments/storage-drivers/native.js","../src/database/record/attachments/storage-drivers/s3.js","../src/database/record/instance-relationships/base.js","../src/database/record/instance-relationships/belongs-to.js","../src/database/record/instance-relationships/has-many.js","../src/database/record/instance-relationships/has-one.js","../src/database/record/relationships/base.js","../src/database/record/relationships/belongs-to.js","../src/database/record/relationships/has-many.js","../src/database/record/relationships/has-one.js","../src/database/record/validators/base.js","../src/database/record/validators/format.js","../src/database/record/validators/length.js","../src/database/record/validators/presence.js","../src/database/record/validators/uniqueness.js","../src/database/table-data/index.js","../src/database/table-data/table-column.js","../src/database/table-data/table-foreign-key.js","../src/database/table-data/table-index.js","../src/database/table-data/table-reference.js","../src/database/tenants/data-copier.js","../src/database/tenants/migration-pending-inspector.js","../src/database/tenants/schema-cloner.js","../src/database/tenants/tenant-table-plan.js","../src/environment-handlers/base.js","../src/environment-handlers/browser.js","../src/environment-handlers/node.js","../src/environment-handlers/node/attachment-path-source.js","../src/environment-handlers/node/source-peer-package.js","../src/environment-handlers/node/cli/commands/background-jobs-main.js","../src/environment-handlers/node/cli/commands/background-jobs-runner.js","../src/environment-handlers/node/cli/commands/background-jobs-worker.js","../src/environment-handlers/node/cli/commands/beacon.js","../src/environment-handlers/node/cli/commands/cli-command-context.js","../src/environment-handlers/node/cli/commands/console.js","../src/environment-handlers/node/cli/commands/init.js","../src/environment-handlers/node/cli/commands/routes.js","../src/environment-handlers/node/cli/commands/run-script.js","../src/environment-handlers/node/cli/commands/runner.js","../src/environment-handlers/node/cli/commands/server.js","../src/environment-handlers/node/cli/commands/test.js","../src/environment-handlers/node/cli/commands/db/seed.js","../src/environment-handlers/node/cli/commands/db/schema/dump.js","../src/environment-handlers/node/cli/commands/db/schema/load.js","../src/environment-handlers/node/cli/commands/destroy/migration.js","../src/environment-handlers/node/cli/commands/generate/base-models.js","../src/environment-handlers/node/cli/commands/generate/frontend-models.js","../src/environment-handlers/node/cli/commands/generate/generated-file-banner.js","../src/environment-handlers/node/cli/commands/generate/migration.js","../src/environment-handlers/node/cli/commands/generate/model.js","../src/environment-handlers/node/cli/commands/lint/relationships.js","../src/environment-handlers/node/cli/commands/test/timing-manifest/merge.js","../src/error-reporting/request-details.js","../src/frontend-model-resource/base-resource.js","../src/frontend-model-resource/velocious-attachment-resource.js","../src/frontend-models/base.js","../src/frontend-models/built-in-resources.js","../src/frontend-models/clear-pending-debounced-callback.js","../src/frontend-models/event-hook-models.js","../src/frontend-models/model-registry.js","../src/frontend-models/outgoing-event-buffer.js","../src/frontend-models/preloader.js","../src/frontend-models/query.js","../src/frontend-models/resource-config-validation.js","../src/frontend-models/resource-definition.js","../src/frontend-models/transport-deadline.js","../src/frontend-models/transport-serialization.js","../src/frontend-models/use-created-event.js","../src/frontend-models/use-destroyed-event.js","../src/frontend-models/use-model-class-event.js","../src/frontend-models/use-updated-event.js","../src/frontend-models/websocket-channel.js","../src/frontend-models/websocket-publishers.js","../src/http-client/header.js","../src/http-client/index.js","../src/http-client/request.js","../src/http-client/response.js","../src/http-client/websocket-client.js","../src/http-client/websocket-url-from-http-base.js","../src/http-server/client-delivery-queue.js","../src/http-server/cookie.js","../src/http-server/development-reloader.js","../src/http-server/index.js","../src/http-server/remote-address.js","../src/http-server/server-client.js","../src/http-server/server-lock.js","../src/http-server/websocket-channel-subscribers.js","../src/http-server/websocket-channel.js","../src/http-server/websocket-connection.js","../src/http-server/websocket-event-log-store.js","../src/http-server/websocket-events-host.js","../src/http-server/websocket-events.js","../src/http-server/client/index.js","../src/http-server/client/params-to-object.js","../src/http-server/client/request-parser.js","../src/http-server/client/request-runner.js","../src/http-server/client/request-timing.js","../src/http-server/client/request.js","../src/http-server/client/response-compression.js","../src/http-server/client/response.js","../src/http-server/client/websocket-request.js","../src/http-server/client/websocket-session.js","../src/http-server/client/request-buffer/form-data-part.js","../src/http-server/client/request-buffer/header.js","../src/http-server/client/request-buffer/index.js","../src/http-server/client/uploaded-file/memory-uploaded-file.js","../src/http-server/client/uploaded-file/temporary-uploaded-file.js","../src/http-server/client/uploaded-file/uploaded-file.js","../src/http-server/worker-handler/channel-subscriber-dispatch.js","../src/http-server/worker-handler/in-process.js","../src/http-server/worker-handler/index.js","../src/http-server/worker-handler/worker-script.js","../src/http-server/worker-handler/worker-thread.js","../src/jobs/mail-delivery.js","../src/jobs/prune-terminal-background-jobs.js","../src/logger/base-logger.js","../src/logger/console-logger.js","../src/logger/file-logger.js","../src/logger/outputs/array-output.js","../src/logger/outputs/console-output.js","../src/logger/outputs/file-output.js","../src/logger/outputs/stdout-output.js","../src/mailer/base.js","../src/mailer/delivery-operation-store.js","../src/mailer/delivery-operation.js","../src/mailer/delivery.js","../src/mailer/index.js","../src/mailer/backends/resend-smtp.js","../src/mailer/backends/smtp.js","../src/packages/velocious-package.js","../src/plugins/sqljs-wasm-route-controller.js","../src/plugins/sqljs-wasm-route.js","../src/routes/app-routes.js","../src/routes/base-route.js","../src/routes/basic-route.js","../src/routes/get-route.js","../src/routes/index.js","../src/routes/namespace-route.js","../src/routes/plugin-routes.js","../src/routes/post-route.js","../src/routes/resolver.js","../src/routes/resource-route.js","../src/routes/root-route.js","../src/routes/built-in/api-manifest/controller.js","../src/routes/built-in/debug/controller.js","../src/routes/built-in/errors/controller.js","../src/routes/hooks/frontend-model-command-route-hook.js","../src/sync/conflict-strategy.js","../src/sync/device-identity.js","../src/sync/local-mutation-log.js","../src/sync/offline-grant.js","../src/sync/peer-mutation-bundle.js","../src/sync/query-scope.js","../src/sync/server-change-feed.js","../src/sync/server-sequence-allocator.js","../src/sync/signed-sync-envelope-replay-service.js","../src/sync/stable-json.js","../src/sync/sync-api-client-types.js","../src/sync/sync-api-client.js","../src/sync/sync-api-controller.js","../src/sync/sync-change-fanout.js","../src/sync/sync-channel-name.js","../src/sync/sync-client-registry.js","../src/sync/sync-client-types.js","../src/sync/sync-client.js","../src/sync/sync-envelope-replay-service.js","../src/sync/sync-model-change-feed-service.js","../src/sync/sync-publish-suppression.js","../src/sync/sync-publisher-types.js","../src/sync/sync-publisher.js","../src/sync/sync-realtime-bridge.js","../src/sync/sync-replay-persisted-data.js","../src/sync/sync-replay-upsert-applier.js","../src/sync/sync-resource-base.js","../src/sync/sync-scope-attributes.js","../src/sync/sync-scope-store.js","../src/sync/sync-upstream-importer.js","../src/sync/sync-websocket-channel.js","../src/tenants/default-tenant-database-provisioning.js","../src/tenants/frontend-tenant-sqlite-lifecycle.js","../src/tenants/tenant-aggregator.js","../src/tenants/tenant-handle.js","../src/tenants/tenant-iterator.js","../src/tenants/tenant-model-scope.js","../src/tenants/tenant.js","../src/testing/base-expect.js","../src/testing/browser-frontend-model-event-hook-scenarios.js","../src/testing/browser-test-app.js","../src/testing/browser-use-database-hook-scenarios.js","../src/testing/expect-to-change.js","../src/testing/expect-utils.js","../src/testing/expect.js","../src/testing/request-client.js","../src/testing/shared-transaction-broker-client.js","../src/testing/shared-transaction-broker.js","../src/testing/shared-transaction-codec.js","../src/testing/shared-transaction-connection-coordinator.js","../src/testing/shared-transaction-proxy-driver.js","../src/testing/test-files-finder.js","../src/testing/test-filter-parser.js","../src/testing/test-profile-activity.js","../src/testing/test-profile-context.js","../src/testing/test-profile-output.js","../src/testing/test-profiler.js","../src/testing/test-runner.js","../src/testing/test-suite-splitter.js","../src/testing/test-transaction-session.js","../src/testing/test.js","../src/testing/timing-manifest.js","../src/testing/factory/association-declaration.js","../src/testing/factory/declarations.js","../src/testing/factory/definition-builder.js","../src/testing/factory/errors.js","../src/testing/factory/evaluation-context.js","../src/testing/factory/events.js","../src/testing/factory/factory-definition.js","../src/testing/factory/factory-registry.js","../src/testing/factory/factory-runner.js","../src/testing/factory/index.js","../src/testing/factory/linter.js","../src/testing/factory/model-contract.js","../src/testing/factory/sequence.js","../src/testing/factory/trait-definition.js","../src/testing/factory/node/definition-reload-policy.js","../src/testing/factory/node/load-definitions.js","../src/testing/factory/strategies/attributes-for.js","../src/testing/factory/strategies/base.js","../src/testing/factory/strategies/build.js","../src/testing/factory/strategies/create.js","../src/types/external-modules.d.ts","../src/utils/backtrace-cleaner-node.js","../src/utils/backtrace-cleaner.js","../src/utils/bearer-token.js","../src/utils/deburr-column-name.js","../src/utils/event-emitter.js","../src/utils/file-exists.js","../src/utils/format-value.js","../src/utils/is-date.js","../src/utils/model-scope.js","../src/utils/mount-prefix.js","../src/utils/nest-callbacks.js","../src/utils/plain-object.js","../src/utils/ransack.js","../src/utils/rest-args-error.js","../src/utils/sha256-hex.js","../src/utils/shutdown-lifecycle.js","../src/utils/singularize-model-name.js","../src/utils/split-sql-statements.js","../src/utils/stable-json.js","../src/utils/to-import-specifier.js","../src/utils/utf8-byte-length.js","../src/utils/with-tracked-stack-async-hooks.js","../src/utils/with-tracked-stack.js"],"packageJsons":["../node_modules/@azure/abort-controller/dist/commonjs/package.json","../node_modules/@azure/abort-controller/package.json","../node_modules/@azure/core-auth/dist/commonjs/package.json","../node_modules/@azure/core-auth/package.json","../node_modules/@azure/core-util/dist/commonjs/package.json","../node_modules/@azure/core-util/package.json","../node_modules/@js-temporal/polyfill/package.json","../node_modules/@types/ejs/package.json","../node_modules/@types/escape-string-regexp/package.json","../node_modules/@types/mssql/package.json","../node_modules/@types/mysql/package.json","../node_modules/@types/node/package.json","../node_modules/@types/pg/package.json","../node_modules/@types/proxy-addr/package.json","../node_modules/@types/react-dom/package.json","../node_modules/@types/react/package.json","../node_modules/@types/strftime/package.json","../node_modules/@types/ws/package.json","../node_modules/@velocious/testing/package.json","../node_modules/awaitery/package.json","../node_modules/bcryptjs/package.json","../node_modules/better-localstorage/package.json","../node_modules/buffer/package.json","../node_modules/csstype/package.json","../node_modules/debounce/package.json","../node_modules/diggerize/package.json","../node_modules/ejs/package.json","../node_modules/env-sense/package.json","../node_modules/epic-locks/package.json","../node_modules/escape-string-regexp/package.json","../node_modules/eventemitter3/package.json","../node_modules/events/package.json","../node_modules/expo-localization/package.json","../node_modules/gettext-universal/package.json","../node_modules/incorporator/package.json","../node_modules/inflection/package.json","../node_modules/is-plain-object/package.json","../node_modules/mssql/package.json","../node_modules/mysql/package.json","../node_modules/node-gyp/package.json","../node_modules/pg-protocol/package.json","../node_modules/pg-types/package.json","../node_modules/pg/package.json","../node_modules/picocolors/package.json","../node_modules/process/package.json","../node_modules/prop-types/package.json","../node_modules/proxy-addr/package.json","../node_modules/punycode/package.json","../node_modules/pure-uuid/package.json","../node_modules/react-dom/package.json","../node_modules/react/package.json","../node_modules/require-context/package.json","../node_modules/scoundrel-remote-eval/package.json","../node_modules/selenium-webdriver/package.json","../node_modules/set-state-compare/package.json","../node_modules/smtp-connection/package.json","../node_modules/snapreq/package.json","../node_modules/sql-escape-string/package.json","../node_modules/sql.js/package.json","../node_modules/sqlite/package.json","../node_modules/sqlite3/package.json","../node_modules/strftime/package.json","../node_modules/string_decoder/package.json","../node_modules/system-testing/package.json","../node_modules/tarn/package.json","../node_modules/tedious/package.json","../node_modules/typanic/package.json","../node_modules/undici-types/package.json","../node_modules/ws/package.json","../package.json"],"missingPackageJsons":["../node_modules/@types/assert/package.json","../node_modules/@types/assert/strict/package.json","../node_modules/@types/async_hooks/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/expo-sqlite/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/incorporator/package.json","../node_modules/@types/inspector/package.json","../node_modules/@types/inspector/promises/package.json","../node_modules/@types/is-plain-object/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/pg/lib/package.json","../node_modules/@types/process/package.json","../node_modules/@types/punycode/package.json","../node_modules/@types/querystring/package.json","../node_modules/@types/react-dom/client/package.json","../node_modules/@types/readline/package.json","../node_modules/@types/readline/promises/package.json","../node_modules/@types/repl/package.json","../node_modules/@types/require-context/package.json","../node_modules/@types/smtp-connection/package.json","../node_modules/@types/sql-escape-string/package.json","../node_modules/@types/sql.js/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/@velocious/testing/build/package.json","../node_modules/appium/package.json","../node_modules/assert/package.json","../node_modules/assert/strict/package.json","../node_modules/async_hooks/package.json","../node_modules/awaitery/build/package.json","../node_modules/awaitery/build/timeout.js/package.json","../node_modules/awaitery/build/wait.js/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/dgram/package.json","../node_modules/diagnostics_channel/package.json","../node_modules/diggerize/build/package.json","../node_modules/dns/package.json","../node_modules/dns/promises/package.json","../node_modules/domain/package.json","../node_modules/env-sense/build/package.json","../node_modules/env-sense/build/use-env-sense.js/package.json","../node_modules/epic-locks/build/mutex.js/package.json","../node_modules/epic-locks/build/package.json","../node_modules/expo-sqlite/package.json","../node_modules/fs/package.json","../node_modules/fs/promises/package.json","../node_modules/gettext-universal/build/package.json","../node_modules/gettext-universal/build/src/config.js/package.json","../node_modules/gettext-universal/build/src/package.json","../node_modules/gettext-universal/build/src/translate.js/package.json","../node_modules/http/package.json","../node_modules/http2/package.json","../node_modules/https/package.json","../node_modules/inflection/lib/package.json","../node_modules/inspector/package.json","../node_modules/inspector/promises/package.json","../node_modules/module/package.json","../node_modules/net/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/pg-protocol/dist/messages.js/package.json","../node_modules/pg-protocol/dist/package.json","../node_modules/querystring/package.json","../node_modules/react-dom/client/package.json","../node_modules/readline/package.json","../node_modules/readline/promises/package.json","../node_modules/repl/package.json","../node_modules/scoundrel-remote-eval/build/client/connections/package.json","../node_modules/scoundrel-remote-eval/build/client/connections/web-socket/index.js/package.json","../node_modules/scoundrel-remote-eval/build/client/connections/web-socket/package.json","../node_modules/scoundrel-remote-eval/build/client/index.js/package.json","../node_modules/scoundrel-remote-eval/build/client/package.json","../node_modules/scoundrel-remote-eval/build/package.json","../node_modules/set-state-compare/build/diff-utils.js/package.json","../node_modules/set-state-compare/build/package.json","../node_modules/snapreq/build/package.json","../node_modules/snapreq/build/websocket/package.json","../node_modules/snapreq/websocket/package.json","../node_modules/sqlite/build/package.json","../node_modules/sqlite3/lib/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/system-testing/build/package.json","../node_modules/system-testing/build/system-test-browser-helper.js/package.json","../node_modules/system-testing/node_modules/eventemitter3/package.json","../node_modules/system-testing/node_modules/scoundrel-remote-eval/build/client/connections/web-socket/index.js/package.json","../node_modules/system-testing/node_modules/scoundrel-remote-eval/build/client/index.js/package.json","../node_modules/system-testing/node_modules/scoundrel-remote-eval/package.json","../node_modules/tarn/dist/Pool/package.json","../node_modules/tarn/dist/package.json","../node_modules/tedious/lib/always-encrypted/package.json","../node_modules/tedious/lib/data-types/package.json","../node_modules/tedious/lib/package.json","../node_modules/tedious/lib/token/package.json","../node_modules/tedious/node_modules/@azure/core-auth/package.json","../node_modules/tedious/node_modules/events/package.json","../node_modules/tedious/node_modules/net/package.json","../node_modules/tedious/node_modules/stream/package.json","../node_modules/tedious/node_modules/tls/package.json","../node_modules/timers/package.json","../node_modules/timers/promises/package.json","../node_modules/tls/package.json","../node_modules/trace_events/package.json","../node_modules/tty/package.json","../node_modules/typanic/build/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/vm/package.json","../node_modules/wasi/package.json","../node_modules/worker_threads/package.json","../node_modules/zlib/package.json"]}
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"velocious": "build/bin/velocious.js"
|
|
4
4
|
},
|
|
5
5
|
"name": "velocious",
|
|
6
|
-
"version": "1.0.
|
|
6
|
+
"version": "1.0.620",
|
|
7
7
|
"main": "build/index.js",
|
|
8
8
|
"types": "build/index.d.ts",
|
|
9
9
|
"files": [
|
|
@@ -64,6 +64,7 @@
|
|
|
64
64
|
"description": "",
|
|
65
65
|
"dependencies": {
|
|
66
66
|
"@js-temporal/polyfill": "^0.5.1",
|
|
67
|
+
"@velocious/testing": "0.0.0",
|
|
67
68
|
"awaitery": "^1.0.19",
|
|
68
69
|
"bcryptjs": "^3.0.2",
|
|
69
70
|
"better-localstorage": "^1.0.7",
|
package/src/configuration.js
CHANGED
|
@@ -3475,7 +3475,7 @@ export default class VelociousConfiguration {
|
|
|
3475
3475
|
* @returns {T} - Callback result.
|
|
3476
3476
|
*/
|
|
3477
3477
|
withoutCurrentConnectionContexts(callback) {
|
|
3478
|
-
let runCallback = callback
|
|
3478
|
+
let runCallback = () => this.getEnvironmentHandler().runWithoutSharedTransactionCoordinatorOwners(callback)
|
|
3479
3479
|
|
|
3480
3480
|
for (const pool of Object.values(this.databasePools)) {
|
|
3481
3481
|
if (!pool) continue
|
|
@@ -54,6 +54,14 @@ export default class VelociousEnvironmentHandlerBase {
|
|
|
54
54
|
*/
|
|
55
55
|
runWithSharedTransactionCoordinatorOwner(_connection, _owner, callback) { return callback() }
|
|
56
56
|
|
|
57
|
+
/**
|
|
58
|
+
* Runs work without inherited shared-transaction coordinator ownership.
|
|
59
|
+
* @template T
|
|
60
|
+
* @param {() => T} callback - Detached work.
|
|
61
|
+
* @returns {T} - Callback result.
|
|
62
|
+
*/
|
|
63
|
+
runWithoutSharedTransactionCoordinatorOwners(callback) { return callback() }
|
|
64
|
+
|
|
57
65
|
/**
|
|
58
66
|
* Runs work with test-profile attribution. Runtimes without async-context
|
|
59
67
|
* storage execute the callback without installing ambient attribution.
|
|
@@ -154,6 +154,18 @@ export default class VelociousEnvironmentHandlerNode extends Base{
|
|
|
154
154
|
return this._sharedTransactionCoordinatorAsyncLocalStorage.run(owners, callback)
|
|
155
155
|
}
|
|
156
156
|
|
|
157
|
+
/**
|
|
158
|
+
* Runs work without inherited shared-transaction coordinator ownership.
|
|
159
|
+
* @template T
|
|
160
|
+
* @param {() => T} callback - Detached work.
|
|
161
|
+
* @returns {T} - Callback result.
|
|
162
|
+
*/
|
|
163
|
+
runWithoutSharedTransactionCoordinatorOwners(callback) {
|
|
164
|
+
if (!this._sharedTransactionCoordinatorAsyncLocalStorage) return callback()
|
|
165
|
+
|
|
166
|
+
return this._sharedTransactionCoordinatorAsyncLocalStorage.run(new Map(), callback)
|
|
167
|
+
}
|
|
168
|
+
|
|
157
169
|
/**
|
|
158
170
|
* Runs work with async-safe test profile attribution.
|
|
159
171
|
* @template T
|
|
@@ -1,18 +1,30 @@
|
|
|
1
1
|
// @ts-check
|
|
2
2
|
|
|
3
|
-
/** @typedef {{coordinator: (callback: () => Promise<unknown>) => Promise<unknown>, ownedQueue: Promise<void>, owner: symbol}} CoordinatorRegistration */
|
|
3
|
+
/** @typedef {{coordinator: (callback: () => Promise<unknown>) => Promise<unknown>, ownedQueue: Promise<void>, owner: symbol, reentrantOwners: Set<symbol>, rootOwners: Set<symbol>}} CoordinatorRegistration */
|
|
4
4
|
|
|
5
5
|
/** @type {WeakMap<object, CoordinatorRegistration>} */
|
|
6
6
|
const coordinators = new WeakMap()
|
|
7
|
+
/** @type {WeakMap<object, CoordinatorRegistration>} */
|
|
8
|
+
const connectionRegistrations = new WeakMap()
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* Runs work directly when only the connection-local queue remains registered.
|
|
12
|
+
* @param {() => Promise<unknown>} callback - Serialized operation.
|
|
13
|
+
* @returns {Promise<unknown>} - Operation result.
|
|
14
|
+
*/
|
|
15
|
+
async function inactiveCoordinator(callback) {
|
|
16
|
+
return await callback()
|
|
17
|
+
}
|
|
7
18
|
|
|
8
19
|
/**
|
|
9
20
|
* Serializes sibling work that inherited one coordinator owner without re-entering the broker queue.
|
|
10
21
|
* @template T
|
|
22
|
+
* @param {import("../database/drivers/base.js").default} connection - Parent physical connection.
|
|
11
23
|
* @param {CoordinatorRegistration} registration - Physical connection registration.
|
|
12
24
|
* @param {() => Promise<T>} callback - Owned operation.
|
|
13
25
|
* @returns {Promise<T>} - Operation result.
|
|
14
26
|
*/
|
|
15
|
-
async function coordinateOwnedSharedTransactionConnection(registration, callback) {
|
|
27
|
+
async function coordinateOwnedSharedTransactionConnection(connection, registration, callback) {
|
|
16
28
|
const previous = registration.ownedQueue
|
|
17
29
|
/**
|
|
18
30
|
* Releases the next owned sibling operation.
|
|
@@ -22,13 +34,54 @@ async function coordinateOwnedSharedTransactionConnection(registration, callback
|
|
|
22
34
|
|
|
23
35
|
registration.ownedQueue = new Promise((resolve) => { release = resolve })
|
|
24
36
|
await previous
|
|
37
|
+
const operationOwner = Symbol("shared-transaction-owned-operation")
|
|
38
|
+
const environmentHandler = connection.configuration.getEnvironmentHandler()
|
|
39
|
+
|
|
40
|
+
registration.reentrantOwners.add(operationOwner)
|
|
25
41
|
try {
|
|
26
|
-
return await callback
|
|
42
|
+
return await environmentHandler.runWithSharedTransactionCoordinatorOwner(connection, operationOwner, callback)
|
|
27
43
|
} finally {
|
|
44
|
+
registration.reentrantOwners.delete(operationOwner)
|
|
28
45
|
release()
|
|
29
46
|
}
|
|
30
47
|
}
|
|
31
48
|
|
|
49
|
+
/**
|
|
50
|
+
* Drains all inherited operations admitted before the root owner is revoked.
|
|
51
|
+
* @param {CoordinatorRegistration} registration - Physical connection registration.
|
|
52
|
+
* @returns {Promise<void>} - Resolves when the owned queue stops advancing.
|
|
53
|
+
*/
|
|
54
|
+
async function drainOwnedSharedTransactionConnections(registration) {
|
|
55
|
+
let tail
|
|
56
|
+
|
|
57
|
+
do {
|
|
58
|
+
tail = registration.ownedQueue
|
|
59
|
+
await tail
|
|
60
|
+
} while (tail !== registration.ownedQueue)
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
/**
|
|
64
|
+
* Runs one broker-serialized root while tracking and draining its inherited work.
|
|
65
|
+
* @template T
|
|
66
|
+
* @param {import("../database/drivers/base.js").default} connection - Parent physical connection.
|
|
67
|
+
* @param {CoordinatorRegistration} registration - Physical connection registration.
|
|
68
|
+
* @param {() => Promise<T>} callback - Root operation.
|
|
69
|
+
* @returns {Promise<T>} - Operation result.
|
|
70
|
+
*/
|
|
71
|
+
async function coordinateRootSharedTransactionConnection(connection, registration, callback) {
|
|
72
|
+
await drainOwnedSharedTransactionConnections(registration)
|
|
73
|
+
const rootOwner = Symbol("shared-transaction-root-operation")
|
|
74
|
+
const environmentHandler = connection.configuration.getEnvironmentHandler()
|
|
75
|
+
|
|
76
|
+
registration.rootOwners.add(rootOwner)
|
|
77
|
+
try {
|
|
78
|
+
return await environmentHandler.runWithSharedTransactionCoordinatorOwner(connection, rootOwner, callback)
|
|
79
|
+
} finally {
|
|
80
|
+
await drainOwnedSharedTransactionConnections(registration)
|
|
81
|
+
registration.rootOwners.delete(rootOwner)
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
|
|
32
85
|
/**
|
|
33
86
|
* Registers test-only serialization owned by the active broker.
|
|
34
87
|
* @param {object} connection - Parent physical connection.
|
|
@@ -37,8 +90,17 @@ async function coordinateOwnedSharedTransactionConnection(registration, callback
|
|
|
37
90
|
*/
|
|
38
91
|
export function setSharedTransactionCoordinator(connection, coordinator) {
|
|
39
92
|
const owner = Symbol("shared-transaction-coordinator")
|
|
93
|
+
let registration = connectionRegistrations.get(connection)
|
|
94
|
+
|
|
95
|
+
if (registration) {
|
|
96
|
+
registration.coordinator = coordinator
|
|
97
|
+
registration.owner = owner
|
|
98
|
+
} else {
|
|
99
|
+
registration = {coordinator, ownedQueue: Promise.resolve(), owner, reentrantOwners: new Set(), rootOwners: new Set()}
|
|
100
|
+
connectionRegistrations.set(connection, registration)
|
|
101
|
+
}
|
|
40
102
|
|
|
41
|
-
coordinators.set(connection,
|
|
103
|
+
coordinators.set(connection, registration)
|
|
42
104
|
return owner
|
|
43
105
|
}
|
|
44
106
|
|
|
@@ -49,7 +111,12 @@ export function setSharedTransactionCoordinator(connection, coordinator) {
|
|
|
49
111
|
* @returns {void}
|
|
50
112
|
*/
|
|
51
113
|
export function clearSharedTransactionCoordinator(connection, coordinator) {
|
|
52
|
-
|
|
114
|
+
const registration = coordinators.get(connection)
|
|
115
|
+
|
|
116
|
+
if (registration?.coordinator === coordinator) {
|
|
117
|
+
coordinators.delete(connection)
|
|
118
|
+
registration.coordinator = inactiveCoordinator
|
|
119
|
+
}
|
|
53
120
|
}
|
|
54
121
|
|
|
55
122
|
/**
|
|
@@ -61,18 +128,24 @@ export function clearSharedTransactionCoordinator(connection, coordinator) {
|
|
|
61
128
|
* @returns {Promise<T>} - Operation result.
|
|
62
129
|
*/
|
|
63
130
|
export async function coordinateSharedTransactionConnection(connection, callback, operationOwner) {
|
|
64
|
-
const
|
|
131
|
+
const activeRegistration = coordinators.get(connection)
|
|
132
|
+
const registration = activeRegistration || connectionRegistrations.get(connection)
|
|
65
133
|
|
|
66
134
|
if (!registration) return await callback()
|
|
67
|
-
if (operationOwner === registration.owner) return await callback()
|
|
68
135
|
|
|
69
136
|
const environmentHandler = connection.configuration.getEnvironmentHandler()
|
|
137
|
+
const currentOwner = environmentHandler.getSharedTransactionCoordinatorOwner(connection)
|
|
70
138
|
|
|
71
|
-
if (
|
|
72
|
-
|
|
139
|
+
if (currentOwner && registration.reentrantOwners.has(currentOwner)) return await callback()
|
|
140
|
+
if (currentOwner && registration.rootOwners.has(currentOwner)) {
|
|
141
|
+
return await coordinateOwnedSharedTransactionConnection(connection, registration, callback)
|
|
142
|
+
}
|
|
143
|
+
if (!activeRegistration) return await coordinateOwnedSharedTransactionConnection(connection, registration, callback)
|
|
144
|
+
if (operationOwner === registration.owner) {
|
|
145
|
+
return await coordinateRootSharedTransactionConnection(connection, registration, callback)
|
|
73
146
|
}
|
|
74
147
|
|
|
75
148
|
return /** @type {T} */ (await registration.coordinator(async () => {
|
|
76
|
-
return await
|
|
149
|
+
return await coordinateRootSharedTransactionConnection(connection, registration, callback)
|
|
77
150
|
}))
|
|
78
151
|
}
|
package/src/testing/test.js
CHANGED
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
import path from "path"
|
|
4
4
|
import {fileURLToPath} from "url"
|
|
5
|
+
import { waitForEvent } from "@velocious/testing"
|
|
5
6
|
import EventEmitter from "../utils/event-emitter.js"
|
|
6
7
|
import Expect from "./expect.js"
|
|
7
|
-
import waitForEvent from "./wait-for-event.js"
|
|
8
8
|
import {arrayContaining, objectContaining} from "./expect-utils.js"
|
|
9
9
|
|
|
10
10
|
/**
|
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
export type WaitForEventOptions = {
|
|
2
|
-
/**
|
|
3
|
-
* Timeout in milliseconds (default: 5000).
|
|
4
|
-
*/
|
|
5
|
-
timeoutMs?: number;
|
|
6
|
-
/**
|
|
7
|
-
* Only resolve when this predicate returns true for the emitted arguments.
|
|
8
|
-
*/
|
|
9
|
-
filter?: (...args: Array<ReturnType<typeof JSON.parse>>) => boolean;
|
|
10
|
-
};
|
|
11
|
-
export type EventEmitterLike = {
|
|
12
|
-
/**
|
|
13
|
-
* Registers a listener.
|
|
14
|
-
*/
|
|
15
|
-
on: (event: string, listener: (...args: Array<ReturnType<typeof JSON.parse>>) => void) => void;
|
|
16
|
-
/**
|
|
17
|
-
* Removes a listener.
|
|
18
|
-
*/
|
|
19
|
-
off: (event: string, listener: (...args: Array<ReturnType<typeof JSON.parse>>) => void) => void;
|
|
20
|
-
};
|
|
21
|
-
/**
|
|
22
|
-
* @typedef {object} WaitForEventOptions
|
|
23
|
-
* @property {number} [timeoutMs] Timeout in milliseconds (default: 5000).
|
|
24
|
-
* @property {(...args: Array<ReturnType<typeof JSON.parse>>) => boolean} [filter] Only resolve when this predicate returns true for the emitted arguments.
|
|
25
|
-
*/
|
|
26
|
-
/**
|
|
27
|
-
* @typedef {object} EventEmitterLike
|
|
28
|
-
* @property {(event: string, listener: (...args: Array<ReturnType<typeof JSON.parse>>) => void) => void} on Registers a listener.
|
|
29
|
-
* @property {(event: string, listener: (...args: Array<ReturnType<typeof JSON.parse>>) => void) => void} off Removes a listener.
|
|
30
|
-
*/
|
|
31
|
-
/**
|
|
32
|
-
* Resolves the moment `eventName` fires on `emitter` — optionally only when `filter`
|
|
33
|
-
* matches the emitted arguments — instead of sleeping a fixed duration. Rejects with a
|
|
34
|
-
* timeout error if the event does not fire within `timeoutMs`. The listener is always
|
|
35
|
-
* removed (on resolve and on timeout).
|
|
36
|
-
*
|
|
37
|
-
* Use this to await a real signal (a background job finishing, a model update, a
|
|
38
|
-
* websocket message) rather than guessing a delay. To poll an arbitrary condition
|
|
39
|
-
* instead of a discrete event, use awaitery's `waitFor`.
|
|
40
|
-
* @param {EventEmitterLike} emitter - Event emitter exposing `on`/`off` (Node EventEmitter, eventemitter3, velocious `testEvents`, ...).
|
|
41
|
-
* @param {string} eventName - The event to wait for.
|
|
42
|
-
* @param {WaitForEventOptions} [options] - Options.
|
|
43
|
-
* @returns {Promise<ReturnType<typeof JSON.parse>>} - Resolves with the single emitted argument, an array when the event emits multiple, or undefined when it emits none.
|
|
44
|
-
*/
|
|
45
|
-
export default function waitForEvent(emitter: EventEmitterLike, eventName: string, options?: WaitForEventOptions): Promise<ReturnType<typeof JSON.parse>>;
|
|
46
|
-
//# sourceMappingURL=wait-for-event.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"wait-for-event.d.ts","sourceRoot":"","sources":["../../../src/testing/wait-for-event.js"],"names":[],"mappings":"AAGG,YAAkB,mBAAmB,GACrC;;;;IAAoB,SAAS,AAA7B,CACA,EADW,MAAM,CACjB;;;;IAAwE,MAAM,AAA9E,CACF,EADa,CAAC,GAAG,IAAI,EAAE,KAAK,CAAC,UAAU,CAAC,OAAO,IAAI,CAAC,KAAK,CAAC,CAAC,KAAK,OAAO,CACvE;CAAA,CAAA;AAGE,YAAkB,gBAAgB,GAClC;;;;IAAuG,EAAE,EAA9F,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC,GAAG,IAAI,EAAE,KAAK,CAAC,UAAU,CAAC,OAAO,IAAI,CAAC,KAAK,CAAC,CAAC,KAAK,IAAI,KAAK,IAAI,CACrG;;;;IAAuG,GAAG,EAA/F,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC,GAAG,IAAI,EAAE,KAAK,CAAC,UAAU,CAAC,OAAO,IAAI,CAAC,KAAK,CAAC,CAAC,KAAK,IAAI,KAAK,IAAI,CACvG;CAAA,CAAA;AAVD;;;;GAIG;AAEH;;;;GAIG;AAEH;;;;;;;;;;;;;GAaG;AACH,MAAM,CAAC,OAAO,UAAU,YAAY,CAAC,OAAO,EALjC,gBAKiC,EAAE,SAAS,EAJ5C,MAI4C,EAAE,OAAO,AAH7D,CACA,EADQ,mBAG0D,GAFxD,OAAO,CAAC,UAAU,CAAC,OAAO,IAAI,CAAC,KAAK,CAAC,CAAC,CA6ClD"}
|
|
@@ -1,64 +0,0 @@
|
|
|
1
|
-
// @ts-check
|
|
2
|
-
/**
|
|
3
|
-
* @typedef {object} WaitForEventOptions
|
|
4
|
-
* @property {number} [timeoutMs] Timeout in milliseconds (default: 5000).
|
|
5
|
-
* @property {(...args: Array<ReturnType<typeof JSON.parse>>) => boolean} [filter] Only resolve when this predicate returns true for the emitted arguments.
|
|
6
|
-
*/
|
|
7
|
-
/**
|
|
8
|
-
* @typedef {object} EventEmitterLike
|
|
9
|
-
* @property {(event: string, listener: (...args: Array<ReturnType<typeof JSON.parse>>) => void) => void} on Registers a listener.
|
|
10
|
-
* @property {(event: string, listener: (...args: Array<ReturnType<typeof JSON.parse>>) => void) => void} off Removes a listener.
|
|
11
|
-
*/
|
|
12
|
-
/**
|
|
13
|
-
* Resolves the moment `eventName` fires on `emitter` — optionally only when `filter`
|
|
14
|
-
* matches the emitted arguments — instead of sleeping a fixed duration. Rejects with a
|
|
15
|
-
* timeout error if the event does not fire within `timeoutMs`. The listener is always
|
|
16
|
-
* removed (on resolve and on timeout).
|
|
17
|
-
*
|
|
18
|
-
* Use this to await a real signal (a background job finishing, a model update, a
|
|
19
|
-
* websocket message) rather than guessing a delay. To poll an arbitrary condition
|
|
20
|
-
* instead of a discrete event, use awaitery's `waitFor`.
|
|
21
|
-
* @param {EventEmitterLike} emitter - Event emitter exposing `on`/`off` (Node EventEmitter, eventemitter3, velocious `testEvents`, ...).
|
|
22
|
-
* @param {string} eventName - The event to wait for.
|
|
23
|
-
* @param {WaitForEventOptions} [options] - Options.
|
|
24
|
-
* @returns {Promise<ReturnType<typeof JSON.parse>>} - Resolves with the single emitted argument, an array when the event emits multiple, or undefined when it emits none.
|
|
25
|
-
*/
|
|
26
|
-
export default function waitForEvent(emitter, eventName, options = {}) {
|
|
27
|
-
const { timeoutMs = 5000, filter } = options;
|
|
28
|
-
return new Promise((resolve, reject) => {
|
|
29
|
-
/** @type {ReturnType<typeof setTimeout>} */
|
|
30
|
-
let timer;
|
|
31
|
-
/**
|
|
32
|
-
* Resolves the wait when a matching event fires, removing itself first. A filter
|
|
33
|
-
* that throws (e.g. it assumes an event shape an intermediate emission doesn't
|
|
34
|
-
* have) rejects immediately rather than leaving the waiter pending until timeout.
|
|
35
|
-
* @param {...ReturnType<typeof JSON.parse>} args - Emitted arguments.
|
|
36
|
-
* @returns {void}
|
|
37
|
-
*/
|
|
38
|
-
const listener = (...args) => {
|
|
39
|
-
if (filter) {
|
|
40
|
-
let matched;
|
|
41
|
-
try {
|
|
42
|
-
matched = filter(...args);
|
|
43
|
-
}
|
|
44
|
-
catch (error) {
|
|
45
|
-
clearTimeout(timer);
|
|
46
|
-
emitter.off(eventName, listener);
|
|
47
|
-
reject(error);
|
|
48
|
-
return;
|
|
49
|
-
}
|
|
50
|
-
if (!matched)
|
|
51
|
-
return;
|
|
52
|
-
}
|
|
53
|
-
clearTimeout(timer);
|
|
54
|
-
emitter.off(eventName, listener);
|
|
55
|
-
resolve(args.length > 1 ? args : args[0]);
|
|
56
|
-
};
|
|
57
|
-
timer = setTimeout(() => {
|
|
58
|
-
emitter.off(eventName, listener);
|
|
59
|
-
reject(new Error(`Timed out after ${timeoutMs}ms waiting for event ${JSON.stringify(eventName)}`));
|
|
60
|
-
}, timeoutMs);
|
|
61
|
-
emitter.on(eventName, listener);
|
|
62
|
-
});
|
|
63
|
-
}
|
|
64
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoid2FpdC1mb3ItZXZlbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9zcmMvdGVzdGluZy93YWl0LWZvci1ldmVudC5qcyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxZQUFZO0FBRVo7Ozs7R0FJRztBQUVIOzs7O0dBSUc7QUFFSDs7Ozs7Ozs7Ozs7OztHQWFHO0FBQ0gsTUFBTSxDQUFDLE9BQU8sVUFBVSxZQUFZLENBQUMsT0FBTyxFQUFFLFNBQVMsRUFBRSxPQUFP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