@bjornpagen/bumbledb-log 0.20.2 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +275 -114
- package/dist/admin.d.ts +24 -0
- package/dist/admin.d.ts.map +1 -0
- package/dist/admin.js +12 -0
- package/dist/admin.js.map +1 -0
- package/dist/bridge.d.ts +30 -0
- package/dist/bridge.d.ts.map +1 -0
- package/dist/bridge.js +92 -0
- package/dist/bridge.js.map +1 -0
- package/dist/codes.d.ts +11 -0
- package/dist/codes.d.ts.map +1 -0
- package/dist/codes.js +53 -0
- package/dist/codes.js.map +1 -0
- package/dist/command.d.ts +21 -0
- package/dist/command.d.ts.map +1 -0
- package/dist/command.js +12 -0
- package/dist/command.js.map +1 -0
- package/dist/errors.d.ts +78 -197
- package/dist/errors.d.ts.map +1 -1
- package/dist/errors.js +144 -114
- package/dist/errors.js.map +1 -1
- package/dist/history.d.ts +22 -0
- package/dist/history.d.ts.map +1 -0
- package/dist/history.js +12 -0
- package/dist/history.js.map +1 -0
- package/dist/identity.d.ts +144 -0
- package/dist/identity.d.ts.map +1 -0
- package/dist/identity.js +223 -0
- package/dist/identity.js.map +1 -0
- package/dist/index.d.ts +24 -31
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +16 -21
- package/dist/index.js.map +1 -1
- package/dist/machine.d.ts +151 -0
- package/dist/machine.d.ts.map +1 -0
- package/dist/machine.js +1128 -0
- package/dist/machine.js.map +1 -0
- package/dist/migration-ops.d.ts +20 -0
- package/dist/migration-ops.d.ts.map +1 -0
- package/dist/migration-ops.js +7 -0
- package/dist/migration-ops.js.map +1 -0
- package/dist/migrations/bin.d.ts +3 -0
- package/dist/migrations/bin.d.ts.map +1 -0
- package/dist/migrations/bin.js +43 -0
- package/dist/migrations/bin.js.map +1 -0
- package/dist/migrations/canonical.d.ts +40 -0
- package/dist/migrations/canonical.d.ts.map +1 -0
- package/dist/migrations/canonical.js +156 -0
- package/dist/migrations/canonical.js.map +1 -0
- package/dist/migrations/cli.d.ts +32 -0
- package/dist/migrations/cli.d.ts.map +1 -0
- package/dist/migrations/cli.js +147 -0
- package/dist/migrations/cli.js.map +1 -0
- package/dist/migrations/codec.d.ts +74 -0
- package/dist/migrations/codec.d.ts.map +1 -0
- package/dist/migrations/codec.js +2 -0
- package/dist/migrations/codec.js.map +1 -0
- package/dist/migrations/decode.d.ts +16 -0
- package/dist/migrations/decode.d.ts.map +1 -0
- package/dist/migrations/decode.js +302 -0
- package/dist/migrations/decode.js.map +1 -0
- package/dist/migrations/diff.d.ts +39 -0
- package/dist/migrations/diff.d.ts.map +1 -0
- package/dist/migrations/diff.js +385 -0
- package/dist/migrations/diff.js.map +1 -0
- package/dist/migrations/expr.d.ts +22 -0
- package/dist/migrations/expr.d.ts.map +1 -0
- package/dist/migrations/expr.js +228 -0
- package/dist/migrations/expr.js.map +1 -0
- package/dist/migrations/fail.d.ts +34 -0
- package/dist/migrations/fail.d.ts.map +1 -0
- package/dist/migrations/fail.js +69 -0
- package/dist/migrations/fail.js.map +1 -0
- package/dist/migrations/fsops.d.ts +37 -0
- package/dist/migrations/fsops.d.ts.map +1 -0
- package/dist/migrations/fsops.js +222 -0
- package/dist/migrations/fsops.js.map +1 -0
- package/dist/migrations/generate.d.ts +11 -0
- package/dist/migrations/generate.d.ts.map +1 -0
- package/dist/migrations/generate.js +479 -0
- package/dist/migrations/generate.js.map +1 -0
- package/dist/migrations/index.d.ts +25 -0
- package/dist/migrations/index.d.ts.map +1 -0
- package/dist/migrations/index.js +6 -0
- package/dist/migrations/index.js.map +1 -0
- package/dist/migrations/intent.d.ts +86 -0
- package/dist/migrations/intent.d.ts.map +1 -0
- package/dist/migrations/intent.js +97 -0
- package/dist/migrations/intent.js.map +1 -0
- package/dist/migrations/lock.d.ts +27 -0
- package/dist/migrations/lock.d.ts.map +1 -0
- package/dist/migrations/lock.js +14 -0
- package/dist/migrations/lock.js.map +1 -0
- package/dist/migrations/native.d.ts +37 -0
- package/dist/migrations/native.d.ts.map +1 -0
- package/dist/migrations/native.js +135 -0
- package/dist/migrations/native.js.map +1 -0
- package/dist/migrations/repo.d.ts +38 -0
- package/dist/migrations/repo.d.ts.map +1 -0
- package/dist/migrations/repo.js +191 -0
- package/dist/migrations/repo.js.map +1 -0
- package/dist/migrations/theory.d.ts +21 -0
- package/dist/migrations/theory.d.ts.map +1 -0
- package/dist/migrations/theory.js +107 -0
- package/dist/migrations/theory.js.map +1 -0
- package/dist/migrations/types.d.ts +243 -0
- package/dist/migrations/types.d.ts.map +1 -0
- package/dist/migrations/types.js +2 -0
- package/dist/migrations/types.js.map +1 -0
- package/dist/migrations/workflow.d.ts +11 -0
- package/dist/migrations/workflow.d.ts.map +1 -0
- package/dist/migrations/workflow.js +14 -0
- package/dist/migrations/workflow.js.map +1 -0
- package/dist/native.d.ts +600 -0
- package/dist/native.d.ts.map +1 -0
- package/dist/native.js +8 -0
- package/dist/native.js.map +1 -0
- package/dist/options.d.ts +106 -0
- package/dist/options.d.ts.map +1 -0
- package/dist/options.js +2 -0
- package/dist/options.js.map +1 -0
- package/dist/outcome.d.ts +291 -0
- package/dist/outcome.d.ts.map +1 -0
- package/dist/outcome.js +2 -0
- package/dist/outcome.js.map +1 -0
- package/dist/production.d.ts +12 -0
- package/dist/production.d.ts.map +1 -0
- package/dist/production.js +29 -0
- package/dist/production.js.map +1 -0
- package/dist/schema.d.ts +10 -0
- package/dist/schema.d.ts.map +1 -0
- package/dist/schema.js +9 -0
- package/dist/schema.js.map +1 -0
- package/dist/surface.d.ts +80 -0
- package/dist/surface.d.ts.map +1 -0
- package/dist/surface.js +2 -0
- package/dist/surface.js.map +1 -0
- package/dist/tenants.d.ts +20 -52
- package/dist/tenants.d.ts.map +1 -1
- package/dist/tenants.js +11 -330
- package/dist/tenants.js.map +1 -1
- package/pack-provenance.json +7 -0
- package/package.json +20 -23
- package/dist/braids.d.ts +0 -28
- package/dist/braids.d.ts.map +0 -1
- package/dist/braids.js +0 -45
- package/dist/braids.js.map +0 -1
- package/dist/bytes.d.ts +0 -26
- package/dist/bytes.d.ts.map +0 -1
- package/dist/bytes.js +0 -86
- package/dist/bytes.js.map +0 -1
- package/dist/chain.d.ts +0 -56
- package/dist/chain.d.ts.map +0 -1
- package/dist/chain.js +0 -137
- package/dist/chain.js.map +0 -1
- package/dist/codec.d.ts +0 -71
- package/dist/codec.d.ts.map +0 -1
- package/dist/codec.js +0 -179
- package/dist/codec.js.map +0 -1
- package/dist/descriptor.d.ts +0 -61
- package/dist/descriptor.d.ts.map +0 -1
- package/dist/descriptor.js +0 -160
- package/dist/descriptor.js.map +0 -1
- package/dist/keys.d.ts +0 -52
- package/dist/keys.d.ts.map +0 -1
- package/dist/keys.js +0 -166
- package/dist/keys.js.map +0 -1
- package/dist/manifest.d.ts +0 -42
- package/dist/manifest.d.ts.map +0 -1
- package/dist/manifest.js +0 -116
- package/dist/manifest.js.map +0 -1
- package/dist/replica.d.ts +0 -154
- package/dist/replica.d.ts.map +0 -1
- package/dist/replica.js +0 -820
- package/dist/replica.js.map +0 -1
- package/dist/store-s3.d.ts +0 -31
- package/dist/store-s3.d.ts.map +0 -1
- package/dist/store-s3.js +0 -299
- package/dist/store-s3.js.map +0 -1
- package/dist/store.d.ts +0 -129
- package/dist/store.d.ts.map +0 -1
- package/dist/store.js +0 -577
- package/dist/store.js.map +0 -1
- package/dist/tilde-family.json +0 -21
- package/dist/vector.d.ts +0 -31
- package/dist/vector.d.ts.map +0 -1
- package/dist/vector.js +0 -87
- package/dist/vector.js.map +0 -1
- package/dist/writer.d.ts +0 -106
- package/dist/writer.d.ts.map +0 -1
- package/dist/writer.js +0 -677
- package/dist/writer.js.map +0 -1
package/dist/errors.js
CHANGED
|
@@ -1,122 +1,152 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* The
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
* `
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
* exhaustion. An unproved conditional write is the store verbs' own
|
|
13
|
-
* `ambiguous` outcome arm, never an error identity.
|
|
2
|
+
* The successor error vocabulary. `LogError = DbError | ProtocolError` and
|
|
3
|
+
* nothing else: a core failure crossing the log is the exact core `DbError`,
|
|
4
|
+
* unchanged; `ProtocolError` adds only the log-specific reason roster from
|
|
5
|
+
* `#codes.ts`, generated by the one native speller. Both classes are direct
|
|
6
|
+
* Effect `Schema.TaggedError` values with a tagged reason; any displayed
|
|
7
|
+
* `.code` is derived from the reason tag and there is no second mutable
|
|
8
|
+
* classification authority. Terminal receipts are data in A, never errors.
|
|
9
|
+
* Submit/admin interruption and finalizer defects stay in `Cause`.
|
|
10
|
+
* Resolve the original command/operation identity after cancellation;
|
|
11
|
+
* cancellation cannot establish whether publication happened.
|
|
14
12
|
*/
|
|
15
|
-
import
|
|
13
|
+
import { DbError, dbError } from "@bjornpagen/bumbledb";
|
|
14
|
+
import { Schema } from "effect";
|
|
15
|
+
import { protocolErrorCodes } from "#codes.ts";
|
|
16
|
+
const Contention = Schema.Struct({
|
|
17
|
+
_tag: Schema.Literal("Contention"),
|
|
18
|
+
attempts: Schema.Number
|
|
19
|
+
});
|
|
20
|
+
const NotYetAvailable = Schema.Struct({
|
|
21
|
+
_tag: Schema.Literal("NotYetAvailable"),
|
|
22
|
+
requestedSeq: Schema.BigInt,
|
|
23
|
+
capturedSeq: Schema.BigInt
|
|
24
|
+
});
|
|
25
|
+
const InsufficientLocalDisk = Schema.Struct({
|
|
26
|
+
_tag: Schema.Literal("InsufficientLocalDisk"),
|
|
27
|
+
requiredBytes: Schema.BigInt,
|
|
28
|
+
availableBytes: Schema.BigInt
|
|
29
|
+
});
|
|
30
|
+
/** C08 envelope backpressure: the retained tail exceeded its policy. */
|
|
31
|
+
const MaintenanceRequired = Schema.Struct({
|
|
32
|
+
_tag: Schema.Literal("MaintenanceRequired"),
|
|
33
|
+
count: Schema.BigInt,
|
|
34
|
+
bytes: Schema.BigInt
|
|
35
|
+
});
|
|
16
36
|
/**
|
|
17
|
-
*
|
|
18
|
-
*
|
|
19
|
-
*
|
|
37
|
+
* The warm local materialization is behind the checkpoint base. Hydration is
|
|
38
|
+
* NATIVE (recovery runs on the next history open / tenant acquire); `detail`
|
|
39
|
+
* carries the native recovery/reopen guidance — this layer surfaces the
|
|
40
|
+
* typed refusal and never repairs the cache itself.
|
|
20
41
|
*/
|
|
21
|
-
const
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
const
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
const
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
const
|
|
42
|
+
const MaterializationStale = Schema.Struct({
|
|
43
|
+
_tag: Schema.Literal("MaterializationStale"),
|
|
44
|
+
detail: Schema.String
|
|
45
|
+
});
|
|
46
|
+
const MigrationDrift = Schema.Struct({
|
|
47
|
+
_tag: Schema.Literal("MigrationDrift"),
|
|
48
|
+
detail: Schema.String
|
|
49
|
+
});
|
|
50
|
+
const MigrationUnsupported = Schema.Struct({
|
|
51
|
+
_tag: Schema.Literal("MigrationUnsupported"),
|
|
52
|
+
detail: Schema.String
|
|
53
|
+
});
|
|
54
|
+
const MigrationRepository = Schema.Struct({
|
|
55
|
+
_tag: Schema.Literal("MigrationRepository"),
|
|
56
|
+
path: Schema.String,
|
|
57
|
+
detail: Schema.String
|
|
58
|
+
});
|
|
59
|
+
const MigrationIntentRequired = Schema.Struct({
|
|
60
|
+
_tag: Schema.Literal("MigrationIntentRequired"),
|
|
61
|
+
requirements: Schema.Array(Schema.Struct({
|
|
62
|
+
code: Schema.Literals([
|
|
63
|
+
"ambiguous",
|
|
64
|
+
"destructive",
|
|
65
|
+
"missing-backfill",
|
|
66
|
+
"type-change",
|
|
67
|
+
"unsupported",
|
|
68
|
+
"stale-intent",
|
|
69
|
+
"conflicting-intent"
|
|
70
|
+
]),
|
|
71
|
+
relation: Schema.String,
|
|
72
|
+
field: Schema.NullOr(Schema.String),
|
|
73
|
+
detail: Schema.String
|
|
74
|
+
})),
|
|
75
|
+
truncated: Schema.Boolean
|
|
76
|
+
});
|
|
77
|
+
const structured = [
|
|
78
|
+
"Contention",
|
|
79
|
+
"NotYetAvailable",
|
|
80
|
+
"InsufficientLocalDisk",
|
|
81
|
+
"MaintenanceRequired",
|
|
82
|
+
"MaterializationStale",
|
|
83
|
+
"MigrationDrift",
|
|
84
|
+
"MigrationUnsupported",
|
|
85
|
+
"MigrationRepository",
|
|
86
|
+
"MigrationIntentRequired"
|
|
87
|
+
];
|
|
88
|
+
const PlainReason = Schema.Struct({
|
|
89
|
+
_tag: Schema.Literals(protocolErrorCodes.filter((code) => !structured.includes(code)))
|
|
90
|
+
});
|
|
91
|
+
export const ProtocolReason = Schema.Union([
|
|
92
|
+
Contention,
|
|
93
|
+
NotYetAvailable,
|
|
94
|
+
InsufficientLocalDisk,
|
|
95
|
+
MaintenanceRequired,
|
|
96
|
+
MaterializationStale,
|
|
97
|
+
MigrationDrift,
|
|
98
|
+
MigrationUnsupported,
|
|
99
|
+
MigrationRepository,
|
|
100
|
+
MigrationIntentRequired,
|
|
101
|
+
PlainReason
|
|
102
|
+
]);
|
|
103
|
+
const ProtocolErrorBase = Schema.TaggedError()("ProtocolError", {
|
|
104
|
+
operation: Schema.String,
|
|
105
|
+
reason: ProtocolReason
|
|
106
|
+
});
|
|
107
|
+
export class ProtocolError extends ProtocolErrorBase {
|
|
108
|
+
get code() {
|
|
109
|
+
return this.reason._tag;
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
/** The one wire error frame the native log machine throws across the bridge. */
|
|
113
|
+
const WireError = Schema.Union([
|
|
114
|
+
Schema.Struct({ source: Schema.Literal("protocol"), reason: ProtocolReason }),
|
|
115
|
+
Schema.Struct({ source: Schema.Literal("core"), reason: Schema.Unknown })
|
|
116
|
+
]);
|
|
117
|
+
const decodeWireError = Schema.decodeUnknownOption(WireError);
|
|
34
118
|
/**
|
|
35
|
-
*
|
|
36
|
-
*
|
|
37
|
-
*
|
|
119
|
+
* Decode a thrown bridge value into the typed union. Already-typed errors
|
|
120
|
+
* pass through untouched (core errors are never rewrapped); an unrecognized
|
|
121
|
+
* local throw is a core `Internal`, not a fabricated protocol outcome.
|
|
38
122
|
*/
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
const
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
function
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
123
|
+
export function logFailure(operation, cause) {
|
|
124
|
+
if (cause instanceof DbError || cause instanceof ProtocolError) {
|
|
125
|
+
return cause;
|
|
126
|
+
}
|
|
127
|
+
const wire = decodeWireError(cause);
|
|
128
|
+
if (wire._tag === "Some") {
|
|
129
|
+
if (wire.value.source === "protocol") {
|
|
130
|
+
return new ProtocolError({ operation, reason: wire.value.reason });
|
|
131
|
+
}
|
|
132
|
+
return dbError(operation, wire.value.reason);
|
|
133
|
+
}
|
|
134
|
+
return dbError(operation, cause);
|
|
135
|
+
}
|
|
136
|
+
/** A plain-tag protocol failure, spelled once. */
|
|
137
|
+
export function protocolError(operation, code) {
|
|
138
|
+
return new ProtocolError({ operation, reason: { _tag: code } });
|
|
139
|
+
}
|
|
140
|
+
/** The boundary-parser refusal: malformed public input, before any I/O. */
|
|
141
|
+
export function invalidInput(operation) {
|
|
142
|
+
return new DbError({ operation, reason: { _tag: "InvalidArgument" } });
|
|
143
|
+
}
|
|
144
|
+
/** A closed/stale capability supplied dynamically. */
|
|
145
|
+
export function closedHandle(operation) {
|
|
146
|
+
return new DbError({ operation, reason: { _tag: "ClosedHandle" } });
|
|
147
|
+
}
|
|
148
|
+
/** Post-dispatch fiber interrupt: afterDispatch arm, same original identity. */
|
|
149
|
+
export function cancelled(operation) {
|
|
150
|
+
return new DbError({ operation, reason: { _tag: "Cancelled" } });
|
|
57
151
|
}
|
|
58
|
-
function refuseChain(data, detail) {
|
|
59
|
-
const error = errors.wrap(ErrChainMismatch, detail);
|
|
60
|
-
chainData.set(error, data);
|
|
61
|
-
throw error;
|
|
62
|
-
}
|
|
63
|
-
function throwContention(data, detail) {
|
|
64
|
-
const error = errors.wrap(ErrContention, detail);
|
|
65
|
-
contentionData.set(error, data);
|
|
66
|
-
throw error;
|
|
67
|
-
}
|
|
68
|
-
function refuseManifestMissing(detail) {
|
|
69
|
-
throw errors.wrap(ErrManifestMissing, detail);
|
|
70
|
-
}
|
|
71
|
-
function isManifestMissing(error) {
|
|
72
|
-
return error instanceof Error && errors.is(error, ErrManifestMissing);
|
|
73
|
-
}
|
|
74
|
-
function refuseOverWidth(data, detail) {
|
|
75
|
-
const error = errors.wrap(ErrOverWidth, detail);
|
|
76
|
-
overWidthData.set(error, data);
|
|
77
|
-
throw error;
|
|
78
|
-
}
|
|
79
|
-
function throwRefillNeeded(data, detail) {
|
|
80
|
-
const error = errors.wrap(ErrRefillNeeded, detail);
|
|
81
|
-
refillNeededData.set(error, data);
|
|
82
|
-
throw error;
|
|
83
|
-
}
|
|
84
|
-
function refuseExhausted(data, detail) {
|
|
85
|
-
const error = errors.wrap(ErrExhausted, detail);
|
|
86
|
-
exhaustedData.set(error, data);
|
|
87
|
-
throw error;
|
|
88
|
-
}
|
|
89
|
-
function refuseSlotRetired(data, detail) {
|
|
90
|
-
const error = errors.wrap(ErrSlotRetired, detail);
|
|
91
|
-
slotRetiredData.set(error, data);
|
|
92
|
-
throw error;
|
|
93
|
-
}
|
|
94
|
-
function refusalOf(error) {
|
|
95
|
-
return refusalData.get(error);
|
|
96
|
-
}
|
|
97
|
-
function chainMismatchOf(error) {
|
|
98
|
-
return chainData.get(error);
|
|
99
|
-
}
|
|
100
|
-
function contentionOf(error) {
|
|
101
|
-
return contentionData.get(error);
|
|
102
|
-
}
|
|
103
|
-
function overWidthOf(error) {
|
|
104
|
-
return overWidthData.get(error);
|
|
105
|
-
}
|
|
106
|
-
function refillNeededOf(error) {
|
|
107
|
-
return refillNeededData.get(error);
|
|
108
|
-
}
|
|
109
|
-
function exhaustedOf(error) {
|
|
110
|
-
return exhaustedData.get(error);
|
|
111
|
-
}
|
|
112
|
-
function slotRetiredOf(error) {
|
|
113
|
-
return slotRetiredData.get(error);
|
|
114
|
-
}
|
|
115
|
-
/** Every store failure wraps the exported sentinel itself, so
|
|
116
|
-
* `errors.is(e, ErrStore)` matches by identity; the vendor error's
|
|
117
|
-
* message rides the detail verbatim. */
|
|
118
|
-
function wrapStore(inner, detail) {
|
|
119
|
-
return errors.wrap(ErrStore, `${detail}: ${inner.message}`);
|
|
120
|
-
}
|
|
121
|
-
export { chainMismatchOf, contentionOf, ErrChainMismatch, ErrContention, ErrExhausted, ErrOverWidth, ErrRefillNeeded, ErrRefused, ErrReplayDiverged, ErrSlotRetired, ErrSpanningCommit, ErrStore, exhaustedOf, isManifestMissing, overWidthOf, refillNeededOf, refusalOf, refuse, refuseChain, refuseExhausted, refuseManifestMissing, refuseOverWidth, refuseSlotRetired, slotRetiredOf, throwContention, throwRefillNeeded, wrapStore };
|
|
122
152
|
//# sourceMappingURL=errors.js.map
|
package/dist/errors.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"errors.js","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"errors.js","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AACH,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAA;AACvD,OAAO,EAAc,MAAM,EAAE,MAAM,QAAQ,CAAA;AAC3C,OAAO,EAAE,kBAAkB,EAAE,MAAM,WAAW,CAAA;AAE9C,MAAM,UAAU,GAAG,MAAM,CAAC,MAAM,CAAC;IAChC,IAAI,EAAE,MA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AC,MAAM,CAAC,CAAA;IAC7C,CAAC;IACD,OAAO,OAAO,CAAC,SAAS,EAAE,KAAK,CAAC,CAAA;AACjC,CAAC;AAED,kDAAkD;AAClD,MAAM,UAAU,aAAa,CAC5B,SAAiB,EACjB,IAAkE;IAElE,OAAO,IAAI,aAAa,CAAC,EAAE,SAAS,EAAE,MAAM,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,EAAE,CAAC,CAAA;AAChE,CAAC;AAED,2EAA2E;AAC3E,MAAM,UAAU,YAAY,CAAC,SAAiB;IAC7C,OAAO,IAAI,OAAO,CAAC,EAAE,SAAS,EAAE,MAAM,EAAE,EAAE,IAAI,EAAE,iBAAiB,EAAE,EAAE,CAAC,CAAA;AACvE,CAAC;AAED,sDAAsD;AACtD,MAAM,UAAU,YAAY,CAAC,SAAiB;IAC7C,OAAO,IAAI,OAAO,CAAC,EAAE,SAAS,EAAE,MAAM,EAAE,EAAE,IAAI,EAAE,cAAc,EAAE,EAAE,CAAC,CAAA;AACpE,CAAC;AAED,gFAAgF;AAChF,MAAM,UAAU,SAAS,CAAC,SAAiB;IAC1C,OAAO,IAAI,OAAO,CAAC,EAAE,SAAS,EAAE,MAAM,EAAE,EAAE,IAAI,EAAE,WAAW,EAAE,EAAE,CAAC,CAAA;AACjE,CAAC"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `LocalHistory` and `HostedHistory`: the chapter 30/35 durable envelope
|
|
3
|
+
* around the exact core change/read machinery. `open` of a missing or
|
|
4
|
+
* unreadable configured database never creates a replacement; `create` is
|
|
5
|
+
* the explicit constructor, refuses existing authority, and validates its
|
|
6
|
+
* stable creation identity plus checked initialization artifact instead of
|
|
7
|
+
* fabricating genesis or applied migration history.
|
|
8
|
+
*/
|
|
9
|
+
import type { AnySchema, NativeRuntime } from "@bjornpagen/bumbledb";
|
|
10
|
+
import type { Effect, Scope } from "effect";
|
|
11
|
+
import type { LogError } from "./errors.js";
|
|
12
|
+
import type { HostedBinding, HostedCreateOptions, HostedOpenOptions, LocalBinding, LocalCreateOptions, LocalOpenOptions } from "./options.js";
|
|
13
|
+
import type { History } from "./surface.js";
|
|
14
|
+
export declare const LocalHistory: {
|
|
15
|
+
open<S extends AnySchema>(binding: LocalBinding, schema: S, options: LocalOpenOptions): Effect.Effect<History<S>, LogError, NativeRuntime | Scope.Scope>;
|
|
16
|
+
create<S extends AnySchema>(binding: LocalBinding, schema: S, options: LocalCreateOptions): Effect.Effect<History<S>, LogError, NativeRuntime | Scope.Scope>;
|
|
17
|
+
};
|
|
18
|
+
export declare const HostedHistory: {
|
|
19
|
+
open<S extends AnySchema>(binding: HostedBinding, schema: S, options: HostedOpenOptions): Effect.Effect<History<S>, LogError, NativeRuntime | Scope.Scope>;
|
|
20
|
+
create<S extends AnySchema>(binding: HostedBinding, schema: S, options: HostedCreateOptions): Effect.Effect<History<S>, LogError, NativeRuntime | Scope.Scope>;
|
|
21
|
+
};
|
|
22
|
+
//# sourceMappingURL=history.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"history.d.ts","sourceRoot":"","sources":["../src/history.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAA;AACpE,OAAO,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,QAAQ,CAAA;AAC3C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAA;AAC1C,OAAO,KAAK,EACX,aAAa,EACb,mBAAmB,EACnB,iBAAiB,EACjB,YAAY,EACZ,kBAAkB,EAClB,gBAAgB,EAChB,MAAM,aAAa,CAAA;AAEpB,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,aAAa,CAAA;AAE1C,eAAO,MAAM,YAAY,EAAE;IAC1B,IAAI,CAAC,CAAC,SAAS,SAAS,EACvB,OAAO,EAAE,YAAY,EACrB,MAAM,EAAE,CAAC,EACT,OAAO,EAAE,gBAAgB,GACvB,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,QAAQ,EAAE,aAAa,GAAG,KAAK,CAAC,KAAK,CAAC,CAAA;IACnE,MAAM,CAAC,CAAC,SAAS,SAAS,EACzB,OAAO,EAAE,YAAY,EACrB,MAAM,EAAE,CAAC,EACT,OAAO,EAAE,kBAAkB,GACzB,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,QAAQ,EAAE,aAAa,GAAG,KAAK,CAAC,KAAK,CAAC,CAAA;CAChD,CAAA;AAEpB,eAAO,MAAM,aAAa,EAAE;IAC3B,IAAI,CAAC,CAAC,SAAS,SAAS,EACvB,OAAO,EAAE,aAAa,EACtB,MAAM,EAAE,CAAC,EACT,OAAO,EAAE,iBAAiB,GACxB,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,QAAQ,EAAE,aAAa,GAAG,KAAK,CAAC,KAAK,CAAC,CAAA;IACnE,MAAM,CAAC,CAAC,SAAS,SAAS,EACzB,OAAO,EAAE,aAAa,EACtB,MAAM,EAAE,CAAC,EACT,OAAO,EAAE,mBAAmB,GAC1B,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,QAAQ,EAAE,aAAa,GAAG,KAAK,CAAC,KAAK,CAAC,CAAA;CAC/C,CAAA"}
|
package/dist/history.js
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `LocalHistory` and `HostedHistory`: the chapter 30/35 durable envelope
|
|
3
|
+
* around the exact core change/read machinery. `open` of a missing or
|
|
4
|
+
* unreadable configured database never creates a replacement; `create` is
|
|
5
|
+
* the explicit constructor, refuses existing authority, and validates its
|
|
6
|
+
* stable creation identity plus checked initialization artifact instead of
|
|
7
|
+
* fabricating genesis or applied migration history.
|
|
8
|
+
*/
|
|
9
|
+
import { log } from "#production.ts";
|
|
10
|
+
export const LocalHistory = log.LocalHistory;
|
|
11
|
+
export const HostedHistory = log.HostedHistory;
|
|
12
|
+
//# sourceMappingURL=history.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"history.js","sourceRoot":"","sources":["../src/history.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAaH,OAAO,EAAE,GAAG,EAAE,MAAM,gBAAgB,CAAA;AAGpC,MAAM,CAAC,MAAM,YAAY,GAWrB,GAAG,CAAC,YAAY,CAAA;AAEpB,MAAM,CAAC,MAAM,aAAa,GAWtB,GAAG,CAAC,aAAa,CAAA"}
|
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Log-layer identity values: small owned immutable data, never handles.
|
|
3
|
+
* `DatabaseId`/`IncarnationId`/`RequestId`/`OperationId` are Uuid-backed
|
|
4
|
+
* roles (canonical UUID); digests are full 32-byte roles
|
|
5
|
+
* (64 lowercase hex). The distinct roles are nominal brands: an entity ID is
|
|
6
|
+
* not a request ID, and neither is a history coordinate. Parsers here are
|
|
7
|
+
* the bounded log boundary codecs for HTTP/session tokens — pure, `Result`-
|
|
8
|
+
* returning, no I/O, no mint/generate; `SchemaId` and `Uuid` remain
|
|
9
|
+
* core-owned imports. Retry uses the caller-supplied bytes again.
|
|
10
|
+
*/
|
|
11
|
+
import { type DbError, type SchemaId, Uuid } from "@bjornpagen/bumbledb";
|
|
12
|
+
import { Result } from "effect";
|
|
13
|
+
declare const databaseIdBrand: unique symbol;
|
|
14
|
+
export type DatabaseId = Uuid & {
|
|
15
|
+
readonly [databaseIdBrand]: typeof databaseIdBrand;
|
|
16
|
+
};
|
|
17
|
+
declare const incarnationIdBrand: unique symbol;
|
|
18
|
+
export type IncarnationId = Uuid & {
|
|
19
|
+
readonly [incarnationIdBrand]: typeof incarnationIdBrand;
|
|
20
|
+
};
|
|
21
|
+
declare const requestIdBrand: unique symbol;
|
|
22
|
+
export type RequestId = Uuid & {
|
|
23
|
+
readonly [requestIdBrand]: typeof requestIdBrand;
|
|
24
|
+
};
|
|
25
|
+
declare const operationIdBrand: unique symbol;
|
|
26
|
+
export type OperationId = Uuid & {
|
|
27
|
+
readonly [operationIdBrand]: typeof operationIdBrand;
|
|
28
|
+
};
|
|
29
|
+
declare const commandDigestBrand: unique symbol;
|
|
30
|
+
export type CommandDigest = string & {
|
|
31
|
+
readonly [commandDigestBrand]: typeof commandDigestBrand;
|
|
32
|
+
};
|
|
33
|
+
declare const decisionDigestBrand: unique symbol;
|
|
34
|
+
export type DecisionDigest = string & {
|
|
35
|
+
readonly [decisionDigestBrand]: typeof decisionDigestBrand;
|
|
36
|
+
};
|
|
37
|
+
declare const rootIdBrand: unique symbol;
|
|
38
|
+
/** A named restore-point/hold identity (chapter 21 NamedRoot). */
|
|
39
|
+
export type RootId = string & {
|
|
40
|
+
readonly [rootIdBrand]: typeof rootIdBrand;
|
|
41
|
+
};
|
|
42
|
+
declare const planSetDigestBrand: unique symbol;
|
|
43
|
+
/** The exact ordered pending-suffix commitment (chapter 33). */
|
|
44
|
+
export type PlanSetDigest = string & {
|
|
45
|
+
readonly [planSetDigestBrand]: typeof planSetDigestBrand;
|
|
46
|
+
};
|
|
47
|
+
export interface DatabaseIdentity {
|
|
48
|
+
readonly databaseId: DatabaseId;
|
|
49
|
+
readonly incarnationId: IncarnationId;
|
|
50
|
+
readonly schemaId: SchemaId;
|
|
51
|
+
}
|
|
52
|
+
export interface DecisionStamp {
|
|
53
|
+
readonly seq: bigint;
|
|
54
|
+
readonly hash: DecisionDigest;
|
|
55
|
+
}
|
|
56
|
+
export interface StateStamp {
|
|
57
|
+
readonly incarnation: IncarnationId;
|
|
58
|
+
readonly dataRevision: bigint;
|
|
59
|
+
}
|
|
60
|
+
declare const receiptEpochBrand: unique symbol;
|
|
61
|
+
/** Positive command-admission namespace; zero is no epoch and is invalid. */
|
|
62
|
+
export type ReceiptEpoch = bigint & {
|
|
63
|
+
readonly [receiptEpochBrand]: typeof receiptEpochBrand;
|
|
64
|
+
};
|
|
65
|
+
export interface CommandId {
|
|
66
|
+
readonly receiptEpoch: ReceiptEpoch;
|
|
67
|
+
readonly requestId: RequestId;
|
|
68
|
+
}
|
|
69
|
+
/** Sufficient to resolve an uncertain submission without a live handle. */
|
|
70
|
+
export interface CommandRef {
|
|
71
|
+
readonly identity: DatabaseIdentity;
|
|
72
|
+
readonly id: CommandId;
|
|
73
|
+
readonly digest: CommandDigest;
|
|
74
|
+
}
|
|
75
|
+
/** One admin/migration operation's protocol identity, fixed before dispatch. */
|
|
76
|
+
export interface OperationRef {
|
|
77
|
+
readonly identity: DatabaseIdentity;
|
|
78
|
+
readonly operation: OperationId;
|
|
79
|
+
}
|
|
80
|
+
export type Freshness = {
|
|
81
|
+
readonly kind: "cached";
|
|
82
|
+
} | {
|
|
83
|
+
readonly kind: "latest";
|
|
84
|
+
} | {
|
|
85
|
+
readonly kind: "at-least";
|
|
86
|
+
readonly requested: DecisionStamp;
|
|
87
|
+
};
|
|
88
|
+
export type ReadConsistency = {
|
|
89
|
+
readonly kind: "cached";
|
|
90
|
+
} | {
|
|
91
|
+
readonly kind: "at-least";
|
|
92
|
+
readonly at: DecisionStamp;
|
|
93
|
+
} | {
|
|
94
|
+
readonly kind: "latest";
|
|
95
|
+
};
|
|
96
|
+
export declare const DatabaseId: {
|
|
97
|
+
readonly parse: (raw: string) => Result.Result<DatabaseId, DbError>;
|
|
98
|
+
readonly from: (id: Uuid) => Result.Result<DatabaseId, DbError>;
|
|
99
|
+
};
|
|
100
|
+
export declare const IncarnationId: {
|
|
101
|
+
readonly parse: (raw: string) => Result.Result<IncarnationId, DbError>;
|
|
102
|
+
readonly from: (id: Uuid) => Result.Result<IncarnationId, DbError>;
|
|
103
|
+
};
|
|
104
|
+
export declare const RequestId: {
|
|
105
|
+
/** The explicit pure nominal conversion over the core's canonical bytes. */
|
|
106
|
+
readonly from: (id: Uuid) => Result.Result<RequestId, DbError>;
|
|
107
|
+
readonly parse: (raw: string) => Result.Result<RequestId, DbError>;
|
|
108
|
+
};
|
|
109
|
+
export declare const OperationId: {
|
|
110
|
+
readonly from: (id: Uuid) => Result.Result<OperationId, DbError>;
|
|
111
|
+
readonly parse: (raw: string) => Result.Result<OperationId, DbError>;
|
|
112
|
+
};
|
|
113
|
+
export declare const ReceiptEpoch: {
|
|
114
|
+
readonly from: (raw: bigint) => Result.Result<ReceiptEpoch, DbError>;
|
|
115
|
+
};
|
|
116
|
+
export declare const CommandDigest: {
|
|
117
|
+
readonly fromHex: (raw: string) => Result.Result<CommandDigest, DbError>;
|
|
118
|
+
};
|
|
119
|
+
export declare const DecisionDigest: {
|
|
120
|
+
readonly fromHex: (raw: string) => Result.Result<DecisionDigest, DbError>;
|
|
121
|
+
};
|
|
122
|
+
export declare const RootId: {
|
|
123
|
+
readonly fromString: (raw: string) => Result.Result<RootId, DbError>;
|
|
124
|
+
};
|
|
125
|
+
export declare const PlanSetDigest: {
|
|
126
|
+
readonly fromHex: (raw: string) => Result.Result<PlanSetDigest, DbError>;
|
|
127
|
+
};
|
|
128
|
+
/**
|
|
129
|
+
* The schema identity is core-owned; the log validates only the canonical
|
|
130
|
+
* 64-lowercase-hex spelling when a token crosses its own HTTP boundary.
|
|
131
|
+
*/
|
|
132
|
+
export declare function parseSchemaId(raw: string): Result.Result<SchemaId, DbError>;
|
|
133
|
+
export declare function renderDecisionStamp(stamp: DecisionStamp): string;
|
|
134
|
+
export declare function parseDecisionStamp(raw: string): Result.Result<DecisionStamp, DbError>;
|
|
135
|
+
export declare function renderStateStamp(stamp: StateStamp): string;
|
|
136
|
+
export declare function parseStateStamp(raw: string): Result.Result<StateStamp, DbError>;
|
|
137
|
+
export declare function renderDatabaseIdentity(identity: DatabaseIdentity): string;
|
|
138
|
+
export declare function parseDatabaseIdentity(raw: string): Result.Result<DatabaseIdentity, DbError>;
|
|
139
|
+
export declare function renderCommandRef(ref: CommandRef): string;
|
|
140
|
+
export declare function parseCommandRef(raw: string): Result.Result<CommandRef, DbError>;
|
|
141
|
+
export declare function sameIdentity(a: DatabaseIdentity, b: DatabaseIdentity): boolean;
|
|
142
|
+
export declare function sameCommandRef(a: CommandRef, b: CommandRef): boolean;
|
|
143
|
+
export {};
|
|
144
|
+
//# sourceMappingURL=identity.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"identity.d.ts","sourceRoot":"","sources":["../src/identity.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,EAAE,KAAK,OAAO,EAAE,KAAK,QAAQ,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAA;AACxE,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAA;AAG/B,OAAO,CAAC,MAAM,eAAe,EAAE,OAAO,MAAM,CAAA;AAC5C,MAAM,MAAM,UAAU,GAAG,IAAI,GAAG;IAAE,QAAQ,CAAC,CAAC,eAAe,CAAC,EAAE,OAAO,eAAe,CAAA;CAAE,CAAA;AACtF,OAAO,CAAC,MAAM,kBAAkB,EAAE,OAAO,MAAM,CAAA;AAC/C,MAAM,MAAM,aAAa,GAAG,IAAI,GAAG;IAAE,QAAQ,CAAC,CAAC,kBAAkB,CAAC,EAAE,OAAO,kBAAkB,CAAA;CAAE,CAAA;AAC/F,OAAO,CAAC,MAAM,cAAc,EAAE,OAAO,MAAM,CAAA;AAC3C,MAAM,MAAM,SAAS,GAAG,IAAI,GAAG;IAAE,QAAQ,CAAC,CAAC,cAAc,CAAC,EAAE,OAAO,cAAc,CAAA;CAAE,CAAA;AACnF,OAAO,CAAC,MAAM,gBAAgB,EAAE,OAAO,MAAM,CAAA;AAC7C,MAAM,MAAM,WAAW,GAAG,IAAI,GAAG;IAAE,QAAQ,CAAC,CAAC,gBAAgB,CAAC,EAAE,OAAO,gBAAgB,CAAA;CAAE,CAAA;AACzF,OAAO,CAAC,MAAM,kBAAkB,EAAE,OAAO,MAAM,CAAA;AAC/C,MAAM,MAAM,aAAa,GAAG,MAAM,GAAG;IAAE,QAAQ,CAAC,C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