@twin.org/synchronised-storage-service 0.0.3-next.9 → 0.9.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 +2 -2
- package/dist/es/helpers/blobStorageHelper.js +1 -1
- package/dist/es/helpers/blobStorageHelper.js.map +1 -1
- package/dist/es/helpers/changeSetHelper.js +3 -3
- package/dist/es/helpers/changeSetHelper.js.map +1 -1
- package/dist/es/helpers/localSyncStateHelper.js +7 -7
- package/dist/es/helpers/localSyncStateHelper.js.map +1 -1
- package/dist/es/helpers/remoteSyncStateHelper.js +14 -9
- package/dist/es/helpers/remoteSyncStateHelper.js.map +1 -1
- package/dist/es/helpers/versions.js +9 -0
- package/dist/es/helpers/versions.js.map +1 -1
- package/dist/es/restEntryPoints.js +3 -0
- package/dist/es/restEntryPoints.js.map +1 -1
- package/dist/es/synchronisedStorageRoutes.js +4 -2
- package/dist/es/synchronisedStorageRoutes.js.map +1 -1
- package/dist/es/synchronisedStorageService.js +14 -11
- package/dist/es/synchronisedStorageService.js.map +1 -1
- package/dist/types/helpers/blobStorageHelper.d.ts +1 -1
- package/dist/types/helpers/changeSetHelper.d.ts +3 -3
- package/dist/types/helpers/localSyncStateHelper.d.ts +5 -5
- package/dist/types/helpers/remoteSyncStateHelper.d.ts +10 -19
- package/dist/types/helpers/versions.d.ts +9 -0
- package/dist/types/restEntryPoints.d.ts +3 -0
- package/dist/types/synchronisedStorageService.d.ts +3 -3
- package/docs/changelog.md +229 -76
- package/docs/examples.md +80 -1
- package/docs/open-api/spec.json +17 -21
- package/docs/reference/classes/SyncSnapshotEntry.md +12 -12
- package/docs/reference/classes/SynchronisedStorageService.md +9 -9
- package/docs/reference/interfaces/ISyncPointerStore.md +2 -2
- package/docs/reference/interfaces/ISyncSnapshot.md +7 -7
- package/docs/reference/interfaces/ISyncState.md +3 -3
- package/docs/reference/interfaces/ISynchronisedStorageServiceConfig.md +13 -13
- package/docs/reference/interfaces/ISynchronisedStorageServiceConstructorOptions.md +19 -19
- package/docs/reference/variables/restEntryPoints.md +2 -0
- package/package.json +20 -22
package/docs/examples.md
CHANGED
|
@@ -1 +1,80 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Synchronised Storage Service Examples
|
|
2
|
+
|
|
3
|
+
These examples show common node-side synchronisation flows, from startup and scheduling to trusted key exchange and inbound change application.
|
|
4
|
+
|
|
5
|
+
## SynchronisedStorageService
|
|
6
|
+
|
|
7
|
+
```typescript
|
|
8
|
+
import { SynchronisedStorageService } from '@twin.org/synchronised-storage-service';
|
|
9
|
+
|
|
10
|
+
const service = new SynchronisedStorageService({
|
|
11
|
+
loggingComponentType: 'logging',
|
|
12
|
+
eventBusComponentType: 'event-bus',
|
|
13
|
+
taskSchedulerComponentType: 'task-scheduler',
|
|
14
|
+
config: {
|
|
15
|
+
verifiableStorageKeyId: 'devnet',
|
|
16
|
+
entityUpdateIntervalMinutes: 2,
|
|
17
|
+
consolidationIntervalMinutes: 30,
|
|
18
|
+
consolidationBatchSize: 200,
|
|
19
|
+
maxConsolidations: 8,
|
|
20
|
+
blobStorageEncryptionKeyId: 'sync-blob-key'
|
|
21
|
+
}
|
|
22
|
+
});
|
|
23
|
+
|
|
24
|
+
console.log(service.className()); // SynchronisedStorageService
|
|
25
|
+
|
|
26
|
+
await service.start('logging');
|
|
27
|
+
await service.stop('logging');
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
```typescript
|
|
31
|
+
import { SynchronisedStorageService } from '@twin.org/synchronised-storage-service';
|
|
32
|
+
|
|
33
|
+
const trustedService = new SynchronisedStorageService({
|
|
34
|
+
config: {
|
|
35
|
+
verifiableStorageKeyId: 'mainnet',
|
|
36
|
+
blobStorageEncryptionKeyId: 'sync-blob-key'
|
|
37
|
+
}
|
|
38
|
+
});
|
|
39
|
+
|
|
40
|
+
const trustPayload = 'eyJhbGciOiJFZERTQSJ9.trusted-node.signature';
|
|
41
|
+
const decryptionKey = await trustedService.getDecryptionKey(trustPayload);
|
|
42
|
+
|
|
43
|
+
console.log(decryptionKey.length); // 44
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
```typescript
|
|
47
|
+
import {
|
|
48
|
+
SynchronisedStorageContexts,
|
|
49
|
+
SynchronisedStorageTypes,
|
|
50
|
+
SyncChangeOperation,
|
|
51
|
+
type ISyncChangeSet
|
|
52
|
+
} from '@twin.org/synchronised-storage-models';
|
|
53
|
+
import { SynchronisedStorageService } from '@twin.org/synchronised-storage-service';
|
|
54
|
+
|
|
55
|
+
const trustedService = new SynchronisedStorageService({
|
|
56
|
+
config: {
|
|
57
|
+
verifiableStorageKeyId: 'testnet',
|
|
58
|
+
blobStorageEncryptionKeyId: 'sync-blob-key'
|
|
59
|
+
}
|
|
60
|
+
});
|
|
61
|
+
|
|
62
|
+
const changeSet: ISyncChangeSet = {
|
|
63
|
+
'@context': SynchronisedStorageContexts.Context,
|
|
64
|
+
type: SynchronisedStorageTypes.ChangeSet,
|
|
65
|
+
id: 'changeset-remote-7',
|
|
66
|
+
storageKey: 'profile',
|
|
67
|
+
dateCreated: '2026-03-10T12:00:00.000Z',
|
|
68
|
+
dateModified: '2026-03-10T12:00:00.000Z',
|
|
69
|
+
nodeIdentity: 'did:iota:node-9',
|
|
70
|
+
changes: [
|
|
71
|
+
{
|
|
72
|
+
operation: SyncChangeOperation.Delete,
|
|
73
|
+
id: 'profile-7'
|
|
74
|
+
}
|
|
75
|
+
]
|
|
76
|
+
};
|
|
77
|
+
|
|
78
|
+
const trustPayload = 'eyJhbGciOiJFZERTQSJ9.remote-node.signature';
|
|
79
|
+
await trustedService.syncChangeSet(changeSet, trustPayload);
|
|
80
|
+
```
|
package/docs/open-api/spec.json
CHANGED
|
@@ -228,6 +228,7 @@
|
|
|
228
228
|
"components": {
|
|
229
229
|
"schemas": {
|
|
230
230
|
"Error": {
|
|
231
|
+
"description": "Model to describe serialized error.",
|
|
231
232
|
"type": "object",
|
|
232
233
|
"properties": {
|
|
233
234
|
"name": {
|
|
@@ -236,7 +237,7 @@
|
|
|
236
237
|
},
|
|
237
238
|
"message": {
|
|
238
239
|
"type": "string",
|
|
239
|
-
"description": "The message for the error."
|
|
240
|
+
"description": "The message for the error as an i18n key."
|
|
240
241
|
},
|
|
241
242
|
"source": {
|
|
242
243
|
"type": "string",
|
|
@@ -258,10 +259,10 @@
|
|
|
258
259
|
"required": [
|
|
259
260
|
"name",
|
|
260
261
|
"message"
|
|
261
|
-
]
|
|
262
|
-
"description": "Model to describe serialized error."
|
|
262
|
+
]
|
|
263
263
|
},
|
|
264
264
|
"SyncChange": {
|
|
265
|
+
"description": "The object definition for a sync change.",
|
|
265
266
|
"type": "object",
|
|
266
267
|
"properties": {
|
|
267
268
|
"operation": {
|
|
@@ -278,34 +279,30 @@
|
|
|
278
279
|
"required": [
|
|
279
280
|
"operation",
|
|
280
281
|
"id"
|
|
281
|
-
]
|
|
282
|
-
"description": "The object definition for a sync change."
|
|
282
|
+
]
|
|
283
283
|
},
|
|
284
284
|
"SyncChangeOperation": {
|
|
285
|
+
"description": "The operations for a change",
|
|
285
286
|
"anyOf": [
|
|
286
287
|
{
|
|
287
|
-
"type": "string",
|
|
288
288
|
"const": "set",
|
|
289
289
|
"description": "An item was set in the storage."
|
|
290
290
|
},
|
|
291
291
|
{
|
|
292
|
-
"type": "string",
|
|
293
292
|
"const": "delete",
|
|
294
293
|
"description": "An item was deleted from the storage."
|
|
295
294
|
}
|
|
296
|
-
]
|
|
297
|
-
"description": "The operations for a change. The operations for a change"
|
|
295
|
+
]
|
|
298
296
|
},
|
|
299
297
|
"SyncChangeSet": {
|
|
298
|
+
"description": "The object definition for a sync change set.",
|
|
300
299
|
"type": "object",
|
|
301
300
|
"properties": {
|
|
302
301
|
"@context": {
|
|
303
|
-
"type": "string",
|
|
304
302
|
"const": "https://schema.twindev.org/synchronised-storage/",
|
|
305
303
|
"description": "The LD Context for the change set."
|
|
306
304
|
},
|
|
307
305
|
"type": {
|
|
308
|
-
"type": "string",
|
|
309
306
|
"const": "ChangeSet",
|
|
310
307
|
"description": "The LD Type for the change set."
|
|
311
308
|
},
|
|
@@ -315,26 +312,26 @@
|
|
|
315
312
|
},
|
|
316
313
|
"storageKey": {
|
|
317
314
|
"type": "string",
|
|
318
|
-
"description": "The storage key of the change set. This is used to identify the entities being synchronised.
|
|
315
|
+
"description": "The storage key of the change set. This is used to identify the entities being synchronised."
|
|
319
316
|
},
|
|
320
317
|
"dateCreated": {
|
|
321
318
|
"type": "string",
|
|
322
|
-
"description": "The date the change set was created.
|
|
319
|
+
"description": "The date the change set was created."
|
|
323
320
|
},
|
|
324
321
|
"dateModified": {
|
|
325
322
|
"type": "string",
|
|
326
|
-
"description": "The date the change set was last modified.
|
|
323
|
+
"description": "The date the change set was last modified."
|
|
327
324
|
},
|
|
328
325
|
"nodeIdentity": {
|
|
329
326
|
"type": "string",
|
|
330
|
-
"description": "The identity of the node that created the change set.
|
|
327
|
+
"description": "The identity of the node that created the change set."
|
|
331
328
|
},
|
|
332
329
|
"changes": {
|
|
333
330
|
"type": "array",
|
|
334
331
|
"items": {
|
|
335
332
|
"$ref": "#/components/schemas/SyncChange"
|
|
336
333
|
},
|
|
337
|
-
"description": "The changes to apply after a snapshot.
|
|
334
|
+
"description": "The changes to apply after a snapshot."
|
|
338
335
|
}
|
|
339
336
|
},
|
|
340
337
|
"required": [
|
|
@@ -346,8 +343,7 @@
|
|
|
346
343
|
"dateModified",
|
|
347
344
|
"nodeIdentity",
|
|
348
345
|
"changes"
|
|
349
|
-
]
|
|
350
|
-
"description": "The object definition for a sync change set."
|
|
346
|
+
]
|
|
351
347
|
},
|
|
352
348
|
"SyncDecryptionKeyResponse": {
|
|
353
349
|
"type": "object",
|
|
@@ -363,17 +359,17 @@
|
|
|
363
359
|
"description": "The body of the response."
|
|
364
360
|
},
|
|
365
361
|
"SynchronisedEntityCore": {
|
|
362
|
+
"description": "The base definition for synchronised entries.",
|
|
366
363
|
"type": "object",
|
|
367
364
|
"properties": {
|
|
368
365
|
"dateModified": {
|
|
369
366
|
"type": "string",
|
|
370
|
-
"description": "The date the entry was modified.
|
|
367
|
+
"description": "The date the entry was modified."
|
|
371
368
|
}
|
|
372
369
|
},
|
|
373
370
|
"required": [
|
|
374
371
|
"dateModified"
|
|
375
|
-
]
|
|
376
|
-
"description": "The base definition for synchronised entries."
|
|
372
|
+
]
|
|
377
373
|
}
|
|
378
374
|
},
|
|
379
375
|
"securitySchemes": {
|
|
@@ -14,7 +14,7 @@ Class representing an entry for the sync snapshot.
|
|
|
14
14
|
|
|
15
15
|
## Properties
|
|
16
16
|
|
|
17
|
-
### id
|
|
17
|
+
### id {#id}
|
|
18
18
|
|
|
19
19
|
> **id**: `string`
|
|
20
20
|
|
|
@@ -22,7 +22,7 @@ The id for the snapshot.
|
|
|
22
22
|
|
|
23
23
|
***
|
|
24
24
|
|
|
25
|
-
### version
|
|
25
|
+
### version {#version}
|
|
26
26
|
|
|
27
27
|
> **version**: `string`
|
|
28
28
|
|
|
@@ -30,7 +30,7 @@ The version for the snapshot.
|
|
|
30
30
|
|
|
31
31
|
***
|
|
32
32
|
|
|
33
|
-
### storageKey
|
|
33
|
+
### storageKey {#storagekey}
|
|
34
34
|
|
|
35
35
|
> **storageKey**: `string`
|
|
36
36
|
|
|
@@ -38,7 +38,7 @@ The storage key for the snapshot i.e. which entity is being synchronized.
|
|
|
38
38
|
|
|
39
39
|
***
|
|
40
40
|
|
|
41
|
-
### dateCreated
|
|
41
|
+
### dateCreated {#datecreated}
|
|
42
42
|
|
|
43
43
|
> **dateCreated**: `string`
|
|
44
44
|
|
|
@@ -46,7 +46,7 @@ The date the snapshot was created.
|
|
|
46
46
|
|
|
47
47
|
***
|
|
48
48
|
|
|
49
|
-
### dateModified
|
|
49
|
+
### dateModified {#datemodified}
|
|
50
50
|
|
|
51
51
|
> **dateModified**: `string`
|
|
52
52
|
|
|
@@ -54,7 +54,7 @@ The date the snapshot was last modified.
|
|
|
54
54
|
|
|
55
55
|
***
|
|
56
56
|
|
|
57
|
-
### isLocal
|
|
57
|
+
### isLocal {#islocal}
|
|
58
58
|
|
|
59
59
|
> **isLocal**: `boolean`
|
|
60
60
|
|
|
@@ -62,7 +62,7 @@ The flag to determine if this is the snapshot is the local one containing change
|
|
|
62
62
|
|
|
63
63
|
***
|
|
64
64
|
|
|
65
|
-
### isConsolidated
|
|
65
|
+
### isConsolidated {#isconsolidated}
|
|
66
66
|
|
|
67
67
|
> **isConsolidated**: `boolean`
|
|
68
68
|
|
|
@@ -70,7 +70,7 @@ The flag to determine if this is a consolidated snapshot.
|
|
|
70
70
|
|
|
71
71
|
***
|
|
72
72
|
|
|
73
|
-
### epoch
|
|
73
|
+
### epoch {#epoch}
|
|
74
74
|
|
|
75
75
|
> **epoch**: `number`
|
|
76
76
|
|
|
@@ -78,16 +78,16 @@ The epoch for the changeset.
|
|
|
78
78
|
|
|
79
79
|
***
|
|
80
80
|
|
|
81
|
-
### changeSetStorageIds?
|
|
81
|
+
### changeSetStorageIds? {#changesetstorageids}
|
|
82
82
|
|
|
83
|
-
> `optional` **changeSetStorageIds
|
|
83
|
+
> `optional` **changeSetStorageIds?**: `string`[]
|
|
84
84
|
|
|
85
85
|
The ids of the storage for the change sets in the snapshot, if this is not a local snapshot.
|
|
86
86
|
|
|
87
87
|
***
|
|
88
88
|
|
|
89
|
-
### changes?
|
|
89
|
+
### changes? {#changes}
|
|
90
90
|
|
|
91
|
-
> `optional` **changes
|
|
91
|
+
> `optional` **changes?**: `ISyncChange`[]
|
|
92
92
|
|
|
93
93
|
The changes that were made in this snapshot, if this is a local snapshot.
|
|
@@ -28,7 +28,7 @@ The options for the service.
|
|
|
28
28
|
|
|
29
29
|
## Properties
|
|
30
30
|
|
|
31
|
-
### CLASS\_NAME
|
|
31
|
+
### CLASS\_NAME {#class_name}
|
|
32
32
|
|
|
33
33
|
> `readonly` `static` **CLASS\_NAME**: `string`
|
|
34
34
|
|
|
@@ -36,7 +36,7 @@ Runtime name for the class.
|
|
|
36
36
|
|
|
37
37
|
## Methods
|
|
38
38
|
|
|
39
|
-
### className()
|
|
39
|
+
### className() {#classname}
|
|
40
40
|
|
|
41
41
|
> **className**(): `string`
|
|
42
42
|
|
|
@@ -54,7 +54,7 @@ The class name of the component.
|
|
|
54
54
|
|
|
55
55
|
***
|
|
56
56
|
|
|
57
|
-
### start()
|
|
57
|
+
### start() {#start}
|
|
58
58
|
|
|
59
59
|
> **start**(`nodeLoggingComponentType?`): `Promise`\<`void`\>
|
|
60
60
|
|
|
@@ -72,7 +72,7 @@ The node logging component type.
|
|
|
72
72
|
|
|
73
73
|
`Promise`\<`void`\>
|
|
74
74
|
|
|
75
|
-
|
|
75
|
+
A promise that resolves when the service is started and all event bus subscriptions are active.
|
|
76
76
|
|
|
77
77
|
#### Implementation of
|
|
78
78
|
|
|
@@ -80,7 +80,7 @@ Nothing.
|
|
|
80
80
|
|
|
81
81
|
***
|
|
82
82
|
|
|
83
|
-
### stop()
|
|
83
|
+
### stop() {#stop}
|
|
84
84
|
|
|
85
85
|
> **stop**(`nodeLoggingComponentType?`): `Promise`\<`void`\>
|
|
86
86
|
|
|
@@ -98,7 +98,7 @@ The node logging component type.
|
|
|
98
98
|
|
|
99
99
|
`Promise`\<`void`\>
|
|
100
100
|
|
|
101
|
-
|
|
101
|
+
A promise that resolves when all scheduled tasks are removed and storage keys are deactivated.
|
|
102
102
|
|
|
103
103
|
#### Implementation of
|
|
104
104
|
|
|
@@ -106,7 +106,7 @@ Nothing.
|
|
|
106
106
|
|
|
107
107
|
***
|
|
108
108
|
|
|
109
|
-
### getDecryptionKey()
|
|
109
|
+
### getDecryptionKey() {#getdecryptionkey}
|
|
110
110
|
|
|
111
111
|
> **getDecryptionKey**(`trustPayload`): `Promise`\<`string`\>
|
|
112
112
|
|
|
@@ -133,7 +133,7 @@ The decryption key.
|
|
|
133
133
|
|
|
134
134
|
***
|
|
135
135
|
|
|
136
|
-
### syncChangeSet()
|
|
136
|
+
### syncChangeSet() {#syncchangeset}
|
|
137
137
|
|
|
138
138
|
> **syncChangeSet**(`syncChangeSet`, `trustPayload`): `Promise`\<`void`\>
|
|
139
139
|
|
|
@@ -157,7 +157,7 @@ Trust payload to verify the requesters identity.
|
|
|
157
157
|
|
|
158
158
|
`Promise`\<`void`\>
|
|
159
159
|
|
|
160
|
-
|
|
160
|
+
A promise that resolves when the change set has been applied and the sync state updated.
|
|
161
161
|
|
|
162
162
|
#### Implementation of
|
|
163
163
|
|
|
@@ -4,7 +4,7 @@ The object definition for the sync pointer store.
|
|
|
4
4
|
|
|
5
5
|
## Properties
|
|
6
6
|
|
|
7
|
-
### version
|
|
7
|
+
### version {#version}
|
|
8
8
|
|
|
9
9
|
> **version**: `string`
|
|
10
10
|
|
|
@@ -12,7 +12,7 @@ The version of the sync pointer store.
|
|
|
12
12
|
|
|
13
13
|
***
|
|
14
14
|
|
|
15
|
-
### syncPointers
|
|
15
|
+
### syncPointers {#syncpointers}
|
|
16
16
|
|
|
17
17
|
> **syncPointers**: `object`
|
|
18
18
|
|
|
@@ -4,7 +4,7 @@ The object definition for a sync snapshot.
|
|
|
4
4
|
|
|
5
5
|
## Properties
|
|
6
6
|
|
|
7
|
-
### version
|
|
7
|
+
### version {#version}
|
|
8
8
|
|
|
9
9
|
> **version**: `string`
|
|
10
10
|
|
|
@@ -12,7 +12,7 @@ The version of the sync state.
|
|
|
12
12
|
|
|
13
13
|
***
|
|
14
14
|
|
|
15
|
-
### id
|
|
15
|
+
### id {#id}
|
|
16
16
|
|
|
17
17
|
> **id**: `string`
|
|
18
18
|
|
|
@@ -20,7 +20,7 @@ The id of the snapshot.
|
|
|
20
20
|
|
|
21
21
|
***
|
|
22
22
|
|
|
23
|
-
### dateCreated
|
|
23
|
+
### dateCreated {#datecreated}
|
|
24
24
|
|
|
25
25
|
> **dateCreated**: `string`
|
|
26
26
|
|
|
@@ -28,7 +28,7 @@ The date the snapshot was created.
|
|
|
28
28
|
|
|
29
29
|
***
|
|
30
30
|
|
|
31
|
-
### dateModified
|
|
31
|
+
### dateModified {#datemodified}
|
|
32
32
|
|
|
33
33
|
> **dateModified**: `string`
|
|
34
34
|
|
|
@@ -36,7 +36,7 @@ The date the snapshot was last modified.
|
|
|
36
36
|
|
|
37
37
|
***
|
|
38
38
|
|
|
39
|
-
### isConsolidated
|
|
39
|
+
### isConsolidated {#isconsolidated}
|
|
40
40
|
|
|
41
41
|
> **isConsolidated**: `boolean`
|
|
42
42
|
|
|
@@ -44,7 +44,7 @@ Is this a consolidated snapshot?
|
|
|
44
44
|
|
|
45
45
|
***
|
|
46
46
|
|
|
47
|
-
### epoch
|
|
47
|
+
### epoch {#epoch}
|
|
48
48
|
|
|
49
49
|
> **epoch**: `number`
|
|
50
50
|
|
|
@@ -52,7 +52,7 @@ The epoch of the snapshot.
|
|
|
52
52
|
|
|
53
53
|
***
|
|
54
54
|
|
|
55
|
-
### changeSetStorageIds
|
|
55
|
+
### changeSetStorageIds {#changesetstorageids}
|
|
56
56
|
|
|
57
57
|
> **changeSetStorageIds**: `string`[]
|
|
58
58
|
|
|
@@ -4,7 +4,7 @@ The object definition for a sync state.
|
|
|
4
4
|
|
|
5
5
|
## Properties
|
|
6
6
|
|
|
7
|
-
### version
|
|
7
|
+
### version {#version}
|
|
8
8
|
|
|
9
9
|
> **version**: `string`
|
|
10
10
|
|
|
@@ -12,7 +12,7 @@ The version of the sync state.
|
|
|
12
12
|
|
|
13
13
|
***
|
|
14
14
|
|
|
15
|
-
### storageKey
|
|
15
|
+
### storageKey {#storagekey}
|
|
16
16
|
|
|
17
17
|
> **storageKey**: `string`
|
|
18
18
|
|
|
@@ -20,7 +20,7 @@ The storage type contained in the sync state.
|
|
|
20
20
|
|
|
21
21
|
***
|
|
22
22
|
|
|
23
|
-
### snapshots
|
|
23
|
+
### snapshots {#snapshots}
|
|
24
24
|
|
|
25
25
|
> **snapshots**: [`ISyncSnapshot`](ISyncSnapshot.md)[]
|
|
26
26
|
|
|
@@ -4,9 +4,9 @@ Configuration for the Synchronised Storage Service.
|
|
|
4
4
|
|
|
5
5
|
## Properties
|
|
6
6
|
|
|
7
|
-
### entityUpdateIntervalMinutes?
|
|
7
|
+
### entityUpdateIntervalMinutes? {#entityupdateintervalminutes}
|
|
8
8
|
|
|
9
|
-
> `optional` **entityUpdateIntervalMinutes
|
|
9
|
+
> `optional` **entityUpdateIntervalMinutes?**: `number`
|
|
10
10
|
|
|
11
11
|
How often to check for entity updates in minutes.
|
|
12
12
|
|
|
@@ -18,9 +18,9 @@ How often to check for entity updates in minutes.
|
|
|
18
18
|
|
|
19
19
|
***
|
|
20
20
|
|
|
21
|
-
### consolidationIntervalMinutes?
|
|
21
|
+
### consolidationIntervalMinutes? {#consolidationintervalminutes}
|
|
22
22
|
|
|
23
|
-
> `optional` **consolidationIntervalMinutes
|
|
23
|
+
> `optional` **consolidationIntervalMinutes?**: `number`
|
|
24
24
|
|
|
25
25
|
Interval to perform consolidation of changesets, only used if this is a trusted node.
|
|
26
26
|
|
|
@@ -32,9 +32,9 @@ Interval to perform consolidation of changesets, only used if this is a trusted
|
|
|
32
32
|
|
|
33
33
|
***
|
|
34
34
|
|
|
35
|
-
### consolidationBatchSize?
|
|
35
|
+
### consolidationBatchSize? {#consolidationbatchsize}
|
|
36
36
|
|
|
37
|
-
> `optional` **consolidationBatchSize
|
|
37
|
+
> `optional` **consolidationBatchSize?**: `number`
|
|
38
38
|
|
|
39
39
|
The number of entities to process in a single consolidation batch, only used if this is a trusted node.
|
|
40
40
|
|
|
@@ -46,9 +46,9 @@ The number of entities to process in a single consolidation batch, only used if
|
|
|
46
46
|
|
|
47
47
|
***
|
|
48
48
|
|
|
49
|
-
### maxConsolidations?
|
|
49
|
+
### maxConsolidations? {#maxconsolidations}
|
|
50
50
|
|
|
51
|
-
> `optional` **maxConsolidations
|
|
51
|
+
> `optional` **maxConsolidations?**: `number`
|
|
52
52
|
|
|
53
53
|
The maximum number of consolidations to keep in storage, only used if this is a trusted node.
|
|
54
54
|
|
|
@@ -60,9 +60,9 @@ The maximum number of consolidations to keep in storage, only used if this is a
|
|
|
60
60
|
|
|
61
61
|
***
|
|
62
62
|
|
|
63
|
-
### blobStorageEncryptionKeyId?
|
|
63
|
+
### blobStorageEncryptionKeyId? {#blobstorageencryptionkeyid}
|
|
64
64
|
|
|
65
|
-
> `optional` **blobStorageEncryptionKeyId
|
|
65
|
+
> `optional` **blobStorageEncryptionKeyId?**: `string`
|
|
66
66
|
|
|
67
67
|
The encryption key id from the vault to use for blob storage, only required for trusted nodes, untrusted nodes will request the key.
|
|
68
68
|
|
|
@@ -74,7 +74,7 @@ synchronised-storage-blob-encryption-key
|
|
|
74
74
|
|
|
75
75
|
***
|
|
76
76
|
|
|
77
|
-
### verifiableStorageKeyId
|
|
77
|
+
### verifiableStorageKeyId {#verifiablestoragekeyid}
|
|
78
78
|
|
|
79
79
|
> **verifiableStorageKeyId**: `string`
|
|
80
80
|
|
|
@@ -89,8 +89,8 @@ local
|
|
|
89
89
|
|
|
90
90
|
***
|
|
91
91
|
|
|
92
|
-
### overrideTrustGeneratorType?
|
|
92
|
+
### overrideTrustGeneratorType? {#overridetrustgeneratortype}
|
|
93
93
|
|
|
94
|
-
> `optional` **overrideTrustGeneratorType
|
|
94
|
+
> `optional` **overrideTrustGeneratorType?**: `string`
|
|
95
95
|
|
|
96
96
|
Override the default trust generator.
|
|
@@ -4,33 +4,33 @@ Options for the Synchronised Storage Service constructor.
|
|
|
4
4
|
|
|
5
5
|
## Properties
|
|
6
6
|
|
|
7
|
-
### loggingComponentType?
|
|
7
|
+
### loggingComponentType? {#loggingcomponenttype}
|
|
8
8
|
|
|
9
|
-
> `optional` **loggingComponentType
|
|
9
|
+
> `optional` **loggingComponentType?**: `string`
|
|
10
10
|
|
|
11
11
|
The logging component.
|
|
12
12
|
|
|
13
13
|
***
|
|
14
14
|
|
|
15
|
-
### eventBusComponentType?
|
|
15
|
+
### eventBusComponentType? {#eventbuscomponenttype}
|
|
16
16
|
|
|
17
|
-
> `optional` **eventBusComponentType
|
|
17
|
+
> `optional` **eventBusComponentType?**: `string`
|
|
18
18
|
|
|
19
19
|
The event bus component type.
|
|
20
20
|
|
|
21
21
|
***
|
|
22
22
|
|
|
23
|
-
### vaultConnectorType?
|
|
23
|
+
### vaultConnectorType? {#vaultconnectortype}
|
|
24
24
|
|
|
25
|
-
> `optional` **vaultConnectorType
|
|
25
|
+
> `optional` **vaultConnectorType?**: `string`
|
|
26
26
|
|
|
27
27
|
The vault connector type.
|
|
28
28
|
|
|
29
29
|
***
|
|
30
30
|
|
|
31
|
-
### syncSnapshotStorageConnectorType?
|
|
31
|
+
### syncSnapshotStorageConnectorType? {#syncsnapshotstorageconnectortype}
|
|
32
32
|
|
|
33
|
-
> `optional` **syncSnapshotStorageConnectorType
|
|
33
|
+
> `optional` **syncSnapshotStorageConnectorType?**: `string`
|
|
34
34
|
|
|
35
35
|
The entity storage connector type to use for sync snapshots.
|
|
36
36
|
|
|
@@ -42,9 +42,9 @@ sync-snapshot-entry
|
|
|
42
42
|
|
|
43
43
|
***
|
|
44
44
|
|
|
45
|
-
### blobStorageConnectorType?
|
|
45
|
+
### blobStorageConnectorType? {#blobstorageconnectortype}
|
|
46
46
|
|
|
47
|
-
> `optional` **blobStorageConnectorType
|
|
47
|
+
> `optional` **blobStorageConnectorType?**: `string`
|
|
48
48
|
|
|
49
49
|
The blob storage connector used for remote sync state.
|
|
50
50
|
|
|
@@ -56,9 +56,9 @@ blob-storage
|
|
|
56
56
|
|
|
57
57
|
***
|
|
58
58
|
|
|
59
|
-
### verifiableStorageConnectorType?
|
|
59
|
+
### verifiableStorageConnectorType? {#verifiablestorageconnectortype}
|
|
60
60
|
|
|
61
|
-
> `optional` **verifiableStorageConnectorType
|
|
61
|
+
> `optional` **verifiableStorageConnectorType?**: `string`
|
|
62
62
|
|
|
63
63
|
The verifiable storage connector type to use for decentralised state.
|
|
64
64
|
|
|
@@ -70,9 +70,9 @@ verifiable-storage
|
|
|
70
70
|
|
|
71
71
|
***
|
|
72
72
|
|
|
73
|
-
### taskSchedulerComponentType?
|
|
73
|
+
### taskSchedulerComponentType? {#taskschedulercomponenttype}
|
|
74
74
|
|
|
75
|
-
> `optional` **taskSchedulerComponentType
|
|
75
|
+
> `optional` **taskSchedulerComponentType?**: `string`
|
|
76
76
|
|
|
77
77
|
The task scheduler component.
|
|
78
78
|
|
|
@@ -84,9 +84,9 @@ task-scheduler
|
|
|
84
84
|
|
|
85
85
|
***
|
|
86
86
|
|
|
87
|
-
### trustComponentType?
|
|
87
|
+
### trustComponentType? {#trustcomponenttype}
|
|
88
88
|
|
|
89
|
-
> `optional` **trustComponentType
|
|
89
|
+
> `optional` **trustComponentType?**: `string`
|
|
90
90
|
|
|
91
91
|
The type of the trust component.
|
|
92
92
|
|
|
@@ -98,16 +98,16 @@ trust
|
|
|
98
98
|
|
|
99
99
|
***
|
|
100
100
|
|
|
101
|
-
### trustedSynchronisedStorageComponentType?
|
|
101
|
+
### trustedSynchronisedStorageComponentType? {#trustedsynchronisedstoragecomponenttype}
|
|
102
102
|
|
|
103
|
-
> `optional` **trustedSynchronisedStorageComponentType
|
|
103
|
+
> `optional` **trustedSynchronisedStorageComponentType?**: `string`
|
|
104
104
|
|
|
105
105
|
The synchronised entity storage component type to use if this node is not trusted.
|
|
106
106
|
If this is set, this node uses it as the trusted node to store changesets.
|
|
107
107
|
|
|
108
108
|
***
|
|
109
109
|
|
|
110
|
-
### config
|
|
110
|
+
### config {#config}
|
|
111
111
|
|
|
112
112
|
> **config**: [`ISynchronisedStorageServiceConfig`](ISynchronisedStorageServiceConfig.md)
|
|
113
113
|
|