@diffra-ai/chord 0.0.0-stage → 0.2.3
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/CHANGELOG.md +237 -0
- package/README.md +227 -2
- package/dist/context/index.d.ts +43 -0
- package/dist/context/index.d.ts.map +1 -0
- package/dist/context/index.js +112 -0
- package/dist/context/index.js.map +1 -0
- package/dist/contracts/accepts.d.ts +91 -0
- package/dist/contracts/accepts.d.ts.map +1 -0
- package/dist/contracts/accepts.js +145 -0
- package/dist/contracts/accepts.js.map +1 -0
- package/dist/contracts/contract.d.ts +238 -0
- package/dist/contracts/contract.d.ts.map +1 -0
- package/dist/contracts/contract.js +69 -0
- package/dist/contracts/contract.js.map +1 -0
- package/dist/contracts/declare.d.ts +144 -0
- package/dist/contracts/declare.d.ts.map +1 -0
- package/dist/contracts/declare.js +207 -0
- package/dist/contracts/declare.js.map +1 -0
- package/dist/contracts/evolve.d.ts +142 -0
- package/dist/contracts/evolve.d.ts.map +1 -0
- package/dist/contracts/evolve.js +216 -0
- package/dist/contracts/evolve.js.map +1 -0
- package/dist/contracts/fingerprint.d.ts +16 -0
- package/dist/contracts/fingerprint.d.ts.map +1 -0
- package/dist/contracts/fingerprint.js +61 -0
- package/dist/contracts/fingerprint.js.map +1 -0
- package/dist/contracts/history.d.ts +79 -0
- package/dist/contracts/history.d.ts.map +1 -0
- package/dist/contracts/history.js +3 -0
- package/dist/contracts/history.js.map +1 -0
- package/dist/contracts/host-kind.d.ts +58 -0
- package/dist/contracts/host-kind.d.ts.map +1 -0
- package/dist/contracts/host-kind.js +122 -0
- package/dist/contracts/host-kind.js.map +1 -0
- package/dist/contracts/index.d.ts +8 -0
- package/dist/contracts/index.d.ts.map +1 -0
- package/dist/contracts/index.js +7 -0
- package/dist/contracts/index.js.map +1 -0
- package/dist/contracts/internal.d.ts +12 -0
- package/dist/contracts/internal.d.ts.map +1 -0
- package/dist/contracts/internal.js +11 -0
- package/dist/contracts/internal.js.map +1 -0
- package/dist/contracts/names.d.ts +3 -0
- package/dist/contracts/names.d.ts.map +1 -0
- package/dist/contracts/names.js +13 -0
- package/dist/contracts/names.js.map +1 -0
- package/dist/contracts/params.d.ts +28 -0
- package/dist/contracts/params.d.ts.map +1 -0
- package/dist/contracts/params.js +55 -0
- package/dist/contracts/params.js.map +1 -0
- package/dist/contracts/schema.d.ts +144 -0
- package/dist/contracts/schema.d.ts.map +1 -0
- package/dist/contracts/schema.js +144 -0
- package/dist/contracts/schema.js.map +1 -0
- package/dist/contracts/snapshot.d.ts +16 -0
- package/dist/contracts/snapshot.d.ts.map +1 -0
- package/dist/contracts/snapshot.js +167 -0
- package/dist/contracts/snapshot.js.map +1 -0
- package/dist/data/args.d.ts +50 -0
- package/dist/data/args.d.ts.map +1 -0
- package/dist/data/args.js +83 -0
- package/dist/data/args.js.map +1 -0
- package/dist/data/errors.d.ts +80 -0
- package/dist/data/errors.d.ts.map +1 -0
- package/dist/data/errors.js +116 -0
- package/dist/data/errors.js.map +1 -0
- package/dist/data/failure.d.ts +31 -0
- package/dist/data/failure.d.ts.map +1 -0
- package/dist/data/failure.js +78 -0
- package/dist/data/failure.js.map +1 -0
- package/dist/data/index.d.ts +4 -0
- package/dist/data/index.d.ts.map +1 -0
- package/dist/data/index.js +5 -0
- package/dist/data/index.js.map +1 -0
- package/dist/data/internal.d.ts +7 -0
- package/dist/data/internal.d.ts.map +1 -0
- package/dist/data/internal.js +8 -0
- package/dist/data/internal.js.map +1 -0
- package/dist/data/params.d.ts +20 -0
- package/dist/data/params.d.ts.map +1 -0
- package/dist/data/params.js +31 -0
- package/dist/data/params.js.map +1 -0
- package/dist/data/principal.d.ts +28 -0
- package/dist/data/principal.d.ts.map +1 -0
- package/dist/data/principal.js +64 -0
- package/dist/data/principal.js.map +1 -0
- package/dist/data/validator.d.ts +12 -0
- package/dist/data/validator.d.ts.map +1 -0
- package/dist/data/validator.js +35 -0
- package/dist/data/validator.js.map +1 -0
- package/dist/delta/apply-immutable-trusted.d.ts +4 -0
- package/dist/delta/apply-immutable-trusted.d.ts.map +1 -0
- package/dist/delta/apply-immutable-trusted.js +126 -0
- package/dist/delta/apply-immutable-trusted.js.map +1 -0
- package/dist/delta/diff.d.ts +5 -0
- package/dist/delta/diff.d.ts.map +1 -0
- package/dist/delta/diff.js +435 -0
- package/dist/delta/diff.js.map +1 -0
- package/dist/delta/draft.d.ts +5 -0
- package/dist/delta/draft.d.ts.map +1 -0
- package/dist/delta/draft.js +2 -0
- package/dist/delta/draft.js.map +1 -0
- package/dist/delta/index.d.ts +120 -0
- package/dist/delta/index.d.ts.map +1 -0
- package/dist/delta/index.js +697 -0
- package/dist/delta/index.js.map +1 -0
- package/dist/delta/pending.d.ts +36 -0
- package/dist/delta/pending.d.ts.map +1 -0
- package/dist/delta/pending.js +143 -0
- package/dist/delta/pending.js.map +1 -0
- package/dist/delta/revision-validator.d.ts +7 -0
- package/dist/delta/revision-validator.d.ts.map +1 -0
- package/dist/delta/revision-validator.js +71 -0
- package/dist/delta/revision-validator.js.map +1 -0
- package/dist/delta/tracker.d.ts +38 -0
- package/dist/delta/tracker.d.ts.map +1 -0
- package/dist/delta/tracker.js +2175 -0
- package/dist/delta/tracker.js.map +1 -0
- package/dist/documents/address-source.d.ts +20 -0
- package/dist/documents/address-source.d.ts.map +1 -0
- package/dist/documents/address-source.js +44 -0
- package/dist/documents/address-source.js.map +1 -0
- package/dist/documents/definition.d.ts +92 -0
- package/dist/documents/definition.d.ts.map +1 -0
- package/dist/documents/definition.js +81 -0
- package/dist/documents/definition.js.map +1 -0
- package/dist/documents/documents.d.ts +129 -0
- package/dist/documents/documents.d.ts.map +1 -0
- package/dist/documents/documents.js +258 -0
- package/dist/documents/documents.js.map +1 -0
- package/dist/documents/fence.d.ts +9 -0
- package/dist/documents/fence.d.ts.map +1 -0
- package/dist/documents/fence.js +15 -0
- package/dist/documents/fence.js.map +1 -0
- package/dist/documents/handles.d.ts +81 -0
- package/dist/documents/handles.d.ts.map +1 -0
- package/dist/documents/handles.js +74 -0
- package/dist/documents/handles.js.map +1 -0
- package/dist/documents/index.d.ts +4 -0
- package/dist/documents/index.d.ts.map +1 -0
- package/dist/documents/index.js +3 -0
- package/dist/documents/index.js.map +1 -0
- package/dist/documents/internal.d.ts +9 -0
- package/dist/documents/internal.d.ts.map +1 -0
- package/dist/documents/internal.js +9 -0
- package/dist/documents/internal.js.map +1 -0
- package/dist/documents/keyed-slot.d.ts +139 -0
- package/dist/documents/keyed-slot.d.ts.map +1 -0
- package/dist/documents/keyed-slot.js +478 -0
- package/dist/documents/keyed-slot.js.map +1 -0
- package/dist/documents/line.d.ts +7 -0
- package/dist/documents/line.d.ts.map +1 -0
- package/dist/documents/line.js +14 -0
- package/dist/documents/line.js.map +1 -0
- package/dist/documents/persistence.d.ts +120 -0
- package/dist/documents/persistence.d.ts.map +1 -0
- package/dist/documents/persistence.js +156 -0
- package/dist/documents/persistence.js.map +1 -0
- package/dist/documents/residency.d.ts +31 -0
- package/dist/documents/residency.d.ts.map +1 -0
- package/dist/documents/residency.js +93 -0
- package/dist/documents/residency.js.map +1 -0
- package/dist/documents/slot.d.ts +112 -0
- package/dist/documents/slot.d.ts.map +1 -0
- package/dist/documents/slot.js +190 -0
- package/dist/documents/slot.js.map +1 -0
- package/dist/documents/transaction.d.ts +143 -0
- package/dist/documents/transaction.d.ts.map +1 -0
- package/dist/documents/transaction.js +445 -0
- package/dist/documents/transaction.js.map +1 -0
- package/dist/host/activity.d.ts +31 -0
- package/dist/host/activity.d.ts.map +1 -0
- package/dist/host/activity.js +40 -0
- package/dist/host/activity.js.map +1 -0
- package/dist/host/adapted.d.ts +63 -0
- package/dist/host/adapted.d.ts.map +1 -0
- package/dist/host/adapted.js +298 -0
- package/dist/host/adapted.js.map +1 -0
- package/dist/host/admission.d.ts +137 -0
- package/dist/host/admission.d.ts.map +1 -0
- package/dist/host/admission.js +290 -0
- package/dist/host/admission.js.map +1 -0
- package/dist/host/attempt.d.ts +417 -0
- package/dist/host/attempt.d.ts.map +1 -0
- package/dist/host/attempt.js +1490 -0
- package/dist/host/attempt.js.map +1 -0
- package/dist/host/backoff.d.ts +29 -0
- package/dist/host/backoff.d.ts.map +1 -0
- package/dist/host/backoff.js +69 -0
- package/dist/host/backoff.js.map +1 -0
- package/dist/host/ctx.d.ts +94 -0
- package/dist/host/ctx.d.ts.map +1 -0
- package/dist/host/ctx.js +200 -0
- package/dist/host/ctx.js.map +1 -0
- package/dist/host/deadline.d.ts +12 -0
- package/dist/host/deadline.d.ts.map +1 -0
- package/dist/host/deadline.js +40 -0
- package/dist/host/deadline.js.map +1 -0
- package/dist/host/dependencies.d.ts +97 -0
- package/dist/host/dependencies.d.ts.map +1 -0
- package/dist/host/dependencies.js +148 -0
- package/dist/host/dependencies.js.map +1 -0
- package/dist/host/destination.d.ts +48 -0
- package/dist/host/destination.d.ts.map +1 -0
- package/dist/host/destination.js +101 -0
- package/dist/host/destination.js.map +1 -0
- package/dist/host/events.d.ts +114 -0
- package/dist/host/events.d.ts.map +1 -0
- package/dist/host/events.js +191 -0
- package/dist/host/events.js.map +1 -0
- package/dist/host/facet.d.ts +106 -0
- package/dist/host/facet.d.ts.map +1 -0
- package/dist/host/facet.js +55 -0
- package/dist/host/facet.js.map +1 -0
- package/dist/host/follow.d.ts +52 -0
- package/dist/host/follow.d.ts.map +1 -0
- package/dist/host/follow.js +207 -0
- package/dist/host/follow.js.map +1 -0
- package/dist/host/host-data.d.ts +62 -0
- package/dist/host/host-data.d.ts.map +1 -0
- package/dist/host/host-data.js +229 -0
- package/dist/host/host-data.js.map +1 -0
- package/dist/host/host.d.ts +641 -0
- package/dist/host/host.d.ts.map +1 -0
- package/dist/host/host.js +1449 -0
- package/dist/host/host.js.map +1 -0
- package/dist/host/index.d.ts +20 -0
- package/dist/host/index.d.ts.map +1 -0
- package/dist/host/index.js +7 -0
- package/dist/host/index.js.map +1 -0
- package/dist/host/internal.d.ts +13 -0
- package/dist/host/internal.d.ts.map +1 -0
- package/dist/host/internal.js +11 -0
- package/dist/host/internal.js.map +1 -0
- package/dist/host/list.d.ts +52 -0
- package/dist/host/list.d.ts.map +1 -0
- package/dist/host/list.js +149 -0
- package/dist/host/list.js.map +1 -0
- package/dist/host/members.d.ts +58 -0
- package/dist/host/members.d.ts.map +1 -0
- package/dist/host/members.js +178 -0
- package/dist/host/members.js.map +1 -0
- package/dist/host/named-query.d.ts +67 -0
- package/dist/host/named-query.d.ts.map +1 -0
- package/dist/host/named-query.js +166 -0
- package/dist/host/named-query.js.map +1 -0
- package/dist/host/native.d.ts +64 -0
- package/dist/host/native.d.ts.map +1 -0
- package/dist/host/native.js +126 -0
- package/dist/host/native.js.map +1 -0
- package/dist/host/object.d.ts +388 -0
- package/dist/host/object.d.ts.map +1 -0
- package/dist/host/object.js +1527 -0
- package/dist/host/object.js.map +1 -0
- package/dist/host/old-work.d.ts +34 -0
- package/dist/host/old-work.d.ts.map +1 -0
- package/dist/host/old-work.js +52 -0
- package/dist/host/old-work.js.map +1 -0
- package/dist/host/parked.d.ts +23 -0
- package/dist/host/parked.d.ts.map +1 -0
- package/dist/host/parked.js +79 -0
- package/dist/host/parked.js.map +1 -0
- package/dist/host/presence.d.ts +34 -0
- package/dist/host/presence.d.ts.map +1 -0
- package/dist/host/presence.js +117 -0
- package/dist/host/presence.js.map +1 -0
- package/dist/host/query-reader.d.ts +80 -0
- package/dist/host/query-reader.d.ts.map +1 -0
- package/dist/host/query-reader.js +182 -0
- package/dist/host/query-reader.js.map +1 -0
- package/dist/host/read-declarations.d.ts +75 -0
- package/dist/host/read-declarations.d.ts.map +1 -0
- package/dist/host/read-declarations.js +152 -0
- package/dist/host/read-declarations.js.map +1 -0
- package/dist/host/readiness.d.ts +27 -0
- package/dist/host/readiness.d.ts.map +1 -0
- package/dist/host/readiness.js +134 -0
- package/dist/host/readiness.js.map +1 -0
- package/dist/host/ref-state.d.ts +53 -0
- package/dist/host/ref-state.d.ts.map +1 -0
- package/dist/host/ref-state.js +83 -0
- package/dist/host/ref-state.js.map +1 -0
- package/dist/host/reference-events.d.ts +51 -0
- package/dist/host/reference-events.d.ts.map +1 -0
- package/dist/host/reference-events.js +133 -0
- package/dist/host/reference-events.js.map +1 -0
- package/dist/host/reference-keys.d.ts +36 -0
- package/dist/host/reference-keys.d.ts.map +1 -0
- package/dist/host/reference-keys.js +168 -0
- package/dist/host/reference-keys.js.map +1 -0
- package/dist/host/reference-source.d.ts +77 -0
- package/dist/host/reference-source.d.ts.map +1 -0
- package/dist/host/reference-source.js +326 -0
- package/dist/host/reference-source.js.map +1 -0
- package/dist/host/reference.d.ts +377 -0
- package/dist/host/reference.d.ts.map +1 -0
- package/dist/host/reference.js +986 -0
- package/dist/host/reference.js.map +1 -0
- package/dist/host/reload-cycle.d.ts +16 -0
- package/dist/host/reload-cycle.d.ts.map +1 -0
- package/dist/host/reload-cycle.js +81 -0
- package/dist/host/reload-cycle.js.map +1 -0
- package/dist/host/retry-on.d.ts +28 -0
- package/dist/host/retry-on.d.ts.map +1 -0
- package/dist/host/retry-on.js +52 -0
- package/dist/host/retry-on.js.map +1 -0
- package/dist/host/revocation.d.ts +16 -0
- package/dist/host/revocation.d.ts.map +1 -0
- package/dist/host/revocation.js +27 -0
- package/dist/host/revocation.js.map +1 -0
- package/dist/host/root.d.ts +37 -0
- package/dist/host/root.d.ts.map +1 -0
- package/dist/host/root.js +68 -0
- package/dist/host/root.js.map +1 -0
- package/dist/host/route-admission.d.ts +24 -0
- package/dist/host/route-admission.d.ts.map +1 -0
- package/dist/host/route-admission.js +238 -0
- package/dist/host/route-admission.js.map +1 -0
- package/dist/host/route.d.ts +88 -0
- package/dist/host/route.d.ts.map +1 -0
- package/dist/host/route.js +247 -0
- package/dist/host/route.js.map +1 -0
- package/dist/host/routines.d.ts +78 -0
- package/dist/host/routines.d.ts.map +1 -0
- package/dist/host/routines.js +398 -0
- package/dist/host/routines.js.map +1 -0
- package/dist/host/sleep.d.ts +9 -0
- package/dist/host/sleep.d.ts.map +1 -0
- package/dist/host/sleep.js +40 -0
- package/dist/host/sleep.js.map +1 -0
- package/dist/host/staging.d.ts +100 -0
- package/dist/host/staging.d.ts.map +1 -0
- package/dist/host/staging.js +413 -0
- package/dist/host/staging.js.map +1 -0
- package/dist/host/tiling.d.ts +57 -0
- package/dist/host/tiling.d.ts.map +1 -0
- package/dist/host/tiling.js +269 -0
- package/dist/host/tiling.js.map +1 -0
- package/dist/host/unbound-clock.d.ts +23 -0
- package/dist/host/unbound-clock.d.ts.map +1 -0
- package/dist/host/unbound-clock.js +58 -0
- package/dist/host/unbound-clock.js.map +1 -0
- package/dist/host/unbound.d.ts +37 -0
- package/dist/host/unbound.d.ts.map +1 -0
- package/dist/host/unbound.js +88 -0
- package/dist/host/unbound.js.map +1 -0
- package/dist/host/uuid.d.ts +3 -0
- package/dist/host/uuid.d.ts.map +1 -0
- package/dist/host/uuid.js +38 -0
- package/dist/host/uuid.js.map +1 -0
- package/dist/index.d.ts +28 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +21 -0
- package/dist/index.js.map +1 -0
- package/dist/jobs/definition.d.ts +96 -0
- package/dist/jobs/definition.d.ts.map +1 -0
- package/dist/jobs/definition.js +83 -0
- package/dist/jobs/definition.js.map +1 -0
- package/dist/jobs/index.d.ts +5 -0
- package/dist/jobs/index.d.ts.map +1 -0
- package/dist/jobs/index.js +3 -0
- package/dist/jobs/index.js.map +1 -0
- package/dist/jobs/internal.d.ts +3 -0
- package/dist/jobs/internal.d.ts.map +1 -0
- package/dist/jobs/internal.js +4 -0
- package/dist/jobs/internal.js.map +1 -0
- package/dist/jobs/job.d.ts +149 -0
- package/dist/jobs/job.d.ts.map +1 -0
- package/dist/jobs/job.js +387 -0
- package/dist/jobs/job.js.map +1 -0
- package/dist/jobs/persisted.d.ts +38 -0
- package/dist/jobs/persisted.d.ts.map +1 -0
- package/dist/jobs/persisted.js +95 -0
- package/dist/jobs/persisted.js.map +1 -0
- package/dist/jobs/records.d.ts +231 -0
- package/dist/jobs/records.d.ts.map +1 -0
- package/dist/jobs/records.js +871 -0
- package/dist/jobs/records.js.map +1 -0
- package/dist/jobs/run-states.d.ts +69 -0
- package/dist/jobs/run-states.d.ts.map +1 -0
- package/dist/jobs/run-states.js +228 -0
- package/dist/jobs/run-states.js.map +1 -0
- package/dist/jobs/run.d.ts +117 -0
- package/dist/jobs/run.d.ts.map +1 -0
- package/dist/jobs/run.js +204 -0
- package/dist/jobs/run.js.map +1 -0
- package/dist/jobs/running.d.ts +44 -0
- package/dist/jobs/running.d.ts.map +1 -0
- package/dist/jobs/running.js +117 -0
- package/dist/jobs/running.js.map +1 -0
- package/dist/jobs/stored.d.ts +63 -0
- package/dist/jobs/stored.d.ts.map +1 -0
- package/dist/jobs/stored.js +55 -0
- package/dist/jobs/stored.js.map +1 -0
- package/dist/json.d.ts +18 -0
- package/dist/json.d.ts.map +1 -0
- package/dist/json.js +124 -0
- package/dist/json.js.map +1 -0
- package/dist/link/binary.d.ts +4 -0
- package/dist/link/binary.d.ts.map +1 -0
- package/dist/link/binary.js +574 -0
- package/dist/link/binary.js.map +1 -0
- package/dist/link/channel.d.ts +78 -0
- package/dist/link/channel.d.ts.map +1 -0
- package/dist/link/channel.js +252 -0
- package/dist/link/channel.js.map +1 -0
- package/dist/link/errors.d.ts +7 -0
- package/dist/link/errors.d.ts.map +1 -0
- package/dist/link/errors.js +21 -0
- package/dist/link/errors.js.map +1 -0
- package/dist/link/index.d.ts +8 -0
- package/dist/link/index.d.ts.map +1 -0
- package/dist/link/index.js +8 -0
- package/dist/link/index.js.map +1 -0
- package/dist/link/internal.d.ts +9 -0
- package/dist/link/internal.d.ts.map +1 -0
- package/dist/link/internal.js +10 -0
- package/dist/link/internal.js.map +1 -0
- package/dist/link/ipc.d.ts +22 -0
- package/dist/link/ipc.d.ts.map +1 -0
- package/dist/link/ipc.js +64 -0
- package/dist/link/ipc.js.map +1 -0
- package/dist/link/link.d.ts +34 -0
- package/dist/link/link.d.ts.map +1 -0
- package/dist/link/link.js +87 -0
- package/dist/link/link.js.map +1 -0
- package/dist/link/message.d.ts +278 -0
- package/dist/link/message.d.ts.map +1 -0
- package/dist/link/message.js +179 -0
- package/dist/link/message.js.map +1 -0
- package/dist/link/part.d.ts +80 -0
- package/dist/link/part.d.ts.map +1 -0
- package/dist/link/part.js +165 -0
- package/dist/link/part.js.map +1 -0
- package/dist/link/text.d.ts +6 -0
- package/dist/link/text.d.ts.map +1 -0
- package/dist/link/text.js +383 -0
- package/dist/link/text.js.map +1 -0
- package/dist/link/values.d.ts +40 -0
- package/dist/link/values.d.ts.map +1 -0
- package/dist/link/values.js +121 -0
- package/dist/link/values.js.map +1 -0
- package/dist/link/websocket.d.ts +26 -0
- package/dist/link/websocket.d.ts.map +1 -0
- package/dist/link/websocket.js +91 -0
- package/dist/link/websocket.js.map +1 -0
- package/dist/node/app/app.d.ts +283 -0
- package/dist/node/app/app.d.ts.map +1 -0
- package/dist/node/app/app.js +598 -0
- package/dist/node/app/app.js.map +1 -0
- package/dist/node/app/archive.d.ts +44 -0
- package/dist/node/app/archive.d.ts.map +1 -0
- package/dist/node/app/archive.js +212 -0
- package/dist/node/app/archive.js.map +1 -0
- package/dist/node/app/blobs.d.ts +23 -0
- package/dist/node/app/blobs.d.ts.map +1 -0
- package/dist/node/app/blobs.js +64 -0
- package/dist/node/app/blobs.js.map +1 -0
- package/dist/node/app/data.d.ts +40 -0
- package/dist/node/app/data.d.ts.map +1 -0
- package/dist/node/app/data.js +47 -0
- package/dist/node/app/data.js.map +1 -0
- package/dist/node/app/ephemeral-sign-ins.d.ts +20 -0
- package/dist/node/app/ephemeral-sign-ins.d.ts.map +1 -0
- package/dist/node/app/ephemeral-sign-ins.js +69 -0
- package/dist/node/app/ephemeral-sign-ins.js.map +1 -0
- package/dist/node/app/ephemeral.d.ts +11 -0
- package/dist/node/app/ephemeral.d.ts.map +1 -0
- package/dist/node/app/ephemeral.js +34 -0
- package/dist/node/app/ephemeral.js.map +1 -0
- package/dist/node/app/files-copy.d.ts +13 -0
- package/dist/node/app/files-copy.d.ts.map +1 -0
- package/dist/node/app/files-copy.js +86 -0
- package/dist/node/app/files-copy.js.map +1 -0
- package/dist/node/app/files-entry.d.ts +4 -0
- package/dist/node/app/files-entry.d.ts.map +1 -0
- package/dist/node/app/files-entry.js +7 -0
- package/dist/node/app/files-entry.js.map +1 -0
- package/dist/node/app/files-index.d.ts +180 -0
- package/dist/node/app/files-index.d.ts.map +1 -0
- package/dist/node/app/files-index.js +535 -0
- package/dist/node/app/files-index.js.map +1 -0
- package/dist/node/app/files.d.ts +388 -0
- package/dist/node/app/files.d.ts.map +1 -0
- package/dist/node/app/files.js +368 -0
- package/dist/node/app/files.js.map +1 -0
- package/dist/node/app/folder-views.d.ts +21 -0
- package/dist/node/app/folder-views.d.ts.map +1 -0
- package/dist/node/app/folder-views.js +55 -0
- package/dist/node/app/folder-views.js.map +1 -0
- package/dist/node/app/index.d.ts +12 -0
- package/dist/node/app/index.d.ts.map +1 -0
- package/dist/node/app/index.js +15 -0
- package/dist/node/app/index.js.map +1 -0
- package/dist/node/app/info.d.ts +70 -0
- package/dist/node/app/info.d.ts.map +1 -0
- package/dist/node/app/info.js +37 -0
- package/dist/node/app/info.js.map +1 -0
- package/dist/node/app/invite.d.ts +5 -0
- package/dist/node/app/invite.d.ts.map +1 -0
- package/dist/node/app/invite.js +64 -0
- package/dist/node/app/invite.js.map +1 -0
- package/dist/node/app/layout.d.ts +36 -0
- package/dist/node/app/layout.d.ts.map +1 -0
- package/dist/node/app/layout.js +87 -0
- package/dist/node/app/layout.js.map +1 -0
- package/dist/node/app/owner.d.ts +31 -0
- package/dist/node/app/owner.d.ts.map +1 -0
- package/dist/node/app/owner.js +104 -0
- package/dist/node/app/owner.js.map +1 -0
- package/dist/node/app/pairing.d.ts +55 -0
- package/dist/node/app/pairing.d.ts.map +1 -0
- package/dist/node/app/pairing.js +183 -0
- package/dist/node/app/pairing.js.map +1 -0
- package/dist/node/app/secrets.d.ts +16 -0
- package/dist/node/app/secrets.d.ts.map +1 -0
- package/dist/node/app/secrets.js +72 -0
- package/dist/node/app/secrets.js.map +1 -0
- package/dist/node/app/sign-ins.d.ts +74 -0
- package/dist/node/app/sign-ins.d.ts.map +1 -0
- package/dist/node/app/sign-ins.js +222 -0
- package/dist/node/app/sign-ins.js.map +1 -0
- package/dist/node/app/tar.d.ts +24 -0
- package/dist/node/app/tar.d.ts.map +1 -0
- package/dist/node/app/tar.js +167 -0
- package/dist/node/app/tar.js.map +1 -0
- package/dist/node/app/uploads.d.ts +37 -0
- package/dist/node/app/uploads.d.ts.map +1 -0
- package/dist/node/app/uploads.js +157 -0
- package/dist/node/app/uploads.js.map +1 -0
- package/dist/node/app/users.d.ts +39 -0
- package/dist/node/app/users.d.ts.map +1 -0
- package/dist/node/app/users.js +62 -0
- package/dist/node/app/users.js.map +1 -0
- package/dist/node/app/worker.d.ts +18 -0
- package/dist/node/app/worker.d.ts.map +1 -0
- package/dist/node/app/worker.js +84 -0
- package/dist/node/app/worker.js.map +1 -0
- package/dist/node/compression.d.ts +7 -0
- package/dist/node/compression.d.ts.map +1 -0
- package/dist/node/compression.js +25 -0
- package/dist/node/compression.js.map +1 -0
- package/dist/node/http/admission.d.ts +64 -0
- package/dist/node/http/admission.d.ts.map +1 -0
- package/dist/node/http/admission.js +137 -0
- package/dist/node/http/admission.js.map +1 -0
- package/dist/node/http/authenticate.d.ts +21 -0
- package/dist/node/http/authenticate.d.ts.map +1 -0
- package/dist/node/http/authenticate.js +34 -0
- package/dist/node/http/authenticate.js.map +1 -0
- package/dist/node/http/cookies.d.ts +32 -0
- package/dist/node/http/cookies.d.ts.map +1 -0
- package/dist/node/http/cookies.js +70 -0
- package/dist/node/http/cookies.js.map +1 -0
- package/dist/node/http/file.d.ts +23 -0
- package/dist/node/http/file.d.ts.map +1 -0
- package/dist/node/http/file.js +94 -0
- package/dist/node/http/file.js.map +1 -0
- package/dist/node/http/headers.d.ts +37 -0
- package/dist/node/http/headers.d.ts.map +1 -0
- package/dist/node/http/headers.js +136 -0
- package/dist/node/http/headers.js.map +1 -0
- package/dist/node/http/http.d.ts +114 -0
- package/dist/node/http/http.d.ts.map +1 -0
- package/dist/node/http/http.js +524 -0
- package/dist/node/http/http.js.map +1 -0
- package/dist/node/http/incoming.d.ts +19 -0
- package/dist/node/http/incoming.d.ts.map +1 -0
- package/dist/node/http/incoming.js +31 -0
- package/dist/node/http/incoming.js.map +1 -0
- package/dist/node/http/index.d.ts +11 -0
- package/dist/node/http/index.d.ts.map +1 -0
- package/dist/node/http/index.js +12 -0
- package/dist/node/http/index.js.map +1 -0
- package/dist/node/http/node.d.ts +78 -0
- package/dist/node/http/node.d.ts.map +1 -0
- package/dist/node/http/node.js +291 -0
- package/dist/node/http/node.js.map +1 -0
- package/dist/node/http/request.d.ts +60 -0
- package/dist/node/http/request.d.ts.map +1 -0
- package/dist/node/http/request.js +118 -0
- package/dist/node/http/request.js.map +1 -0
- package/dist/node/http/response.d.ts +63 -0
- package/dist/node/http/response.d.ts.map +1 -0
- package/dist/node/http/response.js +202 -0
- package/dist/node/http/response.js.map +1 -0
- package/dist/node/http/router.d.ts +132 -0
- package/dist/node/http/router.d.ts.map +1 -0
- package/dist/node/http/router.js +267 -0
- package/dist/node/http/router.js.map +1 -0
- package/dist/node/http/upgrades.d.ts +62 -0
- package/dist/node/http/upgrades.d.ts.map +1 -0
- package/dist/node/http/upgrades.js +194 -0
- package/dist/node/http/upgrades.js.map +1 -0
- package/dist/node/plugins/base-inputs.d.ts +14 -0
- package/dist/node/plugins/base-inputs.d.ts.map +1 -0
- package/dist/node/plugins/base-inputs.js +33 -0
- package/dist/node/plugins/base-inputs.js.map +1 -0
- package/dist/node/plugins/build.d.ts +77 -0
- package/dist/node/plugins/build.d.ts.map +1 -0
- package/dist/node/plugins/build.js +577 -0
- package/dist/node/plugins/build.js.map +1 -0
- package/dist/node/plugins/css-modules.d.ts +13 -0
- package/dist/node/plugins/css-modules.d.ts.map +1 -0
- package/dist/node/plugins/css-modules.js +58 -0
- package/dist/node/plugins/css-modules.js.map +1 -0
- package/dist/node/plugins/discover.d.ts +67 -0
- package/dist/node/plugins/discover.d.ts.map +1 -0
- package/dist/node/plugins/discover.js +369 -0
- package/dist/node/plugins/discover.js.map +1 -0
- package/dist/node/plugins/evaluate.d.ts +33 -0
- package/dist/node/plugins/evaluate.d.ts.map +1 -0
- package/dist/node/plugins/evaluate.js +121 -0
- package/dist/node/plugins/evaluate.js.map +1 -0
- package/dist/node/plugins/index.d.ts +11 -0
- package/dist/node/plugins/index.d.ts.map +1 -0
- package/dist/node/plugins/index.js +13 -0
- package/dist/node/plugins/index.js.map +1 -0
- package/dist/node/plugins/install.d.ts +40 -0
- package/dist/node/plugins/install.d.ts.map +1 -0
- package/dist/node/plugins/install.js +215 -0
- package/dist/node/plugins/install.js.map +1 -0
- package/dist/node/plugins/plugins.d.ts +165 -0
- package/dist/node/plugins/plugins.d.ts.map +1 -0
- package/dist/node/plugins/plugins.js +268 -0
- package/dist/node/plugins/plugins.js.map +1 -0
- package/dist/node/plugins/runtime.d.ts +57 -0
- package/dist/node/plugins/runtime.d.ts.map +1 -0
- package/dist/node/plugins/runtime.js +92 -0
- package/dist/node/plugins/runtime.js.map +1 -0
- package/dist/node/plugins/stack.d.ts +16 -0
- package/dist/node/plugins/stack.d.ts.map +1 -0
- package/dist/node/plugins/stack.js +70 -0
- package/dist/node/plugins/stack.js.map +1 -0
- package/dist/node/plugins/testing.d.ts +58 -0
- package/dist/node/plugins/testing.d.ts.map +1 -0
- package/dist/node/plugins/testing.js +210 -0
- package/dist/node/plugins/testing.js.map +1 -0
- package/dist/node/plugins/watcher.d.ts +69 -0
- package/dist/node/plugins/watcher.d.ts.map +1 -0
- package/dist/node/plugins/watcher.js +622 -0
- package/dist/node/plugins/watcher.js.map +1 -0
- package/dist/node/surfaces/bundle.d.ts +40 -0
- package/dist/node/surfaces/bundle.d.ts.map +1 -0
- package/dist/node/surfaces/bundle.js +121 -0
- package/dist/node/surfaces/bundle.js.map +1 -0
- package/dist/node/surfaces/current.d.ts +17 -0
- package/dist/node/surfaces/current.d.ts.map +1 -0
- package/dist/node/surfaces/current.js +54 -0
- package/dist/node/surfaces/current.js.map +1 -0
- package/dist/node/surfaces/index.d.ts +6 -0
- package/dist/node/surfaces/index.d.ts.map +1 -0
- package/dist/node/surfaces/index.js +6 -0
- package/dist/node/surfaces/index.js.map +1 -0
- package/dist/node/surfaces/published.d.ts +27 -0
- package/dist/node/surfaces/published.d.ts.map +1 -0
- package/dist/node/surfaces/published.js +142 -0
- package/dist/node/surfaces/published.js.map +1 -0
- package/dist/node/surfaces/served.d.ts +17 -0
- package/dist/node/surfaces/served.d.ts.map +1 -0
- package/dist/node/surfaces/served.js +44 -0
- package/dist/node/surfaces/served.js.map +1 -0
- package/dist/node/surfaces/surface-build.d.ts +53 -0
- package/dist/node/surfaces/surface-build.d.ts.map +1 -0
- package/dist/node/surfaces/surface-build.js +105 -0
- package/dist/node/surfaces/surface-build.js.map +1 -0
- package/dist/node/surfaces/tui.d.ts +42 -0
- package/dist/node/surfaces/tui.d.ts.map +1 -0
- package/dist/node/surfaces/tui.js +59 -0
- package/dist/node/surfaces/tui.js.map +1 -0
- package/dist/node/surfaces/web.d.ts +82 -0
- package/dist/node/surfaces/web.d.ts.map +1 -0
- package/dist/node/surfaces/web.js +122 -0
- package/dist/node/surfaces/web.js.map +1 -0
- package/dist/node/tui/actions.d.ts +49 -0
- package/dist/node/tui/actions.d.ts.map +1 -0
- package/dist/node/tui/actions.js +195 -0
- package/dist/node/tui/actions.js.map +1 -0
- package/dist/node/tui/credentials.d.ts +17 -0
- package/dist/node/tui/credentials.d.ts.map +1 -0
- package/dist/node/tui/credentials.js +54 -0
- package/dist/node/tui/credentials.js.map +1 -0
- package/dist/node/tui/filter.d.ts +5 -0
- package/dist/node/tui/filter.d.ts.map +1 -0
- package/dist/node/tui/filter.js +79 -0
- package/dist/node/tui/filter.js.map +1 -0
- package/dist/node/tui/index.d.ts +6 -0
- package/dist/node/tui/index.d.ts.map +1 -0
- package/dist/node/tui/index.js +6 -0
- package/dist/node/tui/index.js.map +1 -0
- package/dist/node/tui/launcher.d.ts +40 -0
- package/dist/node/tui/launcher.d.ts.map +1 -0
- package/dist/node/tui/launcher.js +439 -0
- package/dist/node/tui/launcher.js.map +1 -0
- package/dist/node/tui/pipe.d.ts +18 -0
- package/dist/node/tui/pipe.d.ts.map +1 -0
- package/dist/node/tui/pipe.js +134 -0
- package/dist/node/tui/pipe.js.map +1 -0
- package/dist/node/tui/sandbox.d.ts +54 -0
- package/dist/node/tui/sandbox.d.ts.map +1 -0
- package/dist/node/tui/sandbox.js +431 -0
- package/dist/node/tui/sandbox.js.map +1 -0
- package/dist/node/workers/base.d.ts +30 -0
- package/dist/node/workers/base.d.ts.map +1 -0
- package/dist/node/workers/base.js +260 -0
- package/dist/node/workers/base.js.map +1 -0
- package/dist/node/workers/child.d.ts +4 -0
- package/dist/node/workers/child.d.ts.map +1 -0
- package/dist/node/workers/child.js +6 -0
- package/dist/node/workers/child.js.map +1 -0
- package/dist/node/workers/control.d.ts +83 -0
- package/dist/node/workers/control.d.ts.map +1 -0
- package/dist/node/workers/control.js +77 -0
- package/dist/node/workers/control.js.map +1 -0
- package/dist/node/workers/index.d.ts +4 -0
- package/dist/node/workers/index.d.ts.map +1 -0
- package/dist/node/workers/index.js +7 -0
- package/dist/node/workers/index.js.map +1 -0
- package/dist/node/workers/lock.d.ts +30 -0
- package/dist/node/workers/lock.d.ts.map +1 -0
- package/dist/node/workers/lock.js +180 -0
- package/dist/node/workers/lock.js.map +1 -0
- package/dist/node/workers/main.d.ts +46 -0
- package/dist/node/workers/main.d.ts.map +1 -0
- package/dist/node/workers/main.js +230 -0
- package/dist/node/workers/main.js.map +1 -0
- package/dist/node/workers/process.d.ts +43 -0
- package/dist/node/workers/process.d.ts.map +1 -0
- package/dist/node/workers/process.js +137 -0
- package/dist/node/workers/process.js.map +1 -0
- package/dist/node/workers/workers.d.ts +144 -0
- package/dist/node/workers/workers.d.ts.map +1 -0
- package/dist/node/workers/workers.js +723 -0
- package/dist/node/workers/workers.js.map +1 -0
- package/dist/output.d.ts +91 -0
- package/dist/output.d.ts.map +1 -0
- package/dist/output.js +362 -0
- package/dist/output.js.map +1 -0
- package/dist/react/hooks.d.ts +61 -0
- package/dist/react/hooks.d.ts.map +1 -0
- package/dist/react/hooks.js +119 -0
- package/dist/react/hooks.js.map +1 -0
- package/dist/react/index.d.ts +4 -0
- package/dist/react/index.d.ts.map +1 -0
- package/dist/react/index.js +4 -0
- package/dist/react/index.js.map +1 -0
- package/dist/react/stores.d.ts +9 -0
- package/dist/react/stores.d.ts.map +1 -0
- package/dist/react/stores.js +37 -0
- package/dist/react/stores.js.map +1 -0
- package/dist/registries/contribution.d.ts +50 -0
- package/dist/registries/contribution.d.ts.map +1 -0
- package/dist/registries/contribution.js +129 -0
- package/dist/registries/contribution.js.map +1 -0
- package/dist/registries/entries.d.ts +18 -0
- package/dist/registries/entries.d.ts.map +1 -0
- package/dist/registries/entries.js +42 -0
- package/dist/registries/entries.js.map +1 -0
- package/dist/registries/index.d.ts +3 -0
- package/dist/registries/index.d.ts.map +1 -0
- package/dist/registries/index.js +5 -0
- package/dist/registries/index.js.map +1 -0
- package/dist/registries/internal.d.ts +4 -0
- package/dist/registries/internal.d.ts.map +1 -0
- package/dist/registries/internal.js +5 -0
- package/dist/registries/internal.js.map +1 -0
- package/dist/registries/record.d.ts +115 -0
- package/dist/registries/record.d.ts.map +1 -0
- package/dist/registries/record.js +283 -0
- package/dist/registries/record.js.map +1 -0
- package/dist/registries/registry.d.ts +74 -0
- package/dist/registries/registry.d.ts.map +1 -0
- package/dist/registries/registry.js +14 -0
- package/dist/registries/registry.js.map +1 -0
- package/dist/registries/value.d.ts +48 -0
- package/dist/registries/value.d.ts.map +1 -0
- package/dist/registries/value.js +224 -0
- package/dist/registries/value.js.map +1 -0
- package/dist/remote/calls.d.ts +34 -0
- package/dist/remote/calls.d.ts.map +1 -0
- package/dist/remote/calls.js +75 -0
- package/dist/remote/calls.js.map +1 -0
- package/dist/remote/consumer.d.ts +59 -0
- package/dist/remote/consumer.d.ts.map +1 -0
- package/dist/remote/consumer.js +468 -0
- package/dist/remote/consumer.js.map +1 -0
- package/dist/remote/hold.d.ts +147 -0
- package/dist/remote/hold.d.ts.map +1 -0
- package/dist/remote/hold.js +653 -0
- package/dist/remote/hold.js.map +1 -0
- package/dist/remote/host-link.d.ts +81 -0
- package/dist/remote/host-link.d.ts.map +1 -0
- package/dist/remote/host-link.js +198 -0
- package/dist/remote/host-link.js.map +1 -0
- package/dist/remote/internal.d.ts +6 -0
- package/dist/remote/internal.d.ts.map +1 -0
- package/dist/remote/internal.js +6 -0
- package/dist/remote/internal.js.map +1 -0
- package/dist/remote/path.d.ts +105 -0
- package/dist/remote/path.d.ts.map +1 -0
- package/dist/remote/path.js +197 -0
- package/dist/remote/path.js.map +1 -0
- package/dist/remote/provider.d.ts +113 -0
- package/dist/remote/provider.d.ts.map +1 -0
- package/dist/remote/provider.js +787 -0
- package/dist/remote/provider.js.map +1 -0
- package/dist/remote/relay.d.ts +126 -0
- package/dist/remote/relay.d.ts.map +1 -0
- package/dist/remote/relay.js +334 -0
- package/dist/remote/relay.js.map +1 -0
- package/dist/remote/remote-object.d.ts +181 -0
- package/dist/remote/remote-object.d.ts.map +1 -0
- package/dist/remote/remote-object.js +683 -0
- package/dist/remote/remote-object.js.map +1 -0
- package/dist/remote/replica.d.ts +66 -0
- package/dist/remote/replica.d.ts.map +1 -0
- package/dist/remote/replica.js +148 -0
- package/dist/remote/replica.js.map +1 -0
- package/dist/sqlite/cloudflare.d.ts +54 -0
- package/dist/sqlite/cloudflare.d.ts.map +1 -0
- package/dist/sqlite/cloudflare.js +144 -0
- package/dist/sqlite/cloudflare.js.map +1 -0
- package/dist/sqlite/database.d.ts +40 -0
- package/dist/sqlite/database.d.ts.map +1 -0
- package/dist/sqlite/database.js +2 -0
- package/dist/sqlite/database.js.map +1 -0
- package/dist/sqlite/index.d.ts +4 -0
- package/dist/sqlite/index.d.ts.map +1 -0
- package/dist/sqlite/index.js +3 -0
- package/dist/sqlite/index.js.map +1 -0
- package/dist/sqlite/migrations.d.ts +10 -0
- package/dist/sqlite/migrations.d.ts.map +1 -0
- package/dist/sqlite/migrations.js +33 -0
- package/dist/sqlite/migrations.js.map +1 -0
- package/dist/sqlite/node.d.ts +49 -0
- package/dist/sqlite/node.d.ts.map +1 -0
- package/dist/sqlite/node.js +197 -0
- package/dist/sqlite/node.js.map +1 -0
- package/dist/sqlite/schema.d.ts +3 -0
- package/dist/sqlite/schema.d.ts.map +1 -0
- package/dist/sqlite/schema.js +10 -0
- package/dist/sqlite/schema.js.map +1 -0
- package/dist/state/batch.d.ts +64 -0
- package/dist/state/batch.d.ts.map +1 -0
- package/dist/state/batch.js +164 -0
- package/dist/state/batch.js.map +1 -0
- package/dist/state/derive.d.ts +56 -0
- package/dist/state/derive.d.ts.map +1 -0
- package/dist/state/derive.js +192 -0
- package/dist/state/derive.js.map +1 -0
- package/dist/state/framed.d.ts +43 -0
- package/dist/state/framed.d.ts.map +1 -0
- package/dist/state/framed.js +121 -0
- package/dist/state/framed.js.map +1 -0
- package/dist/state/index.d.ts +6 -0
- package/dist/state/index.d.ts.map +1 -0
- package/dist/state/index.js +4 -0
- package/dist/state/index.js.map +1 -0
- package/dist/state/internal.d.ts +7 -0
- package/dist/state/internal.d.ts.map +1 -0
- package/dist/state/internal.js +9 -0
- package/dist/state/internal.js.map +1 -0
- package/dist/state/native-source.d.ts +106 -0
- package/dist/state/native-source.d.ts.map +1 -0
- package/dist/state/native-source.js +240 -0
- package/dist/state/native-source.js.map +1 -0
- package/dist/state/watchable.d.ts +114 -0
- package/dist/state/watchable.d.ts.map +1 -0
- package/dist/state/watchable.js +156 -0
- package/dist/state/watchable.js.map +1 -0
- package/dist/state/writable.d.ts +32 -0
- package/dist/state/writable.d.ts.map +1 -0
- package/dist/state/writable.js +49 -0
- package/dist/state/writable.js.map +1 -0
- package/dist/store/adapter.d.ts +67 -0
- package/dist/store/adapter.d.ts.map +1 -0
- package/dist/store/adapter.js +118 -0
- package/dist/store/adapter.js.map +1 -0
- package/dist/store/allocator.d.ts +17 -0
- package/dist/store/allocator.d.ts.map +1 -0
- package/dist/store/allocator.js +30 -0
- package/dist/store/allocator.js.map +1 -0
- package/dist/store/applier.d.ts +8 -0
- package/dist/store/applier.d.ts.map +1 -0
- package/dist/store/applier.js +390 -0
- package/dist/store/applier.js.map +1 -0
- package/dist/store/apply-batch.d.ts +12 -0
- package/dist/store/apply-batch.d.ts.map +1 -0
- package/dist/store/apply-batch.js +83 -0
- package/dist/store/apply-batch.js.map +1 -0
- package/dist/store/archive.d.ts +36 -0
- package/dist/store/archive.d.ts.map +1 -0
- package/dist/store/archive.js +140 -0
- package/dist/store/archive.js.map +1 -0
- package/dist/store/backend.d.ts +10 -0
- package/dist/store/backend.d.ts.map +1 -0
- package/dist/store/backend.js +15 -0
- package/dist/store/backend.js.map +1 -0
- package/dist/store/catalog.d.ts +24 -0
- package/dist/store/catalog.d.ts.map +1 -0
- package/dist/store/catalog.js +17 -0
- package/dist/store/catalog.js.map +1 -0
- package/dist/store/claims.d.ts +23 -0
- package/dist/store/claims.d.ts.map +1 -0
- package/dist/store/claims.js +65 -0
- package/dist/store/claims.js.map +1 -0
- package/dist/store/column-set.d.ts +64 -0
- package/dist/store/column-set.d.ts.map +1 -0
- package/dist/store/column-set.js +96 -0
- package/dist/store/column-set.js.map +1 -0
- package/dist/store/columns.d.ts +93 -0
- package/dist/store/columns.d.ts.map +1 -0
- package/dist/store/columns.js +87 -0
- package/dist/store/columns.js.map +1 -0
- package/dist/store/engine.d.ts +182 -0
- package/dist/store/engine.d.ts.map +1 -0
- package/dist/store/engine.js +290 -0
- package/dist/store/engine.js.map +1 -0
- package/dist/store/evaluate.d.ts +17 -0
- package/dist/store/evaluate.d.ts.map +1 -0
- package/dist/store/evaluate.js +131 -0
- package/dist/store/evaluate.js.map +1 -0
- package/dist/store/export.d.ts +30 -0
- package/dist/store/export.d.ts.map +1 -0
- package/dist/store/export.js +221 -0
- package/dist/store/export.js.map +1 -0
- package/dist/store/expression.d.ts +254 -0
- package/dist/store/expression.d.ts.map +1 -0
- package/dist/store/expression.js +577 -0
- package/dist/store/expression.js.map +1 -0
- package/dist/store/host-column.d.ts +22 -0
- package/dist/store/host-column.d.ts.map +1 -0
- package/dist/store/host-column.js +36 -0
- package/dist/store/host-column.js.map +1 -0
- package/dist/store/host-data.d.ts +100 -0
- package/dist/store/host-data.d.ts.map +1 -0
- package/dist/store/host-data.js +397 -0
- package/dist/store/host-data.js.map +1 -0
- package/dist/store/import-migration.d.ts +19 -0
- package/dist/store/import-migration.d.ts.map +1 -0
- package/dist/store/import-migration.js +124 -0
- package/dist/store/import-migration.js.map +1 -0
- package/dist/store/import.d.ts +12 -0
- package/dist/store/import.d.ts.map +1 -0
- package/dist/store/import.js +279 -0
- package/dist/store/import.js.map +1 -0
- package/dist/store/index.d.ts +19 -0
- package/dist/store/index.d.ts.map +1 -0
- package/dist/store/index.js +16 -0
- package/dist/store/index.js.map +1 -0
- package/dist/store/json-column.d.ts +33 -0
- package/dist/store/json-column.d.ts.map +1 -0
- package/dist/store/json-column.js +62 -0
- package/dist/store/json-column.js.map +1 -0
- package/dist/store/jsonl.d.ts +9 -0
- package/dist/store/jsonl.d.ts.map +1 -0
- package/dist/store/jsonl.js +61 -0
- package/dist/store/jsonl.js.map +1 -0
- package/dist/store/live-query.d.ts +72 -0
- package/dist/store/live-query.d.ts.map +1 -0
- package/dist/store/live-query.js +162 -0
- package/dist/store/live-query.js.map +1 -0
- package/dist/store/open-query.d.ts +90 -0
- package/dist/store/open-query.d.ts.map +1 -0
- package/dist/store/open-query.js +201 -0
- package/dist/store/open-query.js.map +1 -0
- package/dist/store/outbox.d.ts +26 -0
- package/dist/store/outbox.d.ts.map +1 -0
- package/dist/store/outbox.js +80 -0
- package/dist/store/outbox.js.map +1 -0
- package/dist/store/page.d.ts +14 -0
- package/dist/store/page.d.ts.map +1 -0
- package/dist/store/page.js +26 -0
- package/dist/store/page.js.map +1 -0
- package/dist/store/query.d.ts +65 -0
- package/dist/store/query.d.ts.map +1 -0
- package/dist/store/query.js +193 -0
- package/dist/store/query.js.map +1 -0
- package/dist/store/read-plan.d.ts +74 -0
- package/dist/store/read-plan.d.ts.map +1 -0
- package/dist/store/read-plan.js +324 -0
- package/dist/store/read-plan.js.map +1 -0
- package/dist/store/read.d.ts +81 -0
- package/dist/store/read.d.ts.map +1 -0
- package/dist/store/read.js +113 -0
- package/dist/store/read.js.map +1 -0
- package/dist/store/reads.d.ts +79 -0
- package/dist/store/reads.d.ts.map +1 -0
- package/dist/store/reads.js +255 -0
- package/dist/store/reads.js.map +1 -0
- package/dist/store/refusal.d.ts +15 -0
- package/dist/store/refusal.d.ts.map +1 -0
- package/dist/store/refusal.js +36 -0
- package/dist/store/refusal.js.map +1 -0
- package/dist/store/rows.d.ts +96 -0
- package/dist/store/rows.d.ts.map +1 -0
- package/dist/store/rows.js +222 -0
- package/dist/store/rows.js.map +1 -0
- package/dist/store/schema.d.ts +25 -0
- package/dist/store/schema.d.ts.map +1 -0
- package/dist/store/schema.js +123 -0
- package/dist/store/schema.js.map +1 -0
- package/dist/store/skip.d.ts +26 -0
- package/dist/store/skip.d.ts.map +1 -0
- package/dist/store/skip.js +66 -0
- package/dist/store/skip.js.map +1 -0
- package/dist/store/sql.d.ts +78 -0
- package/dist/store/sql.d.ts.map +1 -0
- package/dist/store/sql.js +244 -0
- package/dist/store/sql.js.map +1 -0
- package/dist/store/step.d.ts +52 -0
- package/dist/store/step.d.ts.map +1 -0
- package/dist/store/step.js +59 -0
- package/dist/store/step.js.map +1 -0
- package/dist/store/store.d.ts +192 -0
- package/dist/store/store.d.ts.map +1 -0
- package/dist/store/store.js +863 -0
- package/dist/store/store.js.map +1 -0
- package/dist/store/table-changes.d.ts +35 -0
- package/dist/store/table-changes.d.ts.map +1 -0
- package/dist/store/table-changes.js +127 -0
- package/dist/store/table-changes.js.map +1 -0
- package/dist/store/table-evolve.d.ts +82 -0
- package/dist/store/table-evolve.d.ts.map +1 -0
- package/dist/store/table-evolve.js +208 -0
- package/dist/store/table-evolve.js.map +1 -0
- package/dist/store/table-handle.d.ts +69 -0
- package/dist/store/table-handle.d.ts.map +1 -0
- package/dist/store/table-handle.js +92 -0
- package/dist/store/table-handle.js.map +1 -0
- package/dist/store/table-history.d.ts +78 -0
- package/dist/store/table-history.d.ts.map +1 -0
- package/dist/store/table-history.js +43 -0
- package/dist/store/table-history.js.map +1 -0
- package/dist/store/table-migration.d.ts +28 -0
- package/dist/store/table-migration.d.ts.map +1 -0
- package/dist/store/table-migration.js +212 -0
- package/dist/store/table-migration.js.map +1 -0
- package/dist/store/table-writes.d.ts +125 -0
- package/dist/store/table-writes.d.ts.map +1 -0
- package/dist/store/table-writes.js +170 -0
- package/dist/store/table-writes.js.map +1 -0
- package/dist/store/table.d.ts +91 -0
- package/dist/store/table.d.ts.map +1 -0
- package/dist/store/table.js +133 -0
- package/dist/store/table.js.map +1 -0
- package/dist/store/text.d.ts +14 -0
- package/dist/store/text.d.ts.map +1 -0
- package/dist/store/text.js +51 -0
- package/dist/store/text.js.map +1 -0
- package/dist/store/writes.d.ts +5 -0
- package/dist/store/writes.d.ts.map +1 -0
- package/dist/store/writes.js +4 -0
- package/dist/store/writes.js.map +1 -0
- package/dist/surfaces/active-language.d.ts +20 -0
- package/dist/surfaces/active-language.d.ts.map +1 -0
- package/dist/surfaces/active-language.js +78 -0
- package/dist/surfaces/active-language.js.map +1 -0
- package/dist/surfaces/active-theme.d.ts +16 -0
- package/dist/surfaces/active-theme.d.ts.map +1 -0
- package/dist/surfaces/active-theme.js +47 -0
- package/dist/surfaces/active-theme.js.map +1 -0
- package/dist/surfaces/client.d.ts +106 -0
- package/dist/surfaces/client.d.ts.map +1 -0
- package/dist/surfaces/client.js +280 -0
- package/dist/surfaces/client.js.map +1 -0
- package/dist/surfaces/connection.d.ts +53 -0
- package/dist/surfaces/connection.d.ts.map +1 -0
- package/dist/surfaces/connection.js +161 -0
- package/dist/surfaces/connection.js.map +1 -0
- package/dist/surfaces/format.d.ts +5 -0
- package/dist/surfaces/format.d.ts.map +1 -0
- package/dist/surfaces/format.js +37 -0
- package/dist/surfaces/format.js.map +1 -0
- package/dist/surfaces/index.d.ts +15 -0
- package/dist/surfaces/index.d.ts.map +1 -0
- package/dist/surfaces/index.js +18 -0
- package/dist/surfaces/index.js.map +1 -0
- package/dist/surfaces/language.d.ts +53 -0
- package/dist/surfaces/language.d.ts.map +1 -0
- package/dist/surfaces/language.js +74 -0
- package/dist/surfaces/language.js.map +1 -0
- package/dist/surfaces/loaded.d.ts +42 -0
- package/dist/surfaces/loaded.d.ts.map +1 -0
- package/dist/surfaces/loaded.js +116 -0
- package/dist/surfaces/loaded.js.map +1 -0
- package/dist/surfaces/locale-choice.d.ts +26 -0
- package/dist/surfaces/locale-choice.d.ts.map +1 -0
- package/dist/surfaces/locale-choice.js +14 -0
- package/dist/surfaces/locale-choice.js.map +1 -0
- package/dist/surfaces/messages.d.ts +67 -0
- package/dist/surfaces/messages.d.ts.map +1 -0
- package/dist/surfaces/messages.js +112 -0
- package/dist/surfaces/messages.js.map +1 -0
- package/dist/surfaces/page-state.d.ts +14 -0
- package/dist/surfaces/page-state.d.ts.map +1 -0
- package/dist/surfaces/page-state.js +43 -0
- package/dist/surfaces/page-state.js.map +1 -0
- package/dist/surfaces/preference.d.ts +33 -0
- package/dist/surfaces/preference.d.ts.map +1 -0
- package/dist/surfaces/preference.js +72 -0
- package/dist/surfaces/preference.js.map +1 -0
- package/dist/surfaces/registered.d.ts +33 -0
- package/dist/surfaces/registered.d.ts.map +1 -0
- package/dist/surfaces/registered.js +51 -0
- package/dist/surfaces/registered.js.map +1 -0
- package/dist/surfaces/scripts.d.ts +86 -0
- package/dist/surfaces/scripts.d.ts.map +1 -0
- package/dist/surfaces/scripts.js +28 -0
- package/dist/surfaces/scripts.js.map +1 -0
- package/dist/surfaces/theme-choice.d.ts +32 -0
- package/dist/surfaces/theme-choice.d.ts.map +1 -0
- package/dist/surfaces/theme-choice.js +18 -0
- package/dist/surfaces/theme-choice.js.map +1 -0
- package/dist/surfaces/themes.d.ts +43 -0
- package/dist/surfaces/themes.d.ts.map +1 -0
- package/dist/surfaces/themes.js +110 -0
- package/dist/surfaces/themes.js.map +1 -0
- package/dist/surfaces/translations.d.ts +29 -0
- package/dist/surfaces/translations.d.ts.map +1 -0
- package/dist/surfaces/translations.js +57 -0
- package/dist/surfaces/translations.js.map +1 -0
- package/dist/surfaces/variant.d.ts +23 -0
- package/dist/surfaces/variant.d.ts.map +1 -0
- package/dist/surfaces/variant.js +18 -0
- package/dist/surfaces/variant.js.map +1 -0
- package/dist/sync/batch.d.ts +18 -0
- package/dist/sync/batch.d.ts.map +1 -0
- package/dist/sync/batch.js +125 -0
- package/dist/sync/batch.js.map +1 -0
- package/dist/sync/client.d.ts +169 -0
- package/dist/sync/client.d.ts.map +1 -0
- package/dist/sync/client.js +459 -0
- package/dist/sync/client.js.map +1 -0
- package/dist/sync/files.d.ts +46 -0
- package/dist/sync/files.d.ts.map +1 -0
- package/dist/sync/files.js +13 -0
- package/dist/sync/files.js.map +1 -0
- package/dist/sync/filesystem.d.ts +37 -0
- package/dist/sync/filesystem.d.ts.map +1 -0
- package/dist/sync/filesystem.js +205 -0
- package/dist/sync/filesystem.js.map +1 -0
- package/dist/sync/index.d.ts +8 -0
- package/dist/sync/index.d.ts.map +1 -0
- package/dist/sync/index.js +9 -0
- package/dist/sync/index.js.map +1 -0
- package/dist/sync/lines.d.ts +18 -0
- package/dist/sync/lines.d.ts.map +1 -0
- package/dist/sync/lines.js +46 -0
- package/dist/sync/lines.js.map +1 -0
- package/dist/sync/remote.d.ts +145 -0
- package/dist/sync/remote.d.ts.map +1 -0
- package/dist/sync/remote.js +59 -0
- package/dist/sync/remote.js.map +1 -0
- package/dist/sync/state.d.ts +17 -0
- package/dist/sync/state.d.ts.map +1 -0
- package/dist/sync/state.js +40 -0
- package/dist/sync/state.js.map +1 -0
- package/dist/telemetry-ingest/batch.d.ts +73 -0
- package/dist/telemetry-ingest/batch.d.ts.map +1 -0
- package/dist/telemetry-ingest/batch.js +110 -0
- package/dist/telemetry-ingest/batch.js.map +1 -0
- package/dist/telemetry-ingest/facet.d.ts +26 -0
- package/dist/telemetry-ingest/facet.d.ts.map +1 -0
- package/dist/telemetry-ingest/facet.js +100 -0
- package/dist/telemetry-ingest/facet.js.map +1 -0
- package/dist/telemetry-ingest/index.d.ts +5 -0
- package/dist/telemetry-ingest/index.d.ts.map +1 -0
- package/dist/telemetry-ingest/index.js +8 -0
- package/dist/telemetry-ingest/index.js.map +1 -0
- package/dist/telemetry-ingest/recorder.d.ts +50 -0
- package/dist/telemetry-ingest/recorder.d.ts.map +1 -0
- package/dist/telemetry-ingest/recorder.js +298 -0
- package/dist/telemetry-ingest/recorder.js.map +1 -0
- package/dist/telemetry-ingest/sender.d.ts +14 -0
- package/dist/telemetry-ingest/sender.d.ts.map +1 -0
- package/dist/telemetry-ingest/sender.js +64 -0
- package/dist/telemetry-ingest/sender.js.map +1 -0
- package/dist/telemetry-sqlite/index.d.ts +33 -0
- package/dist/telemetry-sqlite/index.d.ts.map +1 -0
- package/dist/telemetry-sqlite/index.js +113 -0
- package/dist/telemetry-sqlite/index.js.map +1 -0
- package/dist/telemetry-sqlite/node.d.ts +13 -0
- package/dist/telemetry-sqlite/node.d.ts.map +1 -0
- package/dist/telemetry-sqlite/node.js +27 -0
- package/dist/telemetry-sqlite/node.js.map +1 -0
- package/dist/telemetry-sqlite/schema.d.ts +9 -0
- package/dist/telemetry-sqlite/schema.d.ts.map +1 -0
- package/dist/telemetry-sqlite/schema.js +61 -0
- package/dist/telemetry-sqlite/schema.js.map +1 -0
- package/dist/telemetry-sqlite/store.d.ts +12 -0
- package/dist/telemetry-sqlite/store.d.ts.map +1 -0
- package/dist/telemetry-sqlite/store.js +121 -0
- package/dist/telemetry-sqlite/store.js.map +1 -0
- package/dist/telemetry.d.ts +1013 -0
- package/dist/telemetry.d.ts.map +1 -0
- package/dist/telemetry.js +518 -0
- package/dist/telemetry.js.map +1 -0
- package/dist/tui/bridge.d.ts +112 -0
- package/dist/tui/bridge.d.ts.map +1 -0
- package/dist/tui/bridge.js +9 -0
- package/dist/tui/bridge.js.map +1 -0
- package/dist/tui/channel.d.ts +44 -0
- package/dist/tui/channel.d.ts.map +1 -0
- package/dist/tui/channel.js +150 -0
- package/dist/tui/channel.js.map +1 -0
- package/dist/tui/frames.d.ts +5 -0
- package/dist/tui/frames.d.ts.map +1 -0
- package/dist/tui/frames.js +52 -0
- package/dist/tui/frames.js.map +1 -0
- package/dist/tui/index.d.ts +8 -0
- package/dist/tui/index.d.ts.map +1 -0
- package/dist/tui/index.js +8 -0
- package/dist/tui/index.js.map +1 -0
- package/dist/tui/runtime.d.ts +46 -0
- package/dist/tui/runtime.d.ts.map +1 -0
- package/dist/tui/runtime.js +101 -0
- package/dist/tui/runtime.js.map +1 -0
- package/dist/tui/scope.d.ts +62 -0
- package/dist/tui/scope.d.ts.map +1 -0
- package/dist/tui/scope.js +173 -0
- package/dist/tui/scope.js.map +1 -0
- package/dist/tui/terminal.d.ts +15 -0
- package/dist/tui/terminal.d.ts.map +1 -0
- package/dist/tui/terminal.js +37 -0
- package/dist/tui/terminal.js.map +1 -0
- package/dist/tui/theme.d.ts +17 -0
- package/dist/tui/theme.d.ts.map +1 -0
- package/dist/tui/theme.js +38 -0
- package/dist/tui/theme.js.map +1 -0
- package/dist/watch.d.ts +194 -0
- package/dist/watch.d.ts.map +1 -0
- package/dist/watch.js +383 -0
- package/dist/watch.js.map +1 -0
- package/dist/web/environment.d.ts +4 -0
- package/dist/web/environment.d.ts.map +1 -0
- package/dist/web/environment.js +37 -0
- package/dist/web/environment.js.map +1 -0
- package/dist/web/index.d.ts +5 -0
- package/dist/web/index.d.ts.map +1 -0
- package/dist/web/index.js +7 -0
- package/dist/web/index.js.map +1 -0
- package/dist/web/language.d.ts +7 -0
- package/dist/web/language.d.ts.map +1 -0
- package/dist/web/language.js +21 -0
- package/dist/web/language.js.map +1 -0
- package/dist/web/page.d.ts +42 -0
- package/dist/web/page.d.ts.map +1 -0
- package/dist/web/page.js +96 -0
- package/dist/web/page.js.map +1 -0
- package/dist/web/scripts.d.ts +23 -0
- package/dist/web/scripts.d.ts.map +1 -0
- package/dist/web/scripts.js +50 -0
- package/dist/web/scripts.js.map +1 -0
- package/dist/web/styles.d.ts +17 -0
- package/dist/web/styles.d.ts.map +1 -0
- package/dist/web/styles.js +218 -0
- package/dist/web/styles.js.map +1 -0
- package/dist/web/themes.d.ts +6 -0
- package/dist/web/themes.d.ts.map +1 -0
- package/dist/web/themes.js +31 -0
- package/dist/web/themes.js.map +1 -0
- package/docs/admission/design.md +178 -0
- package/docs/benchmarks.md +1182 -0
- package/docs/decisions.md +3760 -0
- package/docs/dependencies/book.md +1671 -0
- package/docs/dependencies/index.html +2641 -0
- package/docs/dependencies/model.md +330 -0
- package/docs/design.md +3691 -0
- package/docs/durable-observers/book.md +432 -0
- package/docs/durable-observers/index.html +517 -0
- package/docs/events/spec.md +438 -0
- package/docs/flow-control/book.md +333 -0
- package/docs/flow-control/fold/index.html +265 -0
- package/docs/flow-control/index.html +548 -0
- package/docs/flow-control/window/index.html +228 -0
- package/docs/guide-plugins-hosts/book.md +958 -0
- package/docs/guide-plugins-hosts/index.html +952 -0
- package/docs/host-keyed/spec.md +343 -0
- package/docs/http-workers/book.md +378 -0
- package/docs/http-workers/index.html +515 -0
- package/docs/i18n/book.md +217 -0
- package/docs/i18n/index.html +344 -0
- package/docs/layer-1.md +311 -0
- package/docs/layer-2.md +216 -0
- package/docs/p3-features/README.md +6 -0
- package/docs/p3-features/book.md +478 -0
- package/docs/plugin-authoring.md +389 -0
- package/docs/plugin-model/book.md +186 -0
- package/docs/plugin-model/index.html +310 -0
- package/docs/plugin-primer/book.md +273 -0
- package/docs/plugin-primer/index.html +430 -0
- package/docs/shared-holds/design.md +339 -0
- package/docs/slice-1.md +236 -0
- package/docs/slice-10.md +288 -0
- package/docs/slice-11.md +114 -0
- package/docs/slice-12.md +132 -0
- package/docs/slice-13.md +121 -0
- package/docs/slice-14-design.md +213 -0
- package/docs/slice-14.md +861 -0
- package/docs/slice-2.md +174 -0
- package/docs/slice-3a.md +296 -0
- package/docs/slice-3b.md +197 -0
- package/docs/slice-4.md +146 -0
- package/docs/slice-4a.md +418 -0
- package/docs/slice-4b.md +208 -0
- package/docs/slice-5.md +281 -0
- package/docs/slice-6a.md +676 -0
- package/docs/slice-6b.md +332 -0
- package/docs/slice-7a.md +130 -0
- package/docs/slice-7b/book.md +608 -0
- package/docs/slice-7b/index.html +842 -0
- package/docs/slice-7b.md +255 -0
- package/docs/slice-7c.md +165 -0
- package/docs/slice-8.md +194 -0
- package/docs/slice-9.md +110 -0
- package/docs/slices.md +380 -0
- package/docs/store/book.md +670 -0
- package/docs/store/index.html +861 -0
- package/docs/store/walkthrough.md +193 -0
- package/docs/theming/book.md +223 -0
- package/docs/theming/index.html +371 -0
- package/docs/tutorial/book.md +2170 -0
- package/docs/tutorial/index.html +2112 -0
- package/docs/tutorial/screens/click-after.png +0 -0
- package/docs/tutorial/screens/click-before.png +0 -0
- package/docs/tutorial/screens/edited.png +0 -0
- package/docs/tutorial/screens/french.png +0 -0
- package/docs/tutorial/screens/harbor.png +0 -0
- package/docs/tutorial/screens/page.png +0 -0
- package/docs/tutorial/screens/traces-ada.png +0 -0
- package/docs/tutorial/screens/traces.png +0 -0
- package/package.json +200 -5
- package/src/delta/README.md +262 -0
package/docs/slice-10.md
ADDED
|
@@ -0,0 +1,288 @@
|
|
|
1
|
+
# Slice 10: HTTP and workers (spec)
|
|
2
|
+
|
|
3
|
+
Status: **built** (2026-10-31; build reviews by Fable, Opus, Astra and Sol, security audits by Fable, Opus and Astra, four fix rounds with rechecks; the shape after the fix rounds is in §2, §3 and design §23). Approved by the owner (2026-10-30: "just build it"; D1-D12, D10b, round 1's R1-R6 and round 2's Q1-Q6 in the
|
|
4
|
+
decision "Slice 10's points"; spec reviews round 1 by Fable and Opus, `/tmp/s10-spec-review-{fable,opus}.md`, round 2
|
|
5
|
+
by Fable, Opus, Astra and Sol, `/tmp/s10-spec-review2-*.md`, folded in).
|
|
6
|
+
Slice 10 builds two Node components of the app kit (decision "Slice 7b's open points" (6)): `chord/http` (the
|
|
7
|
+
server's HTTP and WebSocket entry, routes contributed by plugins through a registry, responses as descriptions) and
|
|
8
|
+
`chord/workers` (a worker process per host address, started on demand, stopped when idle, its plugins shipped from
|
|
9
|
+
the server). Both live in `packages/chord/src/node/` (Node-only); the kernel stays portable. The web page host and
|
|
10
|
+
the TUI are slice 11, telemetry slice 9.
|
|
11
|
+
|
|
12
|
+
Read in full before writing code: this spec; `decisions.md`; `design.md` (§3 hosts, routes, `host.activity`, §17,
|
|
13
|
+
§18, §21 "Loading plugins and the reload loop", §23 in full); `slices.md`; `slice-7c.md` and
|
|
14
|
+
`src/node/plugins/README.md`; the 7b brief `slice-7b/book.md` (chapters "Assets and Files", "HTTP", "A Mini p2
|
|
15
|
+
from Chord"); p2's `src/hosts/server.ts`, `src/runtime/server.ts`, `src/hosts/worker.ts`, `src/hosts/socket-limits.ts`,
|
|
16
|
+
`src/hosts/principals.ts`, `plugins/files/server.ts`, `plugins/terminals/server.ts`, `plugins/radius/server.ts`; Chord
|
|
17
|
+
v1's `src/manager.ts` (`processLock`, `forkDriver`, `createHostManager`, `childControl`; v1 has since been deleted).
|
|
18
|
+
|
|
19
|
+
## 1. What p2 has, and what moves into Chord
|
|
20
|
+
|
|
21
|
+
p2's server host (`src/hosts/server.ts`, 742 lines; `src/runtime/server.ts`, 720) does, besides p2's own policy:
|
|
22
|
+
|
|
23
|
+
| p2 today | Moves to |
|
|
24
|
+
| --- | --- |
|
|
25
|
+
| a Node `http` server on loopback, requests parked until `load` resolved, upgrades captured before listening | `http` |
|
|
26
|
+
| `Routes` (`"METHOD /path"`, `/prefix/*`), handlers writing Node's `ServerResponse` themselves (ranges, download headers, `HEAD` by hand in `files`) | `http`: routes returning descriptions |
|
|
27
|
+
| `Upgrades` (a WebSocket by path for terminals and voice), `/chord` (`acceptWebSockets` with per-socket limits) | `http` |
|
|
28
|
+
| `Authenticators`, `RequestResolvers` (cookies, devices, the Radius relay), Fetch Metadata, CSP and the loopback cookie | the app (p3's base code), through `http`'s `authenticate` and `headers` (D3) |
|
|
29
|
+
| loopback and allowed hosts, the `Origin` check on upgrades | `http` (R4), allowed hosts contributable by plugins |
|
|
30
|
+
| `SessionHosts`: a worker per session, `createHostManager` + `forkDriver`, a kernel lock per session, idle stop from reported counts, crash notices, sticky failed starts, ready timeout | `workers` (failures stay until Retry or a rollout, R2) |
|
|
31
|
+
| relocation and pause of a worker, the catalog, `WorkerInitValues` | the app (built on `workers`' `stop` and start data) |
|
|
32
|
+
| `hosts/worker.ts`: the child's control channel, lock, start data, connect, load, report counts, shutdown | `workers`' child side |
|
|
33
|
+
| the dev reload across server and workers, worker plugin lists | `plugins` (7c) plus `workers`' rollout step (§4) |
|
|
34
|
+
|
|
35
|
+
Every option that is not bootstrap is changeable by plugins (decision "The app kit is malleable by plugins"): either a
|
|
36
|
+
contribution to `Http` or a function the component calls per use, which the app backs with its own registries;
|
|
37
|
+
nothing is copied out of a contribution or an option at startup. Bootstrap (changed by a restart): the listen address
|
|
38
|
+
and port, the links path, the worker entry with its `execArgv` and `env`, the host kind workers serve.
|
|
39
|
+
|
|
40
|
+
## 2. `chord/http`
|
|
41
|
+
|
|
42
|
+
As built after the fix rounds (decisions "The HTTP core is a fetch handler", "The HTTP server is a native object",
|
|
43
|
+
"Settings are arguments, extensions are registries", "The HTTP component's security baseline", "allowed hosts only
|
|
44
|
+
through contributions", "A CSP nonce per response", "three small points", "a route's overhead accepted"); design §23
|
|
45
|
+
states every rule, `src/node/http/README.md` the API.
|
|
46
|
+
|
|
47
|
+
```ts
|
|
48
|
+
const http = createHttp(server, {
|
|
49
|
+
listen: { host: "127.0.0.1", port: 8788 }, // settings: arguments, a restart to change
|
|
50
|
+
links: { path: "/chord", options: (request, principal) => ({ limits: linkLimits(principal), maxPayload: 64 * MiB }) },
|
|
51
|
+
closeTimeout: 30_000,
|
|
52
|
+
onError: (error) => log(error), // `HttpError`, below
|
|
53
|
+
}, ctx);
|
|
54
|
+
const app = defineFacet((_host, self) => {
|
|
55
|
+
self.contribute(Authenticators, (request, ctx) => principalFromCookie(readCookie(request, "session", secret)));
|
|
56
|
+
self.contribute(Http, { hosts: ["notes.example.com"], relays: [radiusRelay] });
|
|
57
|
+
});
|
|
58
|
+
await plugins.load(server, { kind: "server", core: [{ name: "chord.http", facet: http.facet }, { name: "@app/core", facet: app }], modules }, ctx);
|
|
59
|
+
…
|
|
60
|
+
await http.close(ctx); // first: no new requests, sockets closed, running requests waited for up to `closeTimeout`
|
|
61
|
+
await workers.close(ctx);
|
|
62
|
+
await server.close(ctx);
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
- **The core** is `http.fetch(request, { localAddress?, localPort?, remoteAddress? })`, a Web `Request` to a Web
|
|
66
|
+
`Response`; `http.upgrade` is Node's upgrade adapter; `nodeRequest(message, res)` converts a Node request with the
|
|
67
|
+
listener's checks (`{ kind: "request", request, connection } | { kind: "refused", status }`, never a throw) for apps
|
|
68
|
+
mounting on their own Node server. Chord's own listener (with `listen`) is a host-lifetime object of `chord.http`
|
|
69
|
+
whose native is a Node server, on a fast path that skips the Web `Request` unless a route or authenticator reads
|
|
70
|
+
it.
|
|
71
|
+
- **Registries:** `Http` (`"chord.http"`, version 1: `routes`, `wraps`, `sockets`, `maxPayload`, `hosts`, `framers`,
|
|
72
|
+
`relays`, `csp`; a value or a writable) and `Authenticators` (in contributor order, the first principal wins).
|
|
73
|
+
Requests before the publication wait for it (503 past `readyTimeout`).
|
|
74
|
+
- **Admission, foreign requests, origins, default headers, cookies, downloads:** the security baseline (design §23).
|
|
75
|
+
Refusals before any plugin code: a non-loopback socket without an allowed host, forwarded headers without a
|
|
76
|
+
verified relay, duplicate or missing `Host`, userinfo in `Host`, absolute-form targets (403), unparsable targets
|
|
77
|
+
(400), `TRACE`/`TRACK`/`CONNECT` (501; a route for them refused at compose).
|
|
78
|
+
- **A request's scope, `HttpRequest`, patterns, wraps, responses, `fileResponse`, sockets, links, revocation,
|
|
79
|
+
`close`:** design §23. The spec's earlier text (an `httpServer` that listens first, `allowedHosts`, one
|
|
80
|
+
`authenticate` and a `headers` option, 64 KiB reads) is superseded by those decisions.
|
|
81
|
+
- **Errors** (`onError`, `HttpError`): `route_failed { pattern, plugin, error }`, `wrap_failed { name, plugin, error }`,
|
|
82
|
+
`socket_failed { pattern, plugin, error }`, `response_failed { pattern, error }`, `hook_failed { hook, plugin?,
|
|
83
|
+
error }` (`authenticate`, `relay`, `links.options`).
|
|
84
|
+
- `ws` is an optional peer dependency (D7), imported only here.
|
|
85
|
+
|
|
86
|
+
## 3. `chord/workers`
|
|
87
|
+
|
|
88
|
+
```ts
|
|
89
|
+
// server.ts
|
|
90
|
+
const workers = createWorkers(server, Session, {
|
|
91
|
+
kind: "worker", // the facet kind it ships
|
|
92
|
+
entry: "./worker.ts", execArgv: ["--import", resolver], env: { … }, // bootstrap
|
|
93
|
+
authorize: (principal, address) => app.mayReach(principal, address), // the route's `authorize` (synchronous)
|
|
94
|
+
principal: (address) => ({ kind: "worker", session: address.params.id }),
|
|
95
|
+
start: (address, ctx) => app.startData(address, ctx), // JSON, before each start
|
|
96
|
+
lock: (address) => `app:${realpath(dataDir)}:worker:${address.key}`, // one live worker per address
|
|
97
|
+
idleMs: () => app.idleMs(),
|
|
98
|
+
plugins, // the plugins component
|
|
99
|
+
onOutput: (address, stream, chunk) => logs.append(address.key, stream, chunk),
|
|
100
|
+
onError: (error) => log(error), // `WorkersError`, below
|
|
101
|
+
}, ctx);
|
|
102
|
+
workers.state // JSON watchable (R5)
|
|
103
|
+
await workers.stop(Session({ id }), ctx); // archive: suspended while held (Q3), then stopped
|
|
104
|
+
await workers.retry(Session({ id }), ctx); // the Retry button: a failed or suspended address resolves again
|
|
105
|
+
await workers.close(ctx); // no new starts, every child stopped
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
```ts
|
|
109
|
+
// worker.ts
|
|
110
|
+
await workerMain(async ({ address, start, parent, plugins, onClose }, ctx) => {
|
|
111
|
+
const store = await openStore(sqliteBackend(await openNodeSqliteDatabase(join(start.dir, "session.sqlite"))), ctx);
|
|
112
|
+
onClose((ctx) => store.close(ctx)); // closers run in reverse order
|
|
113
|
+
const worker = createHost<P>({ address, principal: { kind: "worker", session: start.id }, store, onError });
|
|
114
|
+
onClose((ctx) => worker.close(ctx));
|
|
115
|
+
worker.connect(parent, { principal: { kind: "server" }, trusted: true }, ctx); // `started` goes out now: connect
|
|
116
|
+
// before anything slow (a store opens in ms)
|
|
117
|
+
await plugins.load(worker, { kind: "worker", core: [{ name: "@app/core", facet: coreWorker(start) }] }, ctx);
|
|
118
|
+
return { busy: harness.activeTasks }; // extra keep-alive counts
|
|
119
|
+
}, {
|
|
120
|
+
hostPackages: { "@diffra-ai/chord": chord, "@app/core": appCore }, // the child's own instances
|
|
121
|
+
redact: (error) => ({ message: redactSecrets(String(error)), ...codeOf(error) }), // what crosses as `fatal`
|
|
122
|
+
onError: (error) => log(error),
|
|
123
|
+
});
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
- **The route:** `createWorkers` calls `host.route(Kind, { authorize, resolve }, ctx)` itself and keeps the
|
|
127
|
+
`RouteHandle` (`retry`, `suspend`: D10b, R1). `authorize` is synchronous (the kernel's): a plugin backing it keeps an
|
|
128
|
+
index.
|
|
129
|
+
- **Per address, events and operations:** a child's events (its exit, its link's close, `started`, `ready`, `fatal`)
|
|
130
|
+
are observed as they happen and recorded at once on that child (a late event of an old child never changes a new
|
|
131
|
+
one); the operations (start, stop) run in one queue per address: a start waits for the previous child's exit, a
|
|
132
|
+
stop during a start waits for it then stops, and a start queued behind an exit checks the address's state after it
|
|
133
|
+
(a crash recorded meanwhile makes it reject with that failure). Stops record their intent before `shutdown`, so the
|
|
134
|
+
exit they cause is no crash.
|
|
135
|
+
- **A start** (`resolve(address)`): calls `start(address, ctx)` (abortable; a throw rejects the start), checks that the
|
|
136
|
+
component is not closing, forks `entry` (`serialization: "advanced"`, a detached process group, stdout and stderr
|
|
137
|
+
piped: the stderr tail kept, mirrored to the server's when there is no `onOutput`), makes `ipcLink(child)` at once
|
|
138
|
+
(so the child's `hello` and early holds are queued, never lost), and sends the start message `{ address, start,
|
|
139
|
+
scripts, lock }` (`scripts`: the worker kind's complete current set, read when the message is sent). The child takes
|
|
140
|
+
the lock (when an old worker still holds it, it waits by connecting to the lock's socket and trying again when that
|
|
141
|
+
connection closes: no polling), and sends `started` when the app's host sets its listener on `parent` (`parent` is
|
|
142
|
+
a thin wrapper of the IPC link, so `connect` is the signal: the app connects before anything slow). `resolve` then
|
|
143
|
+
returns `{ link, principal: principal(address), trusted: true }`, and the handshake and the worker's server traffic
|
|
144
|
+
run during its `load`. The start timer (60 s from the fork) covers fork, lock and connect only (Q4): past it the tree is
|
|
145
|
+
killed and the start fails. `ready` (after the app's function returned, carrying the idle state and its load report) sets `state` to
|
|
146
|
+
`running` and lets idle stops begin; a `load` that never ends shows `starting` until `stop`.
|
|
147
|
+
- **Workers never restart by themselves** (R2): a crash (an exit nobody asked for), a `fatal`, or a failed start
|
|
148
|
+
(`start` threw, the start timer, a lock not taken in time) leaves the address `failed` with its error
|
|
149
|
+
(`worker_failed` reported once). A link lost while its child lives (the heartbeat after a blocked event loop, a
|
|
150
|
+
protocol error, the child closing its own link) starts the stop: the grace (5 s), then the tree is killed. After
|
|
151
|
+
`ready` that exit is no failure (decision "A lost worker link is recovered from", 2026-11-03): `worker_link_lost`
|
|
152
|
+
is reported and the held route resolves again, a new worker; a second within a minute of the address's last
|
|
153
|
+
recovery fails it (`worker lost its link`), as does one before `ready`. `resolve` of a failed address rejects at once with that error; its holders and new holds see `failed {
|
|
154
|
+
waiting }` with it as cause (Q1) and stay on the address's path, nothing forks. `workers.retry(address)`
|
|
155
|
+
(`RouteHandle.retry`) or a rollout reaching workers clears it (Q2, §4). An idle stop is no failure: the next hold
|
|
156
|
+
starts the worker on demand.
|
|
157
|
+
- **Keep-alive** (D9, R3, Q5): the child's idle state is all of `host.activity`'s `references`, `jobs` and `lingering`
|
|
158
|
+
and the app's `busy` (a JSON watchable of numbers) at zero, not `calls` (a remote call runs on a hold; local calls
|
|
159
|
+
come from routines, jobs and tasks counted elsewhere). `ready { idle }` carries the first state, then `{ idle }` on
|
|
160
|
+
each flip; a rollout applying in the child counts as busy. The server stops a worker idle since `idleMs()` (5 min by
|
|
161
|
+
default; checked every second), never before `ready`. A stop (idle, `stop`, `close`): `shutdown`; the child aborts its
|
|
162
|
+
`ctx`, runs the closers registered with `onClose` in reverse order and exits, forcing its own exit after 3 s; the
|
|
163
|
+
server kills the tree after 5 s.
|
|
164
|
+
- **`state`** (R5, decision "worker errors in public"): per address key `{ status: "starting" | "running" |
|
|
165
|
+
"stopping", pid, startedAt }` or `{ status: "failed", error: { message, code?, reason? }, at }` with a public error
|
|
166
|
+
(a fixed message, or the child's redacted `fatal`); no entry when stopped or never started. The full error and the
|
|
167
|
+
stderr tail go only to `onError` (`worker_failed`); every app hook of a start (`start`, `principal`, `lock`, the
|
|
168
|
+
fork) is inside that boundary.
|
|
169
|
+
- **`stop(address, ctx)`** (R1, Q3): `RouteHandle.suspend(address)`, then the stop. The suspension lasts while the
|
|
170
|
+
address has holders (they see `failed { waiting }`, "suspended"); with the last holder it goes, and a later hold
|
|
171
|
+
starts the worker on demand; `retry(address)` lifts it at once. Whether an archived session may be opened is the
|
|
172
|
+
app's (`authorize`, its views).
|
|
173
|
+
- **`close(ctx)`:** cancels active and queued starts first (a `start(address)` waiting on the app's barrier is
|
|
174
|
+
aborted; nothing forks after it), then stops every child (grace, then kill), clears the timers; new starts reject
|
|
175
|
+
`released/closed`; the caller's cancellation ends only its own wait. `createWorkers`'s `ctx` aborting (the host
|
|
176
|
+
closing aborts the route's context) closes it too, and from then on every exit is a stop, never a crash (no
|
|
177
|
+
`worker_failed` at shutdown).
|
|
178
|
+
- **The child** (`workerMain(fn, { hostPackages, redact, onError })`): reads the start message, takes the lock, makes
|
|
179
|
+
`ipcLink(process)` and its wrapper `parent`, creates its plugin runtime with `hostPackages` (the child's own module
|
|
180
|
+
instances; functions cannot cross IPC), calls `fn({ address, start, parent, plugins, onClose }, ctx)`. `shutdown`,
|
|
181
|
+
the parent's disconnect, `SIGTERM` and `SIGINT` alike abort `ctx` and run the closers registered so far, also while
|
|
182
|
+
`fn` still runs (its startup is cancelled through `ctx`). An uncaught error, or `fn` throwing, sends `fatal` with
|
|
183
|
+
`redact(error)` (never the original message) and exits; after `started` that is a crash like any other.
|
|
184
|
+
- **Control messages** (JSON beside the link's `Uint8Array` frames; the IPC link skips them): parent to child `start`,
|
|
185
|
+
`shutdown`, `reload { scripts }`; child to parent `started`, `ready { idle }`, `idle { idle }`, `fatal { error }`,
|
|
186
|
+
`reloaded { report } | { error }`. One `reload` is outstanding per child at a time: a reload whose caller aborted
|
|
187
|
+
keeps the child's slot until its `reloaded` or the child's exit, and the next waits for it. Errors cross as `{
|
|
188
|
+
message, code?, reason? }`.
|
|
189
|
+
- **Errors** (`onError`, `WorkersError`, which includes `BatchError` for a `state` watch listener that throws): `worker_failed { address, error, stderrTail? }` (private),
|
|
190
|
+
`authorize_failed { address, error }` (a throwing `authorize`: the hold is refused `forbidden`), `worker_exited {
|
|
191
|
+
address, code, signal }` (only for an exit nobody asked for: not after a stop or a start the component failed),
|
|
192
|
+
`worker_link_lost { address, error }` (a running worker's lost link recovered from).
|
|
193
|
+
|
|
194
|
+
### Plugins in workers (D11)
|
|
195
|
+
|
|
196
|
+
Workers never build. The plugins component (7c) gets `scripts(kind, ctx)`: the complete current set of one kind (every
|
|
197
|
+
discovered plugin's facet of it, built on first use, then updated by every rollout that ships that kind), each with its
|
|
198
|
+
plugin record (`name`, `dir`, `chord.external`). The component's per-host loading (its loaded map, `#prepare`, `adopt`,
|
|
199
|
+
the queue per host) moves into a file without esbuild or the watcher, `createPluginRuntime()`
|
|
200
|
+
with `load(host, { kind, core, scripts, modules }, ctx)` (`modules`: the host packages' module objects of this process) and `reload(host, scripts, ctx)` (a complete set: removed = loaded −
|
|
201
|
+
shipped; same digests unchanged); `createPlugins` uses it, and the child's `plugins` is a `WorkerPlugins` over one
|
|
202
|
+
(`load(host, { kind, core })` loads the start message's scripts; `reload` messages wait until `fn` returned); `import`
|
|
203
|
+
of `chord/plugins/runtime` loads no esbuild. Each kind is defined once in `createPlugins({ kinds: { <kind>: {
|
|
204
|
+
platform, hostPackages } } })` (decision "Slice 11's points", Kinds).
|
|
205
|
+
|
|
206
|
+
## 4. The rollout across server and workers
|
|
207
|
+
|
|
208
|
+
```ts
|
|
209
|
+
const built = await plugins.build(plugins.state.value.dirty, ctx);
|
|
210
|
+
const result = await plugins.rollout([plugins.step("server", server), workers.step("workers")], built, ctx);
|
|
211
|
+
// result.steps: [{ name: "server", hosts: [{ host: "server", report }] },
|
|
212
|
+
// { name: "workers", hosts: [{ host: "session|S1", report }, { host: "session|S2", stopped: true },
|
|
213
|
+
// { host: "session|S3", error }] }]
|
|
214
|
+
```
|
|
215
|
+
|
|
216
|
+
`RolloutStep.reload(built, ctx)` returns `{ hosts: readonly ({ host; report } | { host; stopped: true } | { host; error
|
|
217
|
+
})[] }` (D12; 7c's in-process step returns a list of one, its `host` the name given to `step`). `workers.step(name)`:
|
|
218
|
+
|
|
219
|
+
1. replaces the workers' current set (`plugins.scripts(kind)` updated from `built`);
|
|
220
|
+
2. clears the failures recorded before this rollout and calls `RouteHandle.retry` for those addresses that have holders
|
|
221
|
+
(Q2): they start with the new set and are listed; an unheld one starts at its next hold;
|
|
222
|
+
3. ships the complete set to every running or starting worker whose start message or last reload carried an older one
|
|
223
|
+
(a child queues a reload that arrives before its `ready` until its load is done); workers reload in parallel.
|
|
224
|
+
|
|
225
|
+
A worker's entry settles on its `reloaded` or on its exit or link loss, whichever comes first. A worker stopped cleanly
|
|
226
|
+
during the step (idle, `stop`) is listed `stopped` and dirties nothing (its next start gets the current set); one that
|
|
227
|
+
crashed or failed to apply is listed with its error and does not stop the rollout, and every plugin of its kind in the
|
|
228
|
+
build counts as failed there (stays dirty); a worker failing during this rollout stays failed. A plugin's dirty mark
|
|
229
|
+
clears only when it applied on every host of every step, and a kind built in the rollout that no step shipped keeps its
|
|
230
|
+
plugins dirty.
|
|
231
|
+
|
|
232
|
+
## 5. Not in slice 10
|
|
233
|
+
|
|
234
|
+
The web page host, the browser's evaluation of scripts and serving them (slice 11); the TUI (slice 11); relocation and
|
|
235
|
+
pause of workers (the app's: `start(address)` is where the app awaits its own barrier); request resolvers and
|
|
236
|
+
authenticators as registries (the app's); chunked transfers as a Chord helper (an owner pattern, design §23); the
|
|
237
|
+
channel component (D6); telemetry spans for requests (slice 9).
|
|
238
|
+
|
|
239
|
+
## 6. Kernel changes
|
|
240
|
+
|
|
241
|
+
- `host.route(Kind, options, ctx)` returns a `RouteHandle { retry(address), suspend(address) }` (D10b, R1, Q3).
|
|
242
|
+
- A route has no backoff timer (R2): a rejected `resolve`, or a link that closes before its handshake completed, fails
|
|
243
|
+
the route's holders `failed { waiting }` with its error (they stay on the address's path, Q1) and resolves nothing
|
|
244
|
+
more; the route resolves again only for a new hold, on `retry`, or once after a link that had completed its handshake
|
|
245
|
+
dropped while holds exist; a suspended address resolves nothing while it has holders and forgets the suspension with
|
|
246
|
+
the last one.
|
|
247
|
+
- `host.root(fn, ctx, { principal: undefined })` runs anonymous (`ctx.principal` undefined); only an omitted
|
|
248
|
+
`principal` takes the host's (a public-API change of `RootOptions`: `"principal" in options`).
|
|
249
|
+
- Origins only from relays (decision, 2026-10-31, security audit): `origin` is read only on parent and route links;
|
|
250
|
+
on a child link it is a protocol error; a per-origin record goes once it has no holds, calls or messages in flight.
|
|
251
|
+
- An anonymous `host.root` scope gets no remote object served on its host (`forbidden`).
|
|
252
|
+
- Design §3: the paragraph on a `resolve` waiting for the worker's `load` is updated (done), and "Chord never closes a
|
|
253
|
+
route link itself except at `host.close`" becomes "except at `host.close`, the heartbeat and protocol errors".
|
|
254
|
+
|
|
255
|
+
## 7. Tests, examples, cost
|
|
256
|
+
|
|
257
|
+
- One test file per source file. HTTP: listening before the publication (a request waits, then is served; 503 past
|
|
258
|
+
`readyTimeout`); the router resolved once; `Host` (loopback forms, allowed from the option and from a writable
|
|
259
|
+
contribution changing at runtime) and `Origin` checks; anonymous requests (`ctx.principal` undefined on a server with
|
|
260
|
+
a principal); authentication per request and upgrade; throwing hooks; patterns, decoding, precedence, `HEAD`, 404;
|
|
261
|
+
conflicts reported; wraps (phases, order, scopes, a missing route, a throwing wrap); every response kind (ranges
|
|
262
|
+
206/416, multi-range, `HEAD`, download names, chunked without `size`, a short `read`, a disconnect stopping `read`,
|
|
263
|
+
header merging); `json`/`body` limits and their statuses, an unread body; a throwing route; the links endpoint
|
|
264
|
+
(`host.accept`, options per socket, a refused socket, the output cap); plugin sockets (an oversized frame closes only
|
|
265
|
+
that socket; a reload removing the contribution closes its sockets 1012); a removed allowed host closing its
|
|
266
|
+
connections; a reload swapping a route while a request runs on the old router; `fileResponse` closing its handle on
|
|
267
|
+
every path; `close` (refusals, waiting, then sealing). Workers: a start on the first hold; the link made at the fork
|
|
268
|
+
(a load longer than the heartbeat's 30 s binds); `started` on `connect`; the start timer covering only the start (a
|
|
269
|
+
slow `load` is not killed); the lock (an old worker's lock waited for without polling); `start` throwing; a crash,
|
|
270
|
+
a `fatal`, a link lost with a live child (killed after the grace), and a failed start each staying failed (no fork for
|
|
271
|
+
a new hold; holders `failed { waiting }`), `retry` and a rollout clearing them and rebinding the holders; idle stop,
|
|
272
|
+
a worker idle from its start, a hold keeping it; `busy`; 1,000 sequential local calls sending no message;
|
|
273
|
+
`stop` with holders (suspended, then forgotten with the last holder); stop during start and start during stop; a
|
|
274
|
+
crash while a resolve is queued; `close` (cancelling a start waiting in `start(address)`, no `worker_failed` at
|
|
275
|
+
shutdown); the rollout step (complete sets, a worker starting during it, a clean stop listed `stopped`, a crash during
|
|
276
|
+
it, an aborted reload's late reply, a kind no step shipped staying dirty); the child's shutdown during its startup,
|
|
277
|
+
disconnect and signals; `redact` (a secret in the original message reaches neither `fatal` nor `state`). Kernel:
|
|
278
|
+
`RouteHandle.retry` and `suspend`; a link closing before its handshake (no re-resolve loop); no re-resolve without a
|
|
279
|
+
hold, a retry or one drop of a healthy link; `host.root` with an explicit `undefined` principal.
|
|
280
|
+
- GC: requests (their scopes, bodies, file handles) and stopped workers' state collected; no listener left on a closed
|
|
281
|
+
socket; 1,000 addresses started and stopped leave no `state` entries, no per-address queue records and no
|
|
282
|
+
suspensions.
|
|
283
|
+
- Examples (each a folder, as 7c's): `40-http` (routes, a wrap, a download with ranges, a socket, an allowed host
|
|
284
|
+
added at runtime), `41-workers` (a server routing a session kind to forked workers, idle stop, a crash staying failed
|
|
285
|
+
until Retry, a rollout reaching the workers and restarting a held failed one).
|
|
286
|
+
- Benchmark: a route's overhead per request against a plain Node handler (bar: within 10% of a keep-alive round
|
|
287
|
+
trip; Opus measured 2.5 µs of 54 µs); `bytes` throughput for a 100 MiB file against `pipeline`; a worker's cold start
|
|
288
|
+
(fork to `started` and to `ready`) with shipped scripts; memory per idle worker on the server.
|
package/docs/slice-11.md
ADDED
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
# Slice 11: web and TUI surfaces (spec)
|
|
2
|
+
|
|
3
|
+
Status: **approved** (owner, 2026-10-30/11-01: P1-P9 in the decisions "Slice 11's points" and "Slice 11, P3" to "P9",
|
|
4
|
+
then "go ahead, just do all the things"). Built after slices 12 and 13: the surfaces are generic plumbing that the app
|
|
5
|
+
kit wires in (`startApp` serves the web surface; a TUI client entry). The app keeps everything visible: HTML shell,
|
|
6
|
+
CSS, components, themes, navigation, layout, keys.
|
|
7
|
+
|
|
8
|
+
Read in full before writing code: this spec; `decisions.md` (slice 11's entries, the plugin model, the app kit);
|
|
9
|
+
`design.md` §3 (clients), §21, §23 (all, "Web and TUI" included); `slice-10.md`, `slice-12.md`, `slice-13.md`; p2's
|
|
10
|
+
`src/hosts/web.ts`, `src/hosts/web/main.tsx`, `src/web/reconnect.ts`, `src/runtime/web.tsx`, `src/hosts/bundles.ts`,
|
|
11
|
+
`src/hosts/tui.ts`, `src/hosts/tui-client.ts`, `src/hosts/tui-sandbox.ts`, `src/hosts/tui-bootstrap.mjs`,
|
|
12
|
+
`src/hosts/tui-worker-runtime.ts`, `src/runtime/tui.ts` (`TuiScope`).
|
|
13
|
+
|
|
14
|
+
## 1. `chord/surfaces` (the web surface's server side)
|
|
15
|
+
|
|
16
|
+
```ts
|
|
17
|
+
// inside startApp (slice 13), or by hand:
|
|
18
|
+
const web = webSurface(server, {
|
|
19
|
+
kind: "web", plugins,
|
|
20
|
+
entry: "./src/web/main.tsx", // the app's web start code: the base bundle's entry
|
|
21
|
+
page: (request, assets) => shell(request.nonce, assets), // the app's HTML; assets: base script, plugins file, styles
|
|
22
|
+
}, ctx);
|
|
23
|
+
// its facet (routes to Http, the WebScripts object) goes into the server's core facets
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
- **Base bundle** per client kind: built on the server by esbuild from `entry`, with the kind's host packages inlined
|
|
27
|
+
once (the app's API modules for the kind, Chord, React), content-hashed (`/_chord/web/base.<hash>.js`), cached
|
|
28
|
+
forever (`Cache-Control: immutable`, overriding the baseline's `no-store` for these routes only); rebuilt when base
|
|
29
|
+
code changes (the server restarts anyway: built at start).
|
|
30
|
+
- **Plugin scripts:** each web facet served as a script that registers itself (`chordFacet("<plugin>", "<digest>",
|
|
31
|
+
function (require, module, exports) { … })`, P2), at `/_chord/web/plugin/<plugin>.<digest>.js`, immutable; the
|
|
32
|
+
current set as one combined file `/_chord/web/plugins.<set-hash>.js` (P3); stylesheets and assets of the build
|
|
33
|
+
likewise, under `publicPath`.
|
|
34
|
+
- **`WebScripts`** (a `remote` object the surface serves, params `{}`, any principal that may load the app): its state
|
|
35
|
+
is the current set `{ plugins: [{ name, digest, url, css? }], base }`; a rollout that ships the web kind updates it
|
|
36
|
+
(the plugins component's `scripts("web")` changes; the surface follows them) without waiting for pages (P5).
|
|
37
|
+
- Routes and the page are `Http` contributions of the surface's facet; the page route is `page: true` (navigation from
|
|
38
|
+
another site allowed) and public or not as the app says.
|
|
39
|
+
|
|
40
|
+
## 2. `chord/web` (browser side)
|
|
41
|
+
|
|
42
|
+
```ts
|
|
43
|
+
// src/web/main.tsx (the app's entry, in the base bundle)
|
|
44
|
+
startPage<P>({
|
|
45
|
+
connect: () => new WebSocket(`${location.origin.replace(/^http/, "ws")}/chord`),
|
|
46
|
+
modules: { "@acme/app/v3": api, "@acme/app/v3/web": apiWeb, react: React, "react/jsx-runtime": jsx },
|
|
47
|
+
core: [{ name: "@acme/web", facet: webCore }],
|
|
48
|
+
canRetry: async () => true,
|
|
49
|
+
onConnection: (state) => setBanner(state),
|
|
50
|
+
render: (host) => createRoot(document.getElementById("root")!).render(<HostProvider host={host}><App /></HostProvider>),
|
|
51
|
+
});
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
- A client host (no address); the connection loop (P6, p2's `keepConnected`: reconnect 250 ms to 5 s, wake on
|
|
55
|
+
visibility, `online` and network change, replace a silent socket, stop on an outdated protocol (reload the page) or
|
|
56
|
+
when `canRetry` says no); `onConnection` reports `connecting | connected | waiting`.
|
|
57
|
+
- Loads the combined plugins file, evaluates each registered facet with `modules` (the `require` they get answers only
|
|
58
|
+
host packages and `@diffra-ai/chord/plugins`'s browser half if any), loads them with `core` in one
|
|
59
|
+
`host.load`, then holds `WebScripts`: on a new set it fetches the changed scripts (`<script src>`, one each), and
|
|
60
|
+
calls `host.reload` with the complete set (P4: in place; a failed plugin keeps its old facet, reported to the app);
|
|
61
|
+
a changed `base` hash reloads the page.
|
|
62
|
+
- CSP: scripts are `'self'` plus the nonce for the page's inline bootstrap; no `eval`.
|
|
63
|
+
|
|
64
|
+
## 3. `chord/react`
|
|
65
|
+
|
|
66
|
+
`HostProvider`, `useHost()`, `useHold(Type, params)` (a reference held for the component's life, released on unmount,
|
|
67
|
+
re-held when params change), `useWatch(watchable)` (the current value, re-rendering on change; `useSyncExternalStore`),
|
|
68
|
+
`useRegistry(R)`, `useRefState(ref)`. A component unmounted by a reload has not left (design §21): releases are plain
|
|
69
|
+
releases, presence is the app's. No components, no styling.
|
|
70
|
+
|
|
71
|
+
## 4. `chord/tui` and `chord/tui/launcher`
|
|
72
|
+
|
|
73
|
+
- **Launcher** (trusted, a Node process): `startTerminal({ url, token | tokenFile, pairing?, ... })` connects (a token
|
|
74
|
+
from the owner token file, slice 13, or device pairing), downloads the base bundle and the TUI kind's plugin scripts
|
|
75
|
+
over HTTP, and starts the **sandbox**: a child process on pipes (decision "The terminal's sandbox is a child
|
|
76
|
+
process", replacing p2's worker thread: empty environment, Node's permission model granting nothing, no SQLite; no
|
|
77
|
+
terminal, file system, child processes or network except the bridge), always (P8), whose runtime gets a
|
|
78
|
+
bridge terminal (input events in, frames out), the Chord link (messages relayed by the launcher) and the evaluated
|
|
79
|
+
scripts. The launcher keeps credentials, the real terminal and local preferences, and exposes a small set of actions
|
|
80
|
+
to the sandbox (clipboard, open URL), each confirmed by the launcher's own UI when it touches the machine.
|
|
81
|
+
- **Runtime** (inside the sandbox, in the base bundle): a client host like the page's, the same connection loop over
|
|
82
|
+
the bridged link, in-place reloads through a `TuiScripts` object as the web.
|
|
83
|
+
- **`TuiScope`** (P9): `new TuiScope(host, changed)` with `hold`, `watch`, `registry`, `dispose`; no diffra-tui dependency.
|
|
84
|
+
|
|
85
|
+
## 4b. Looks and themes (decision "Looks and themes", `docs/theming/`)
|
|
86
|
+
|
|
87
|
+
- The kit ships `Themes` (`defineRegistry<Theme, readonly Theme[]>`, in the shared module the kit's apps re-export),
|
|
88
|
+
`Theme = { id, name, mode: "dark" | "light", colors: { accent, bg, fg, muted, error, warning, success, ...app roles },
|
|
89
|
+
web?, tui? }`, and a `themes` preference per user (`{ dark, light }` theme ids) stored by the kit's users plugin or a
|
|
90
|
+
local object for single-user apps.
|
|
91
|
+
- Web: `startPage` watches `Themes` and the preference with `prefers-color-scheme`, and writes the active theme as CSS
|
|
92
|
+
variables on `:root` (`--accent`, ..., plus `web` extras), with no reload; the base bundle's stylesheet is the app's.
|
|
93
|
+
- TUI: `TuiScope`'s host gets a `theme` lookup by role (true colour, else the nearest of 256 colours, `tui` overrides
|
|
94
|
+
first).
|
|
95
|
+
- CSS modules (`*.module.css`) work in plugin builds (esbuild's local-css loader); documented in `plugin-authoring.md`.
|
|
96
|
+
- Version 1 of `Themes`; a later role is added by a version bump mapping old entries (missing roles from the default
|
|
97
|
+
theme).
|
|
98
|
+
|
|
99
|
+
## 5. In the app kit
|
|
100
|
+
|
|
101
|
+
`startApp` gains `web: { entry, page }` and `tui: { entry }` (optional); with them it creates the surfaces and adds
|
|
102
|
+
their facets. Without, an app has no web or TUI surface (an API-only app).
|
|
103
|
+
|
|
104
|
+
## 6. Tests, examples
|
|
105
|
+
|
|
106
|
+
- One test file per source file. Web server side: the base bundle (hash, immutable, rebuilt per start), plugin
|
|
107
|
+
scripts and the combined file (registration wrapper, no eval, digests), `WebScripts` updated by a rollout, the page
|
|
108
|
+
route and CSP. Browser side under jsdom or a real browser (the repo's browser smoke setup, if it fits): the loop
|
|
109
|
+
(backoff, wake events, outdated protocol, `canRetry`), loading the combined file, an in-place reload keeping a
|
|
110
|
+
component's state, a base change reloading. React hooks (hold released on unmount, watch re-render, registry).
|
|
111
|
+
TUI: the sandbox cannot read a file or spawn a process (a test plugin that tries), the bridge, an in-place reload,
|
|
112
|
+
`TuiScope` disposal; pairing a TUI client against a kit app.
|
|
113
|
+
- Examples: `56-web` (a kit app with a page, two web plugins, an edit applied in place), `57-tui` (a kit app with a
|
|
114
|
+
TUI client, sandboxed), `58-themes` (a theme plugin restyling a page and a TUI live).
|
package/docs/slice-12.md
ADDED
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
# Slice 12: the plugin model (spec)
|
|
2
|
+
|
|
3
|
+
Status: **approved** (owner, 2026-11-01: the plugin model's decisions, then "go ahead, just do all the things"; this
|
|
4
|
+
spec written by the redesign session from them, no separate spec review). Builds on 7c's plugins component
|
|
5
|
+
(`src/node/plugins/`) and slice 10's kinds and `createPluginRuntime`.
|
|
6
|
+
|
|
7
|
+
Read in full before writing code: this spec; `decisions.md` entries of 2026-11-01 "Contracts come from where the
|
|
8
|
+
plugin's code came from", "Plugins import only the app's versioned API", "The plugin model, points 3, 4, 5 and 8,
|
|
9
|
+
imports and builds", "Single-file plugins", "Testing a plugin alone"; `design.md` §21 (all of it, "The plugin model"
|
|
10
|
+
included) and §16-§17; `slices.md` (carry-over "Slice 12"); `slice-7c.md`, `slice-10.md` §3 "Plugins in workers";
|
|
11
|
+
`src/node/plugins/README.md` and its sources; the primer `docs/plugin-primer/book.md`.
|
|
12
|
+
|
|
13
|
+
## 1. The app's API (`createPlugins` option `api`)
|
|
14
|
+
|
|
15
|
+
```ts
|
|
16
|
+
const plugins = createPlugins({
|
|
17
|
+
roots: [{ path: "./plugins", required: true }, { path: join(dataDir, "plugins") }],
|
|
18
|
+
api: { name: "@acme/app", versions: ["v3", "v2"] }, // newest first
|
|
19
|
+
kinds: {
|
|
20
|
+
server: { platform: "node", hostPackages: ["@acme/app/v3", "@acme/app/v3/server", "@acme/app/v2"] },
|
|
21
|
+
worker: { platform: "node", hostPackages: ["@acme/app/v3", "@acme/app/v3/worker", "@acme/app/v2"] },
|
|
22
|
+
web: { platform: "browser", hostPackages: ["@acme/app/v3", "@acme/app/v3/web", "@acme/app/v2", "react", "react/jsx-runtime"] },
|
|
23
|
+
},
|
|
24
|
+
onError,
|
|
25
|
+
}, ctx);
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
- `api` names the app's API package and the versions it provides. A plugin import of `<name>/<version>[/<kind>]`:
|
|
29
|
+
a version not listed is a build error naming the listed ones ("@acme/app/v1 is not available: this app provides v3,
|
|
30
|
+
v2"); a listed one that the kind's `hostPackages` lacks (`@acme/app/v3/web` from a worker facet) is a build error
|
|
31
|
+
naming the kind. One facet's imports of the API all use one version (a mix is a build error naming both).
|
|
32
|
+
- Chord itself (`@diffra-ai/chord` and its subpaths other than `/plugins`, which stays as in 7c for
|
|
33
|
+
`pluginFile`) is not importable by plugins: a build error pointing to the app's API. Apps that do not set `api` keep
|
|
34
|
+
7c's behaviour (host packages as listed), so Chord's own tests and examples keep importing Chord directly where they
|
|
35
|
+
model base code.
|
|
36
|
+
- `roots` entries may be strings (as today) or `{ path, required? }`. A plugin of a required root whose build,
|
|
37
|
+
evaluation or setup fails at `plugins.load` makes `load` reject (`PluginError` naming it), after the host's own load
|
|
38
|
+
settled; failures in other roots are reported as today. At a reload, a required plugin failing keeps its old code as
|
|
39
|
+
any plugin (reported).
|
|
40
|
+
|
|
41
|
+
## 2. Imports between plugins (replaces slice 10's by-name lookup)
|
|
42
|
+
|
|
43
|
+
- **Relative paths within a root:** an import from one plugin into another plugin's directory under the same root
|
|
44
|
+
(`../notes/contract.ts`) is inlined (listed in `copied`), the copied file under 7c's rule (only host packages and
|
|
45
|
+
files of its own plugin). A relative path leaving the root (base code, another root) is a build error naming the file
|
|
46
|
+
and pointing to the API or a dependency. A git checkout of several plugins cloned into a root is "within a root".
|
|
47
|
+
- **Package names across repositories:** an import of a package in the plugin's `dependencies` resolves as npm does
|
|
48
|
+
through that package's `exports` (`@bob/notes` → its `contract.ts`, `@bob/notes/web` → `contract.web.tsx`), inlined
|
|
49
|
+
at the installed version. A dependency may be an npm version or a git URL with a ref (`github:bob/notes#<commit>`,
|
|
50
|
+
`git+https://...#<tag>`); `installDependencies` installs it with npm as today. A plugin inside a multi-plugin
|
|
51
|
+
repository is reached through a dependency on the whole repository, by path into it (`@bob/plugins/notes/contract.ts`)
|
|
52
|
+
or its `exports` (decision "`chord.plugins` is a package's manifest of plugins").
|
|
53
|
+
- **`chord.plugins`** in a package's `package.json` lists the plugin folders it provides (globs, exclusions); used by
|
|
54
|
+
discovery of a root's packages and by `installPlugin`; without it, conventional discovery.
|
|
55
|
+
- The by-name lookup (`build.ts` `#byName`), its error texts and the six `tsconfig.json` path aliases go; fixtures and
|
|
56
|
+
examples 35-38 import relatively again.
|
|
57
|
+
|
|
58
|
+
## 3. Per-kind files and the import check
|
|
59
|
+
|
|
60
|
+
- A file whose name has a kind segment before its extension (`contract.web.tsx`, `ui.tui.ts`, any `*.<kind>.<ext>` with
|
|
61
|
+
`<kind>` one of `kinds`) is a file of that kind: importing it (directly or through other files) from a facet of
|
|
62
|
+
another kind is a build error naming the chain. Facet files keep their names (`web.tsx`); contract files are
|
|
63
|
+
`contract.ts` (shared) and `contract.<kind>.ts(x)`.
|
|
64
|
+
- The check runs in the existing esbuild `onResolve` path, on the resolved file, for relative imports, dependencies and
|
|
65
|
+
copied files alike.
|
|
66
|
+
- Documented, not checked: a contract file mentions native things only through `import type` (TypeScript erases it;
|
|
67
|
+
a runtime import of a package the kind lacks already fails as above).
|
|
68
|
+
|
|
69
|
+
## 4. Single-file plugins
|
|
70
|
+
|
|
71
|
+
- Discovery also lists files at a root's top named `<name>.<kind>.(ts|tsx|js|mjs)`; files of one `<name>` form one
|
|
72
|
+
plugin named `<name>` (an unscoped valid npm name, else reported), one facet per file, `dir` the root, no
|
|
73
|
+
`package.json` (no dependencies, no `chord.external`). A directory plugin of the same name in the same root is a
|
|
74
|
+
reported duplicate (the directory wins).
|
|
75
|
+
- Its build allows imports of host packages only (the app's API); anything else is a build error saying to make it a
|
|
76
|
+
directory. `pluginFile` refuses (it has no directory of its own).
|
|
77
|
+
- The watcher: such a file appearing or disappearing at a root's top sets `set`; a change marks the plugin dirty.
|
|
78
|
+
|
|
79
|
+
## 5. Installing plugins
|
|
80
|
+
|
|
81
|
+
`installPlugin(source, root, ctx)`: `source` is `{ git: url, ref }` (a shallow clone of the ref into
|
|
82
|
+
`<root>/<repository name>`; a repository whose top has a `package.json` is one plugin, otherwise its subdirectories
|
|
83
|
+
are plugins) or `{ npm: name, version }` (`npm pack` and extract into `<root>/<name>`), then `installDependencies` for
|
|
84
|
+
each new plugin; marks `set`. Returns the installed plugin names. Removal is deleting the directory (`set`). No
|
|
85
|
+
updating in place: install another ref (a new directory) or delete and install.
|
|
86
|
+
|
|
87
|
+
## 6. `testPlugin`
|
|
88
|
+
|
|
89
|
+
```ts
|
|
90
|
+
const t = await testPlugin("./plugins/stats", {
|
|
91
|
+
kind: "worker",
|
|
92
|
+
api: { name: "@acme/app", versions: ["v3"] },
|
|
93
|
+
modules: { "@acme/app/v3": apiV3, "@acme/app/v3/worker": apiV3Worker }, // the real API modules
|
|
94
|
+
stubs: [{ name: "@acme/notes", facet: notesStub }], // facets serving what it uses
|
|
95
|
+
principal: { kind: "user", id: "u1" }, // the host's principal (optional)
|
|
96
|
+
}, ctx);
|
|
97
|
+
const stats = await t.host.get(Stats, { project: "p1" }, ctx);
|
|
98
|
+
t.contributions(Panels); // what the plugin contributed to a registry nobody serves (the helper serves it)
|
|
99
|
+
t.unserved(); // contract names requests wait for unbound `not_served`
|
|
100
|
+
await t.close(ctx);
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
- Built with the same build as production (`buildFacet` with the kind's options), evaluated with `modules`, loaded on a
|
|
104
|
+
host with `address`/`principal` as given, an in-memory store (`:memory:` SQLite); stubs loaded beside it.
|
|
105
|
+
- The helper serves, as a collecting registry, every registry the plugin contributes to that no stub or the plugin
|
|
106
|
+
itself serves (`t.contributions(R)`: the current entries).
|
|
107
|
+
- `t.unserved()` lists the names of contracts whose requests wait unbound `not_served` on the host (the unbound
|
|
108
|
+
index), so a test knows what to stub. `t.root(fn, ctx, { principal })` runs as another principal.
|
|
109
|
+
- Exported from `chord/plugins` (`testing.ts`); no test-only modes elsewhere.
|
|
110
|
+
|
|
111
|
+
## 7. Docs for authors and agents
|
|
112
|
+
|
|
113
|
+
- `docs/plugin-authoring.md`: a plugin's layout (directory and single-file), its facet and contract files per
|
|
114
|
+
kind, what it may import and how each import resolves, versions, how the server builds it (esbuild, what the build
|
|
115
|
+
handles, no build hooks), installing from git or npm, testing with `testPlugin`; written for agents (short, exact,
|
|
116
|
+
with one complete example plugin).
|
|
117
|
+
- Update `src/node/plugins/README.md`, the guide `docs/guide-plugins-hosts/book.md` (chapters "Plugins Using
|
|
118
|
+
Plugins" and "Base Code and Plugins"; rebuild `index.html`), design §21's slice-10 note.
|
|
119
|
+
|
|
120
|
+
## 8. Tests, examples
|
|
121
|
+
|
|
122
|
+
- One test file per source file; build tests for every refusal and allowance of §1-§4 (an unlisted version, a kind
|
|
123
|
+
module from another kind, mixed versions, a Chord import, a relative path leaving the root, a per-kind file through
|
|
124
|
+
a chain, a package from `dependencies` through `exports`, a git dependency with a ref (a local bare repository in a
|
|
125
|
+
temp directory, no network), a subfolder dependency); discovery of single-file plugins; required roots at load;
|
|
126
|
+
`installPlugin` from a local git repository and a local npm tarball; `testPlugin` (stubs, collected contributions,
|
|
127
|
+
`unserved`, a principal).
|
|
128
|
+
- Examples: `49-plugin-api` (an app API with two versions and per-kind modules, a plugin per version, the refusals),
|
|
129
|
+
`50-plugin-imports` (relative within a root, a git dependency pinned to a commit, per-kind contract files),
|
|
130
|
+
`51-single-file-plugin`, `52-test-plugin` (a plugin tested with a stub). Examples 35-38 updated.
|
|
131
|
+
- No hot path changes; no benchmark beyond a cold build of the 20-plugin set (as 7c's) to show the checks cost nothing
|
|
132
|
+
measurable.
|