@optimystic/db-p2p 1.0.0-beta.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/dist/src/cluster/block-transfer-service.d.ts +73 -1
- package/dist/src/cluster/block-transfer-service.d.ts.map +1 -1
- package/dist/src/cluster/block-transfer-service.js +70 -3
- package/dist/src/cluster/block-transfer-service.js.map +1 -1
- package/dist/src/cluster/block-transfer.d.ts +16 -1
- package/dist/src/cluster/block-transfer.d.ts.map +1 -1
- package/dist/src/cluster/block-transfer.js +73 -72
- package/dist/src/cluster/block-transfer.js.map +1 -1
- package/dist/src/cluster/client.d.ts +4 -6
- package/dist/src/cluster/client.d.ts.map +1 -1
- package/dist/src/cluster/client.js +8 -13
- package/dist/src/cluster/client.js.map +1 -1
- package/dist/src/cluster/cluster-policy.d.ts +2 -1
- package/dist/src/cluster/cluster-policy.d.ts.map +1 -1
- package/dist/src/cluster/cluster-policy.js.map +1 -1
- package/dist/src/cluster/cluster-repo.d.ts +172 -17
- package/dist/src/cluster/cluster-repo.d.ts.map +1 -1
- package/dist/src/cluster/cluster-repo.js +553 -149
- package/dist/src/cluster/cluster-repo.js.map +1 -1
- package/dist/src/cluster/commit-proof.js +2 -2
- package/dist/src/cluster/race-resolution.d.ts +51 -7
- package/dist/src/cluster/race-resolution.d.ts.map +1 -1
- package/dist/src/cluster/race-resolution.js +71 -7
- package/dist/src/cluster/race-resolution.js.map +1 -1
- package/dist/src/cluster/rebalance-monitor.d.ts +67 -5
- package/dist/src/cluster/rebalance-monitor.d.ts.map +1 -1
- package/dist/src/cluster/rebalance-monitor.js +120 -26
- package/dist/src/cluster/rebalance-monitor.js.map +1 -1
- package/dist/src/cluster/spread-on-churn.d.ts.map +1 -1
- package/dist/src/cluster/spread-on-churn.js +34 -47
- package/dist/src/cluster/spread-on-churn.js.map +1 -1
- package/dist/src/cohort-topic/host.d.ts.map +1 -1
- package/dist/src/cohort-topic/host.js +8 -6
- package/dist/src/cohort-topic/host.js.map +1 -1
- package/dist/src/cohort-topic/membership-source.js +1 -1
- package/dist/src/cohort-topic/membership-source.js.map +1 -1
- package/dist/src/cohort-topic/peer-codec.d.ts.map +1 -1
- package/dist/src/cohort-topic/peer-codec.js +5 -2
- package/dist/src/cohort-topic/peer-codec.js.map +1 -1
- package/dist/src/cohort-topic/stream-util.d.ts +24 -3
- package/dist/src/cohort-topic/stream-util.d.ts.map +1 -1
- package/dist/src/cohort-topic/stream-util.js +36 -3
- package/dist/src/cohort-topic/stream-util.js.map +1 -1
- package/dist/src/cohort-topic/topic-router.d.ts +9 -0
- package/dist/src/cohort-topic/topic-router.d.ts.map +1 -1
- package/dist/src/cohort-topic/topic-router.js +12 -2
- package/dist/src/cohort-topic/topic-router.js.map +1 -1
- package/dist/src/dispute/client.d.ts.map +1 -1
- package/dist/src/dispute/client.js +15 -3
- package/dist/src/dispute/client.js.map +1 -1
- package/dist/src/index.d.ts +5 -0
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +5 -0
- package/dist/src/index.js.map +1 -1
- package/dist/src/libp2p-key-network.d.ts +78 -17
- package/dist/src/libp2p-key-network.d.ts.map +1 -1
- package/dist/src/libp2p-key-network.js +241 -147
- package/dist/src/libp2p-key-network.js.map +1 -1
- package/dist/src/libp2p-node-base.d.ts +35 -1
- package/dist/src/libp2p-node-base.d.ts.map +1 -1
- package/dist/src/libp2p-node-base.js +151 -26
- package/dist/src/libp2p-node-base.js.map +1 -1
- package/dist/src/libp2p-node-rn.d.ts +2 -2
- package/dist/src/libp2p-node-rn.d.ts.map +1 -1
- package/dist/src/libp2p-node-rn.js.map +1 -1
- package/dist/src/libp2p-node.d.ts +2 -2
- package/dist/src/libp2p-node.d.ts.map +1 -1
- package/dist/src/libp2p-node.js.map +1 -1
- package/dist/src/logger.d.ts.map +1 -1
- package/dist/src/logger.js +19 -7
- package/dist/src/logger.js.map +1 -1
- package/dist/src/matchmaking/query-transport.d.ts +3 -4
- package/dist/src/matchmaking/query-transport.d.ts.map +1 -1
- package/dist/src/matchmaking/query-transport.js +9 -9
- package/dist/src/matchmaking/query-transport.js.map +1 -1
- package/dist/src/network/network-manager-service.d.ts +10 -5
- package/dist/src/network/network-manager-service.d.ts.map +1 -1
- package/dist/src/network/network-manager-service.js +11 -2
- package/dist/src/network/network-manager-service.js.map +1 -1
- package/dist/src/network/relay-reservation.d.ts +170 -0
- package/dist/src/network/relay-reservation.d.ts.map +1 -0
- package/dist/src/network/relay-reservation.js +527 -0
- package/dist/src/network/relay-reservation.js.map +1 -0
- package/dist/src/pend-validation.d.ts +3 -2
- package/dist/src/pend-validation.d.ts.map +1 -1
- package/dist/src/pend-validation.js +3 -2
- package/dist/src/pend-validation.js.map +1 -1
- package/dist/src/protocol-client.d.ts +8 -1
- package/dist/src/protocol-client.d.ts.map +1 -1
- package/dist/src/protocol-client.js +11 -0
- package/dist/src/protocol-client.js.map +1 -1
- package/dist/src/reactivity/forwarder-host.d.ts +2 -1
- package/dist/src/reactivity/forwarder-host.d.ts.map +1 -1
- package/dist/src/reactivity/forwarder-host.js +2 -1
- package/dist/src/reactivity/forwarder-host.js.map +1 -1
- package/dist/src/reactivity/origination-manager.d.ts +3 -3
- package/dist/src/reactivity/origination-manager.js +3 -3
- package/dist/src/reactivity/recover-transport.d.ts +22 -14
- package/dist/src/reactivity/recover-transport.d.ts.map +1 -1
- package/dist/src/reactivity/recover-transport.js +32 -19
- package/dist/src/reactivity/recover-transport.js.map +1 -1
- package/dist/src/reactivity/subscription-manager.d.ts +2 -2
- package/dist/src/reactivity/topic-bytes.d.ts +6 -7
- package/dist/src/reactivity/topic-bytes.d.ts.map +1 -1
- package/dist/src/reactivity/topic-bytes.js +8 -9
- package/dist/src/reactivity/topic-bytes.js.map +1 -1
- package/dist/src/repo/client.d.ts +5 -2
- package/dist/src/repo/client.d.ts.map +1 -1
- package/dist/src/repo/client.js +49 -40
- package/dist/src/repo/client.js.map +1 -1
- package/dist/src/repo/cluster-coordinator.d.ts +119 -5
- package/dist/src/repo/cluster-coordinator.d.ts.map +1 -1
- package/dist/src/repo/cluster-coordinator.js +181 -29
- package/dist/src/repo/cluster-coordinator.js.map +1 -1
- package/dist/src/repo/coordinator-repo.d.ts +259 -76
- package/dist/src/repo/coordinator-repo.d.ts.map +1 -1
- package/dist/src/repo/coordinator-repo.js +716 -328
- package/dist/src/repo/coordinator-repo.js.map +1 -1
- package/dist/src/repo/i-under-replication-ledger.d.ts +87 -0
- package/dist/src/repo/i-under-replication-ledger.d.ts.map +1 -0
- package/dist/src/repo/i-under-replication-ledger.js +2 -0
- package/dist/src/repo/i-under-replication-ledger.js.map +1 -0
- package/dist/src/repo/kv-under-replication-ledger.d.ts +91 -0
- package/dist/src/repo/kv-under-replication-ledger.d.ts.map +1 -0
- package/dist/src/repo/kv-under-replication-ledger.js +287 -0
- package/dist/src/repo/kv-under-replication-ledger.js.map +1 -0
- package/dist/src/repo/responsibility.d.ts +37 -0
- package/dist/src/repo/responsibility.d.ts.map +1 -0
- package/dist/src/repo/responsibility.js +37 -0
- package/dist/src/repo/responsibility.js.map +1 -0
- package/dist/src/repo/service.d.ts +44 -15
- package/dist/src/repo/service.d.ts.map +1 -1
- package/dist/src/repo/service.js +64 -27
- package/dist/src/repo/service.js.map +1 -1
- package/dist/src/repo/stuck-reservation.d.ts +127 -0
- package/dist/src/repo/stuck-reservation.d.ts.map +1 -0
- package/dist/src/repo/stuck-reservation.js +179 -0
- package/dist/src/repo/stuck-reservation.js.map +1 -0
- package/dist/src/repo/under-replication-drain.d.ts +208 -0
- package/dist/src/repo/under-replication-drain.d.ts.map +1 -0
- package/dist/src/repo/under-replication-drain.js +461 -0
- package/dist/src/repo/under-replication-drain.js.map +1 -0
- package/dist/src/rn.d.ts +5 -0
- package/dist/src/rn.d.ts.map +1 -1
- package/dist/src/rn.js +5 -0
- package/dist/src/rn.js.map +1 -1
- package/dist/src/storage/block-latch.d.ts +3 -2
- package/dist/src/storage/block-latch.d.ts.map +1 -1
- package/dist/src/storage/block-latch.js +7 -4
- package/dist/src/storage/block-latch.js.map +1 -1
- package/dist/src/storage/block-storage.d.ts +45 -3
- package/dist/src/storage/block-storage.d.ts.map +1 -1
- package/dist/src/storage/block-storage.js +156 -9
- package/dist/src/storage/block-storage.js.map +1 -1
- package/dist/src/storage/i-block-storage.d.ts +57 -5
- package/dist/src/storage/i-block-storage.d.ts.map +1 -1
- package/dist/src/storage/i-block-storage.js.map +1 -1
- package/dist/src/storage/pending-claim.d.ts +167 -0
- package/dist/src/storage/pending-claim.d.ts.map +1 -0
- package/dist/src/storage/pending-claim.js +156 -0
- package/dist/src/storage/pending-claim.js.map +1 -0
- package/dist/src/storage/raw-store-codec.d.ts +13 -0
- package/dist/src/storage/raw-store-codec.d.ts.map +1 -1
- package/dist/src/storage/raw-store-codec.js +24 -3
- package/dist/src/storage/raw-store-codec.js.map +1 -1
- package/dist/src/storage/restoration-coordinator.d.ts.map +1 -1
- package/dist/src/storage/restoration-coordinator.js +2 -1
- package/dist/src/storage/restoration-coordinator.js.map +1 -1
- package/dist/src/storage/ring-shift-coordinator.d.ts.map +1 -1
- package/dist/src/storage/ring-shift-coordinator.js +3 -3
- package/dist/src/storage/ring-shift-coordinator.js.map +1 -1
- package/dist/src/storage/storage-repo.d.ts +137 -5
- package/dist/src/storage/storage-repo.d.ts.map +1 -1
- package/dist/src/storage/storage-repo.js +273 -68
- package/dist/src/storage/storage-repo.js.map +1 -1
- package/dist/src/storage/struct.d.ts +58 -0
- package/dist/src/storage/struct.d.ts.map +1 -1
- package/dist/src/testing/mesh-harness.d.ts +92 -11
- package/dist/src/testing/mesh-harness.d.ts.map +1 -1
- package/dist/src/testing/mesh-harness.js +246 -103
- package/dist/src/testing/mesh-harness.js.map +1 -1
- package/package.json +2 -2
- package/readme.md +27 -3
- package/src/cluster/block-transfer-service.ts +132 -4
- package/src/cluster/block-transfer.ts +79 -84
- package/src/cluster/client.ts +115 -119
- package/src/cluster/cluster-policy.ts +2 -1
- package/src/cluster/cluster-repo.ts +3115 -2671
- package/src/cluster/commit-proof.ts +2 -2
- package/src/cluster/race-resolution.ts +76 -7
- package/src/cluster/rebalance-monitor.ts +677 -539
- package/src/cluster/spread-on-churn.ts +34 -54
- package/src/cohort-topic/host.ts +8 -6
- package/src/cohort-topic/membership-source.ts +1 -1
- package/src/cohort-topic/peer-codec.ts +34 -31
- package/src/cohort-topic/stream-util.ts +39 -4
- package/src/cohort-topic/topic-router.ts +12 -2
- package/src/dispute/client.ts +17 -7
- package/src/index.ts +64 -59
- package/src/libp2p-key-network.ts +1377 -1253
- package/src/libp2p-node-base.ts +186 -27
- package/src/libp2p-node-rn.ts +31 -30
- package/src/libp2p-node.ts +37 -36
- package/src/logger.ts +20 -7
- package/src/matchmaking/query-transport.ts +9 -9
- package/src/network/network-manager-service.ts +16 -5
- package/src/network/relay-reservation.ts +636 -0
- package/src/pend-validation.ts +3 -2
- package/src/protocol-client.ts +13 -1
- package/src/reactivity/forwarder-host.ts +2 -1
- package/src/reactivity/origination-manager.ts +3 -3
- package/src/reactivity/recover-transport.ts +39 -22
- package/src/reactivity/subscription-manager.ts +2 -2
- package/src/reactivity/topic-bytes.ts +35 -37
- package/src/repo/client.ts +172 -173
- package/src/repo/cluster-coordinator.ts +1296 -1113
- package/src/repo/coordinator-repo.ts +3087 -2687
- package/src/repo/i-under-replication-ledger.ts +89 -0
- package/src/repo/kv-under-replication-ledger.ts +302 -0
- package/src/repo/responsibility.ts +48 -0
- package/src/repo/service.ts +76 -39
- package/src/repo/stuck-reservation.ts +224 -0
- package/src/repo/under-replication-drain.ts +582 -0
- package/src/rn.ts +74 -69
- package/src/storage/block-latch.ts +7 -4
- package/src/storage/block-storage.ts +161 -10
- package/src/storage/i-block-storage.ts +60 -5
- package/src/storage/pending-claim.ts +200 -0
- package/src/storage/raw-store-codec.ts +26 -3
- package/src/storage/restoration-coordinator.ts +212 -211
- package/src/storage/ring-shift-coordinator.ts +271 -271
- package/src/storage/storage-repo.ts +311 -73
- package/src/storage/struct.ts +58 -0
- package/src/testing/mesh-harness.ts +329 -115
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { blockIdsForTransforms } from '@optimystic/db-core';
|
|
2
2
|
import { ProtocolClient } from '../protocol-client.js';
|
|
3
3
|
import { peerIdFromString } from '@libp2p/peer-id';
|
|
4
4
|
import { isClusterErrorEnvelope, clusterErrorFromEnvelope } from './cluster-error.js';
|
|
@@ -55,7 +55,7 @@ export class ClusterClient extends ProtocolClient {
|
|
|
55
55
|
// notice we get that this peer matters, and if it is relay-only we have no address
|
|
56
56
|
// for it at all. Merging after the dial would help only some later hop.
|
|
57
57
|
this.peerNetwork.recordPeerAddresses?.(nextId, next.addrs ?? []);
|
|
58
|
-
|
|
58
|
+
this.recordCoordinatorForRecordIfSupported(record, nextId);
|
|
59
59
|
const nextClient = ClusterClient.create(nextId, this.peerNetwork, this.protocolPrefix);
|
|
60
60
|
// Thread the caller's *original* options through the redirect hop (the
|
|
61
61
|
// recursive call re-applies its own defaults) so the deadline survives a redirect.
|
|
@@ -91,14 +91,12 @@ export class ClusterClient extends ProtocolClient {
|
|
|
91
91
|
* Reading `record.message.commit`/`.pend` (the old code) always saw
|
|
92
92
|
* `undefined`, so this hint was dead code and never recorded anything.
|
|
93
93
|
*
|
|
94
|
-
*
|
|
95
|
-
*
|
|
96
|
-
* (
|
|
97
|
-
*
|
|
98
|
-
* anchors on a real block id (blockIdsForTransforms), not a structural
|
|
99
|
-
* transforms field name. ClusterClient only ever carries commit/pend.
|
|
94
|
+
* Commit anchors on blockIds[0] (where CoordinatorRepo runs consensus +
|
|
95
|
+
* verifyResponsibility), not tailId. Pend anchors on a real block id
|
|
96
|
+
* (blockIdsForTransforms), not a structural transforms field name.
|
|
97
|
+
* ClusterClient only ever carries commit/pend.
|
|
100
98
|
*/
|
|
101
|
-
|
|
99
|
+
recordCoordinatorForRecordIfSupported(record, peerId) {
|
|
102
100
|
const op = record.message.operations[0];
|
|
103
101
|
if (!op)
|
|
104
102
|
return;
|
|
@@ -109,10 +107,7 @@ export class ClusterClient extends ProtocolClient {
|
|
|
109
107
|
id = blockIdsForTransforms(op.pend.transforms)[0];
|
|
110
108
|
if (id == null)
|
|
111
109
|
return;
|
|
112
|
-
|
|
113
|
-
const pn = this.peerNetwork;
|
|
114
|
-
if (typeof pn?.recordCoordinator === 'function')
|
|
115
|
-
pn.recordCoordinator(kbytes, peerId);
|
|
110
|
+
this.recordCoordinatorHint(id, peerId);
|
|
116
111
|
}
|
|
117
112
|
}
|
|
118
113
|
//# sourceMappingURL=client.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"client.js","sourceRoot":"","sources":["../../../src/cluster/client.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"client.js","sourceRoot":"","sources":["../../../src/cluster/client.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,qBAAqB,EAAE,MAAM,qBAAqB,CAAC;AAC5D,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AACnD,OAAO,EAAE,sBAAsB,EAAE,wBAAwB,EAAE,MAAM,oBAAoB,CAAC;AAEtF,OAAO,EAAE,wBAAwB,EAAE,MAAM,yBAAyB,CAAC;AACnE,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAC5C,OAAO,EAAE,uBAAuB,EAA2B,MAAM,oBAAoB,CAAC;AACtF,OAAO,EAAE,yBAAyB,EAAE,MAAM,uBAAuB,CAAC;AAElE,MAAM,GAAG,GAAG,YAAY,CAAC,gBAAgB,CAAC,CAAC;AAE3C,MAAM,OAAO,aAAc,SAAQ,cAAc;IACwB;IAAxE,YAAoB,MAAc,EAAE,WAAyB,EAAW,cAAuB;QAC9F,KAAK,CAAC,MAAM,EAAE,WAAW,CAAC,CAAC;QAD4C,mBAAc,GAAd,cAAc,CAAS;IAE/F,CA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,CAAC,CAAA;IACtG,CAAC;IAEA;;;;;;;;;;;;;OAaG;IACK,qCAAqC,CAAC,MAAqB,EAAE,MAAc;QACjF,MAAM,EAAE,GAAG,MAAM,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC,CAAC,CAAA;QACvC,IAAI,CAAC,EAAE;YAAE,OAAM;QACf,IAAI,EAAsB,CAAA;QAC1B,IAAI,QAAQ,IAAI,EAAE;YAAE,EAAE,GAAG,EAAE,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAA;aACzC,IAAI,MAAM,IAAI,EAAE;YAAE,EAAE,GAAG,qBAAqB,CAAC,EAAE,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,CAAA;QACxE,IAAI,EAAE,IAAI,IAAI;YAAE,OAAM;QACtB,IAAI,CAAC,qBAAqB,CAAC,EAAE,EAAE,MAAM,CAAC,CAAA;IACxC,CAAC;CACF"}
|
|
@@ -142,7 +142,8 @@ export interface ClusterPolicyOptions {
|
|
|
142
142
|
repairCorroborationClusterSize?: number;
|
|
143
143
|
/**
|
|
144
144
|
* What a validator-configured member does with a pend that carries no `validation` payload
|
|
145
|
-
* (nothing to re-execute —
|
|
145
|
+
* (nothing to re-execute — a single-collection `Collection.sync` pend, or the Quereus
|
|
146
|
+
* adapter's legacy multi-tree commit, which pends through an unvalidated coordinator). Default 'accept';
|
|
146
147
|
* see {@link UnvalidatablePendPolicy}.
|
|
147
148
|
*/
|
|
148
149
|
unvalidatablePendPolicy?: UnvalidatablePendPolicy;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cluster-policy.d.ts","sourceRoot":"","sources":["../../../src/cluster/cluster-policy.ts"],"names":[],"mappings":"AAAA,OAAO,EAAoC,KAAK,sBAAsB,EAAE,KAAK,uBAAuB,EAAE,MAAM,qBAAqB,CAAC;AAMlI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsDG;AAEH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,kBAAkB,EAAE,mBAAmB;YACvC,kBAAkB;YAClB,0FAA0F;YAC1F,kDAAkD;YAClD,kBAAkB;YAClB,gBAAgB;YAChB,cAAc;YACd,sBAAsB;YACtB,4BAA4B;YAC5B,OAAO,EAAE,IAAI,GAAG,gBAAgB,GAAG,cAAc,GAAG,eAAe,GAAG,aAAa;SACnF,CAAC,CAAC;IACJ,CAAC;IAED,OAAO;QACN,sBAAsB,EAAE,OAAO,CAAC,aAAa,EAAE,sBAAsB,IAAI,gCAAgC;QACzG,uBAAuB,EAAE,IAAI;QAC7B,sBAAsB;QACtB,oBAAoB,EAAE,OAAO,CAAC,aAAa,EAAE,aAAa,IAAI,IAAI;QAClE,oBAAoB,EAAE,OAAO,CAAC,aAAa,EAAE,aAAa,IAAI,GAAG;QACjE,2FAA2F;QAC3F,oFAAoF;QACpF,4BAA4B,EAAE,OAAO,CAAC,aAAa,EAAE,4BAA4B,IAAI,KAAK;QAC1F,yFAAyF;QACzF,yCAAyC;QACzC,uBAAuB,EAAE,OAAO,CAAC,aAAa,EAAE,uBAAuB;QACvE,wBAAwB,EAAE,KAAK;QAC/B,8FAA8F;QAC9F,gGAAgG;QAChG,qFAAqF;QACrF,WAAW;QACX,+FAA+F;QAC/F,8FAA8F;QAC9F,0EAA0E;QAC1E,kBAAkB,EAAE,kBAAkB,IAAI,sBAAsB;QAChE,+FAA+F;QAC/F,8FAA8F;QAC9F,4FAA4F;QAC5F,mEAAmE;QACnE,8BAA8B;KAC9B,CAAC;AACH,CAAC"}
|
|
@@ -8,6 +8,7 @@ import type { FretService } from "p2p-fret";
|
|
|
8
8
|
import type { IPeerReputation } from "../reputation/types.js";
|
|
9
9
|
import type { ITransactionStateStore } from "./i-transaction-state-store.js";
|
|
10
10
|
import { type BlockCommitProof } from "./commit-proof.js";
|
|
11
|
+
import type { CommittedHolders } from "./rebalance-monitor.js";
|
|
11
12
|
/**
|
|
12
13
|
* Actively reconciles a block this member committed without having seen the matching
|
|
13
14
|
* pend (cohort drift between the independent pend and commit cluster-transactions).
|
|
@@ -29,6 +30,14 @@ export type ReconcileBlockCallback = (blockId: BlockId, committed: ActionRev, co
|
|
|
29
30
|
* isolated + logged (it must never break consensus).
|
|
30
31
|
*/
|
|
31
32
|
export type CommitCertificateSink = (actionId: ActionId, cert: CommitCert) => void;
|
|
33
|
+
/**
|
|
34
|
+
* Sink for who is known to hold a commit this node's own storage durably holds — fed to the rebalance
|
|
35
|
+
* monitor so it does not push freshly committed blocks back to the members that stored them (see
|
|
36
|
+
* `RebalanceMonitor.recordCommittedHolders`). Fired by the member after applying a consensus commit,
|
|
37
|
+
* and by `CoordinatorRepo.commit` when it acknowledges one. Optional; a throwing sink is isolated +
|
|
38
|
+
* logged (it must never break consensus or the writer's answer).
|
|
39
|
+
*/
|
|
40
|
+
export type CommittedHoldersSink = (committed: CommittedHolders) => void;
|
|
32
41
|
/**
|
|
33
42
|
* Applies a consensus-ordered {@link InvalidateRequest} to local storage — the deterministic
|
|
34
43
|
* reversal every member runs once consensus on the invalidation is reached. The implementation
|
|
@@ -88,6 +97,13 @@ export declare const MEMBERSHIP_NOT_ADMITTED = "membership-not-admitted";
|
|
|
88
97
|
* so the rejection itself is integrity-protected.
|
|
89
98
|
*/
|
|
90
99
|
export declare const CONTENT_DIGEST_MISMATCH = "content-digest-mismatch";
|
|
100
|
+
/**
|
|
101
|
+
* Stable reject reason a member emits when a commit declares, for a block, a base revision
|
|
102
|
+
* (`CommitRequest.blockDigests[id].baseRev`) other than the one the same action's pend carried to
|
|
103
|
+
* this member (`PendRequest.baseRevs`, kept with the pending record) — see
|
|
104
|
+
* `ClusterMember.validateCommitBaseDeclarations`. Signed like its sibling above.
|
|
105
|
+
*/
|
|
106
|
+
export declare const BASE_DECLARATION_DISAGREES = "base-declaration-disagrees";
|
|
91
107
|
/**
|
|
92
108
|
* The two stable reject reasons a validator-configured member emits from the shared
|
|
93
109
|
* {@link checkPendValidation}: `PEND_NOT_VALIDATABLE` for a pend carrying no `validation` payload
|
|
@@ -112,6 +128,8 @@ interface ClusterMemberComponents {
|
|
|
112
128
|
reconcileBlock?: ReconcileBlockCallback;
|
|
113
129
|
/** Receives the consensus commit cert per committed action; see {@link CommitCertificateSink}. */
|
|
114
130
|
onCommitCertificate?: CommitCertificateSink;
|
|
131
|
+
/** Receives who holds each consensus commit this member durably applied; see {@link CommittedHoldersSink}. */
|
|
132
|
+
onCommittedHolders?: CommittedHoldersSink;
|
|
115
133
|
/** Applies a consensus-ordered invalidation to local storage; see {@link InvalidationApplySink}. */
|
|
116
134
|
onInvalidate?: InvalidationApplySink;
|
|
117
135
|
/** Layer-2 arbitrator-set recompute for invalidation verification; see {@link RecomputeArbitratorSetCapability}. */
|
|
@@ -159,12 +177,21 @@ export declare class ClusterMember implements ICluster {
|
|
|
159
177
|
private readonly onInvalidate?;
|
|
160
178
|
private readonly recomputeArbitratorSet?;
|
|
161
179
|
private readonly deriveExpectedCluster?;
|
|
180
|
+
private readonly onCommittedHolders?;
|
|
162
181
|
private activeTransactions;
|
|
163
182
|
private executedTransactions;
|
|
164
183
|
private executedPendResults;
|
|
165
184
|
private executedCommitResults;
|
|
166
185
|
private refusedPendActions;
|
|
167
186
|
private appliedInvalidations;
|
|
187
|
+
/**
|
|
188
|
+
* Per block, what this member's own `held` votes have added up to — the member-side instance of
|
|
189
|
+
* the counter `CoordinatorRepo.noteStuckReservation` keeps from the coordinator's vantage. Fed by
|
|
190
|
+
* every `held` verdict {@link validatePendOperations} casts, so a reservation only THIS member
|
|
191
|
+
* holds (one the coordinator's storage cannot corroborate) is still named, once, where the record
|
|
192
|
+
* lives. Forgotten for a block the moment a vote finds it no longer reserved.
|
|
193
|
+
*/
|
|
194
|
+
private readonly stuckReservations;
|
|
168
195
|
private cleanupQueue;
|
|
169
196
|
private pendingUpdates;
|
|
170
197
|
private readonly expirationInterval;
|
|
@@ -193,7 +220,7 @@ export declare class ClusterMember implements ICluster {
|
|
|
193
220
|
private readonly unvalidatablePendPolicy;
|
|
194
221
|
/** Clock behind the reservation table's `lastUpdate` — see {@link ClusterMemberComponents.now}. */
|
|
195
222
|
private readonly now;
|
|
196
|
-
constructor(storageRepo: IRepo, peerNetwork: IPeerNetwork, peerId: PeerId, privateKey: PrivateKey, protocolPrefix?: string | undefined, _partitionDetector?: PartitionDetector, fretService?: FretService | undefined, validator?: ITransactionValidator | undefined, reputation?: IPeerReputation | undefined, consensusConfig?: ClusterConsensusConfig, stateStore?: ITransactionStateStore | undefined, reconcileBlock?: ReconcileBlockCallback | undefined, onCommitCertificate?: CommitCertificateSink | undefined, onInvalidate?: InvalidationApplySink | undefined, recomputeArbitratorSet?: RecomputeArbitratorSetCapability | undefined, deriveExpectedCluster?: DeriveExpectedClusterCallback | undefined, now?: () => number);
|
|
223
|
+
constructor(storageRepo: IRepo, peerNetwork: IPeerNetwork, peerId: PeerId, privateKey: PrivateKey, protocolPrefix?: string | undefined, _partitionDetector?: PartitionDetector, fretService?: FretService | undefined, validator?: ITransactionValidator | undefined, reputation?: IPeerReputation | undefined, consensusConfig?: ClusterConsensusConfig, stateStore?: ITransactionStateStore | undefined, reconcileBlock?: ReconcileBlockCallback | undefined, onCommitCertificate?: CommitCertificateSink | undefined, onInvalidate?: InvalidationApplySink | undefined, recomputeArbitratorSet?: RecomputeArbitratorSetCapability | undefined, deriveExpectedCluster?: DeriveExpectedClusterCallback | undefined, now?: () => number, onCommittedHolders?: CommittedHoldersSink | undefined);
|
|
197
224
|
/**
|
|
198
225
|
* The resolved super-majority threshold this member runs on. Exposed so the composition root can
|
|
199
226
|
* fail-fast if the member and the coordinator would run different thresholds (see the coupling
|
|
@@ -223,13 +250,15 @@ export declare class ClusterMember implements ICluster {
|
|
|
223
250
|
*/
|
|
224
251
|
getExecutedPendResult(messageHash: string): PendResult | undefined;
|
|
225
252
|
/**
|
|
226
|
-
* Commit-shaped sibling of {@link getExecutedPendResult}:
|
|
227
|
-
* operation applied during consensus, when
|
|
228
|
-
*
|
|
229
|
-
*
|
|
230
|
-
*
|
|
231
|
-
*
|
|
232
|
-
*
|
|
253
|
+
* Commit-shaped sibling of {@link getExecutedPendResult}: this member's post-reconcile durable
|
|
254
|
+
* verdict for a commit operation applied during consensus, when it retained one — `success: true`
|
|
255
|
+
* iff local storage holds the committed revision under the record's action for every block the
|
|
256
|
+
* commit named, after the apply and any behind-reconcile it triggered. `CoordinatorRepo.commit`
|
|
257
|
+
* reads it after a locally-executed commit-consensus, both as this node's own contribution to the
|
|
258
|
+
* durable-holder count its durability gate needs, and — for a retained refusal whose cause a
|
|
259
|
+
* local re-read confirms as a rival holding the requested revision — as the trigger for a
|
|
260
|
+
* retryable conflict answer. Same availability caveats as the pend accessor: in-memory only,
|
|
261
|
+
* absent for pre-restart applies, pruned on the executed-transaction TTL.
|
|
233
262
|
*/
|
|
234
263
|
getExecutedCommitResult(messageHash: string): CommitResult | undefined;
|
|
235
264
|
/**
|
|
@@ -247,10 +276,12 @@ export declare class ClusterMember implements ICluster {
|
|
|
247
276
|
update(record: ClusterRecord): Promise<ClusterRecord>;
|
|
248
277
|
private processUpdate;
|
|
249
278
|
/**
|
|
250
|
-
* Add this member's own
|
|
251
|
-
*
|
|
252
|
-
*
|
|
253
|
-
*
|
|
279
|
+
* Add this member's own apply verdicts to a record's {@link ClusterRecord.applyOutcomes}, when
|
|
280
|
+
* storage produced any for this transaction. The two arms follow the rules on
|
|
281
|
+
* {@link MemberApplyOutcome}: the pend arm carries ONLY a conflict-shaped refusal (a success, a
|
|
282
|
+
* bare-reason fault, or no retained verdict leaves it off — the coordinator's rule is "an entry
|
|
283
|
+
* means retry", so an entry that does not mean retry must not exist); the commit arm carries the
|
|
284
|
+
* retained durable verdict whatever it says, because the coordinator counts the successes.
|
|
254
285
|
*
|
|
255
286
|
* The member never signs this and never writes another peer's entry.
|
|
256
287
|
*/
|
|
@@ -262,8 +293,9 @@ export declare class ClusterMember implements ICluster {
|
|
|
262
293
|
private mergeRecords;
|
|
263
294
|
/**
|
|
264
295
|
* Compares existing vs incoming signatures for the same peers.
|
|
265
|
-
*
|
|
266
|
-
*
|
|
296
|
+
* ANY change of vote type is equivocation — the comparison is over `Signature['type']`, so it
|
|
297
|
+
* covers every kind without enumerating them (a new kind joins the check by existing): report a
|
|
298
|
+
* penalty and keep the first-seen signature.
|
|
267
299
|
* New peers are accepted normally.
|
|
268
300
|
*/
|
|
269
301
|
private detectEquivocation;
|
|
@@ -302,6 +334,13 @@ export declare class ClusterMember implements ICluster {
|
|
|
302
334
|
private getTransactionPhase;
|
|
303
335
|
private hasMajority;
|
|
304
336
|
private handlePromiseNeeded;
|
|
337
|
+
/**
|
|
338
|
+
* Turn a {@link PromiseVerdict} into this member's signed promise vote — one vote kind per refusal
|
|
339
|
+
* kind. The single place the mapping lives, so a new refusal kind cannot reach the wire as the
|
|
340
|
+
* wrong vote: the coordinator's thresholds read only `Signature.type`, and until `held` existed the
|
|
341
|
+
* transient refusal had nowhere to go but `reject`.
|
|
342
|
+
*/
|
|
343
|
+
private signPromiseVerdict;
|
|
305
344
|
/**
|
|
306
345
|
* Answer a record that lost the deterministic race to a transaction this member already holds
|
|
307
346
|
* (`docs/correctness.md` Theorems 1 & 9: the loser is TOLD it lost, not ignored — an unanswered
|
|
@@ -314,8 +353,10 @@ export declare class ClusterMember implements ICluster {
|
|
|
314
353
|
private handleConflictVoteNeeded;
|
|
315
354
|
/**
|
|
316
355
|
* The full promise-phase decision for a record: admit the declared membership FIRST, then (only if
|
|
317
|
-
* admitted) validate its pend operations, then its commit operations. Failing any yields a
|
|
318
|
-
*
|
|
356
|
+
* admitted) validate its pend operations, then its commit operations. Failing any yields a refusal
|
|
357
|
+
* the caller turns into a vote — a `reject` for every validity judgement here, and a `held` for the
|
|
358
|
+
* one transient refusal {@link validatePendOperations} can make (see {@link PromiseVerdict}).
|
|
359
|
+
* Keeping the checks separate keeps
|
|
319
360
|
* the reason strings distinct — a `membership-not-admitted` reject is a different signal (feeds the
|
|
320
361
|
* dispute path) than a stale-revision / custom-validator reject, which is different again from a
|
|
321
362
|
* `content-digest-mismatch` (see {@link validateCommitOperations}). A record carries pend OR commit
|
|
@@ -395,11 +436,47 @@ export declare class ClusterMember implements ICluster {
|
|
|
395
436
|
private static symmetricDifferenceSize;
|
|
396
437
|
/**
|
|
397
438
|
* Validates pend operations in a cluster record using the transaction validator.
|
|
398
|
-
* Also checks for stale revisions, and for blocks
|
|
439
|
+
* Also checks for stale revisions, and for blocks RESERVED by a different unresolved pending
|
|
399
440
|
* action, to prevent consensus on operations that storage would refuse at apply.
|
|
400
441
|
* Returns success if no validator is configured (backwards compatibility).
|
|
442
|
+
*
|
|
443
|
+
* Every refusal here is a validity judgement EXCEPT the pending-conflict one, which is transient by
|
|
444
|
+
* construction and returns the `held` kind — see {@link PromiseVerdict}. Transient means the
|
|
445
|
+
* reservation it answers is one its holder is still going to commit or cancel: a record claiming
|
|
446
|
+
* the slot this pend wants, or a later one. A record claiming a slot the collection has already
|
|
447
|
+
* moved past is NOT a reservation against this pend and is not refused on — see
|
|
448
|
+
* {@link reservingRivals} — because its holder is never going to remove it: the holder either
|
|
449
|
+
* committed at that slot on the rest of the cohort (this member missed the commit) or lost the
|
|
450
|
+
* slot, and in both cases the record would otherwise refuse every later write to the block, from
|
|
451
|
+
* every writer, for as long as this member lives.
|
|
401
452
|
*/
|
|
402
453
|
private validatePendOperations;
|
|
454
|
+
/**
|
|
455
|
+
* Of the rival pending records `get` listed on `blockId`, the ones that RESERVE the block against
|
|
456
|
+
* `pendRequest` — see `isReservationAgainst` for the rule, fed the pend's revision and the base it
|
|
457
|
+
* declares for this block (`reservationRequestFor`, the same reading storage applies at apply).
|
|
458
|
+
* Asks storage's {@link IPendingClaimReader} for the slot each record claims; a repo without that
|
|
459
|
+
* capability (a plain `IRepo` mock) or a read that fails degrades to "every rival reserves", which
|
|
460
|
+
* is the refusal this member cast before claims were recorded — never to silently admitting one. A
|
|
461
|
+
* rival that `get` listed but that is gone by the time the claims are read has resolved in
|
|
462
|
+
* between, and is not a rival any more.
|
|
463
|
+
*/
|
|
464
|
+
private reservingRivals;
|
|
465
|
+
/** `pendRequest`'s {@link ReservationRequest} for `blockId`, logging a base the rule cannot read —
|
|
466
|
+
* never a refusal: `baseRevs` is untrusted wire data, and a malformed entry only drops that block
|
|
467
|
+
* back to the revision rule. The base is read only when `record`'s cohort can reach its promise
|
|
468
|
+
* super-majority without one of its members (`cohortCanMissAPend`); in a cohort that needs every
|
|
469
|
+
* member, a stray record on one member (a cancel that never reached it) would otherwise refuse
|
|
470
|
+
* every later writer for good, and no member can have missed the pend the base arm guards against. */
|
|
471
|
+
private reservationRequestOf;
|
|
472
|
+
/**
|
|
473
|
+
* Feed this member's own `held` vote to its {@link stuckReservations} counter and say, once per
|
|
474
|
+
* episode and in words, when a block is wedged behind a reservation that is not going to clear —
|
|
475
|
+
* the member-side twin of `CoordinatorRepo.noteStuckReservation`, for the reservations that
|
|
476
|
+
* node cannot corroborate from its own storage. `peerId` is carried because this logger is not
|
|
477
|
+
* suffixed with one and several members can share a process.
|
|
478
|
+
*/
|
|
479
|
+
private nameStuckReservation;
|
|
403
480
|
/**
|
|
404
481
|
* Promise-round check that a commit record's requested revision is not already committed HERE
|
|
405
482
|
* under a different action. This is the member-side arm that keeps a DEAD rival's re-broadcast
|
|
@@ -491,6 +568,43 @@ export declare class ClusterMember implements ICluster {
|
|
|
491
568
|
* it, or `undefined` for "no longer corroborated — abstain" (which a read fault also yields).
|
|
492
569
|
*/
|
|
493
570
|
private refusedPendConflictsWithLocalState;
|
|
571
|
+
/**
|
|
572
|
+
* Promise-round check that a commit declares, for each block, the base revision the same action's
|
|
573
|
+
* PEND carried to this member. The author says the base twice — `PendRequest.baseRevs[id]`, kept
|
|
574
|
+
* with this member's pending record as `PendingClaim.baseRev`, and
|
|
575
|
+
* `CommitRequest.blockDigests[id].baseRev` — and an honest author says the same thing both times
|
|
576
|
+
* (`Tracker` pins the base at staging; the pend and the digest both read that pin). When they
|
|
577
|
+
* differ, this member's record holds operations computed against a base other than the one the
|
|
578
|
+
* commit is about to be applied as, so vote reject with {@link BASE_DECLARATION_DISAGREES}.
|
|
579
|
+
* `StorageRepo.internalCommit` refuses the same shape at apply (`guardCommitBase`); refusing here
|
|
580
|
+
* too puts a signed verdict on the record one round earlier, and when the cohort's records agree
|
|
581
|
+
* with each other but not with the commit (a writer whose commit contradicts its own pend) the
|
|
582
|
+
* whole cohort refuses at the vote, where the apply-time refusal alone would have every member
|
|
583
|
+
* refuse after consensus and reconcile against a revision nobody holds.
|
|
584
|
+
*
|
|
585
|
+
* Needs no preview, so it runs on a repo that can read one record's claim
|
|
586
|
+
* ({@link IPendingClaimReader}`.pendingClaimOf`) whether or not it can materialize. Abstains — votes
|
|
587
|
+
* as it would without the check — whenever it cannot compare: the commit declares nothing, an entry
|
|
588
|
+
* is surplus to `blockIds` or carries no numeric `baseRev` (untrusted wire data, same posture as the
|
|
589
|
+
* digest check), this member holds no record for the action on the block, the record carries no
|
|
590
|
+
* base (an inserted or deleted block, a base-less sender, or a record written before bases were
|
|
591
|
+
* kept), the read fails — or this member does not hold the declared base as its latest.
|
|
592
|
+
*
|
|
593
|
+
* That last abstain is what keeps an HONEST retry off this reject. The one disagreement an honest
|
|
594
|
+
* writer can meet here is a stale record from an earlier attempt of a retried action (same action
|
|
595
|
+
* id) meeting the retry's commit, when the retry's pend — which would have overwritten the record
|
|
596
|
+
* — never reached this member. Such a member is typically behind: it missed a pend, and the retry
|
|
597
|
+
* declares a base the rest of the cohort moved to. At three members one reject sinks the commit
|
|
598
|
+
* record (the default super-majority allows none), where abstaining lets the others commit and
|
|
599
|
+
* leaves this member to `guardCommitBase`, which refuses to apply the stale record and reconciles.
|
|
600
|
+
* When this member's latest IS the declared base, the stale operations are exactly what it would
|
|
601
|
+
* apply over it, and the digest check below rejects the same shape whenever they materialize
|
|
602
|
+
* differently; rejecting here names the cause instead.
|
|
603
|
+
*/
|
|
604
|
+
private validateCommitBaseDeclarations;
|
|
605
|
+
/** This member's own committed revision of `blockId` (raw storage, no cluster recursion), or
|
|
606
|
+
* `undefined` when it holds none or the read fails — a fault reads as "cannot judge". */
|
|
607
|
+
private latestRevOf;
|
|
494
608
|
/**
|
|
495
609
|
* Promise-round check of a commit record's declared content digests
|
|
496
610
|
* (`CommitRequest.blockDigests`) against what this member's OWN pended copy of each transform
|
|
@@ -585,8 +699,39 @@ export declare class ClusterMember implements ICluster {
|
|
|
585
699
|
* mid-commit `internalCommit` fault (`success:false` with a bare `reason`, no
|
|
586
700
|
* `missing`) is propagated so {@link handleConsensus} rolls back the executed marker
|
|
587
701
|
* and rethrows — exactly like an unexpected thrown fault.
|
|
702
|
+
*
|
|
703
|
+
* Tolerated is not the same as acknowledged. Whatever shape a commit's apply took, this
|
|
704
|
+
* member retains one post-reconcile durable verdict for it ({@link durableCommitVerdict}) and
|
|
705
|
+
* reports it to the coordinator, whose durability gate (`CoordinatorRepo.commit`) acknowledges
|
|
706
|
+
* the writer only when a majority of the cohort reports holding the revision.
|
|
588
707
|
*/
|
|
589
708
|
private applyConsensusOperation;
|
|
709
|
+
/**
|
|
710
|
+
* Apply one consensus commit to local storage, tolerating every divergence shape the way the
|
|
711
|
+
* doc comment on {@link applyConsensusOperation} describes and reconciling the behind ones.
|
|
712
|
+
* Returns storage's own result — or, for the thrown missing-pend shape, which produces no
|
|
713
|
+
* `CommitResult` at all, a refusal built from the throw — so {@link durableCommitVerdict} works
|
|
714
|
+
* from one uniform shape. Genuine faults (a bare-reason returned failure, an unrecognized throw)
|
|
715
|
+
* propagate so {@link handleConsensus} rolls back the executed marker and rethrows.
|
|
716
|
+
*/
|
|
717
|
+
private applyCommitToStorage;
|
|
718
|
+
/**
|
|
719
|
+
* The durable verdict for a consensus commit: `applied` itself when storage landed it (a
|
|
720
|
+
* success from `StorageRepo.commit` means every block is committed, or already was, under this
|
|
721
|
+
* action), otherwise a fresh look at what local storage holds NOW — after the reconcile the
|
|
722
|
+
* refusal triggered. Durable means every block in `commit.blockIds` records `commit.rev` under
|
|
723
|
+
* `commit.actionId`. A refusal that is not durable is returned as-is, so the coordinating node
|
|
724
|
+
* can still classify its own member's ahead-shaped refusal against a rival. A read fault counts
|
|
725
|
+
* as not durable: the gate this feeds fails toward retry.
|
|
726
|
+
*/
|
|
727
|
+
private durableCommitVerdict;
|
|
728
|
+
/**
|
|
729
|
+
* True when local storage records `commit.rev` of `blockId` under `commit.actionId`. Read from
|
|
730
|
+
* the revision index (the {@link IRevisionActionReader} capability) so a member whose `latest` has
|
|
731
|
+
* since moved past the revision still counts as holding it; a repo without the capability is
|
|
732
|
+
* judged on `latest` alone.
|
|
733
|
+
*/
|
|
734
|
+
private holdsCommittedRevision;
|
|
590
735
|
/**
|
|
591
736
|
* Applies a consensus-ordered invalidation on this member: dedup → certificate verification →
|
|
592
737
|
* capture the invalidation's commit cert (for reactivity reuse) → delegate the compensating write +
|
|
@@ -611,6 +756,16 @@ export declare class ClusterMember implements ICluster {
|
|
|
611
756
|
* it can never break consensus.
|
|
612
757
|
*/
|
|
613
758
|
private captureCommitCert;
|
|
759
|
+
/**
|
|
760
|
+
* Tell the {@link CommittedHoldersSink} which cohort members hold a commit this member just
|
|
761
|
+
* durably applied. A member learns nothing about the others' storage at apply time, so the
|
|
762
|
+
* evidence is the record's approving commit signers: each is a cohort member that signed to apply
|
|
763
|
+
* this commit. A signer that then failed to apply is wrongly recorded, which only spares it a
|
|
764
|
+
* rebalance push; its own reconcile, read-repair, and — on the coordinating node — the
|
|
765
|
+
* coordinator's durability-checked report (which lands after this one and overrides it) still
|
|
766
|
+
* reach it.
|
|
767
|
+
*/
|
|
768
|
+
private reportCommittedHolders;
|
|
614
769
|
/**
|
|
615
770
|
* After tolerating a "behind" commit divergence, pull the committed revision of
|
|
616
771
|
* each block from a cohort peer that holds it and restore it locally. Best-effort:
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cluster-repo.d.ts","sourceRoot":"","sources":["../../../src/cluster/cluster-repo.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK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