harperdb 4.5.28 → 4.5.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/bin/harperdb.js +39 -39
- package/bin/lite.js +36 -36
- package/launchServiceScripts/launchNatsIngestService.js +34 -34
- package/launchServiceScripts/launchNatsReplyService.js +34 -34
- package/launchServiceScripts/launchUpdateNodes4-0-0.js +34 -34
- package/npm-shrinkwrap.json +322 -332
- package/package.json +1 -1
- package/resources/Table.d.ts +28 -28
- package/resources/blob.d.ts +6 -3
- package/resources/databases.d.ts +28 -28
- package/server/jobs/jobProcess.js +34 -34
- package/server/threads/threadServer.js +36 -36
- package/studio/build-local/asset-manifest.json +2 -2
- package/studio/build-local/index.html +1 -1
- package/studio/build-local/static/js/{main.8b9a184d.js → main.20814c04.js} +2 -2
- package/utility/scripts/restartHdb.js +34 -34
- /package/studio/build-local/static/js/{main.8b9a184d.js.LICENSE.txt → main.20814c04.js.LICENSE.txt} +0 -0
package/package.json
CHANGED
package/resources/Table.d.ts
CHANGED
|
@@ -49,12 +49,12 @@ type ResidencyDefinition = number | string[] | void;
|
|
|
49
49
|
*/
|
|
50
50
|
export declare function makeTable(options: any): {
|
|
51
51
|
new (identifier: Id, source: any): {
|
|
52
|
-
#record: any;
|
|
53
|
-
#changes: any;
|
|
54
|
-
#version: number;
|
|
55
|
-
#entry: Entry;
|
|
56
|
-
#saveMode: boolean;
|
|
57
|
-
#loadedFromSource: boolean;
|
|
52
|
+
"__#private@#record": any;
|
|
53
|
+
"__#private@#changes": any;
|
|
54
|
+
"__#private@#version": number;
|
|
55
|
+
"__#private@#entry": Entry;
|
|
56
|
+
"__#private@#saveMode": boolean;
|
|
57
|
+
"__#private@#loadedFromSource": boolean;
|
|
58
58
|
/**
|
|
59
59
|
* This is a request to explicitly ensure that the record is loaded from source, rather than only using the local record.
|
|
60
60
|
* This will load from source if the current record is expired, missing, or invalidated.
|
|
@@ -186,9 +186,9 @@ export declare function makeTable(options: any): {
|
|
|
186
186
|
validate(record: any, patch?: any): void;
|
|
187
187
|
getUpdatedTime(): number;
|
|
188
188
|
wasLoadedFromSource(): boolean | void;
|
|
189
|
-
readonly #id: Id;
|
|
190
|
-
readonly #context: Context;
|
|
191
|
-
#isCollection: boolean;
|
|
189
|
+
readonly "__#private@#id": Id;
|
|
190
|
+
readonly "__#private@#context": Context;
|
|
191
|
+
"__#private@#isCollection": boolean;
|
|
192
192
|
post(new_record: any): Promise<any>;
|
|
193
193
|
get isCollection(): boolean;
|
|
194
194
|
connect(incomingMessages: import("./IterableEventQueue").IterableEventQueue, query?: {}): AsyncIterable<any>;
|
|
@@ -240,12 +240,12 @@ export declare function makeTable(options: any): {
|
|
|
240
240
|
* @returns
|
|
241
241
|
*/
|
|
242
242
|
getResource(id: Id, request: Context, resource_options?: any): Promise<{
|
|
243
|
-
#record: any;
|
|
244
|
-
#changes: any;
|
|
245
|
-
#version: number;
|
|
246
|
-
#entry: Entry;
|
|
247
|
-
#saveMode: boolean;
|
|
248
|
-
#loadedFromSource: boolean;
|
|
243
|
+
"__#private@#record": any;
|
|
244
|
+
"__#private@#changes": any;
|
|
245
|
+
"__#private@#version": number;
|
|
246
|
+
"__#private@#entry": Entry;
|
|
247
|
+
"__#private@#saveMode": boolean;
|
|
248
|
+
"__#private@#loadedFromSource": boolean;
|
|
249
249
|
/**
|
|
250
250
|
* This is a request to explicitly ensure that the record is loaded from source, rather than only using the local record.
|
|
251
251
|
* This will load from source if the current record is expired, missing, or invalidated.
|
|
@@ -377,21 +377,21 @@ export declare function makeTable(options: any): {
|
|
|
377
377
|
validate(record: any, patch?: any): void;
|
|
378
378
|
getUpdatedTime(): number;
|
|
379
379
|
wasLoadedFromSource(): boolean | void;
|
|
380
|
-
readonly #id: Id;
|
|
381
|
-
readonly #context: Context;
|
|
382
|
-
#isCollection: boolean;
|
|
380
|
+
readonly "__#private@#id": Id;
|
|
381
|
+
readonly "__#private@#context": Context;
|
|
382
|
+
"__#private@#isCollection": boolean;
|
|
383
383
|
post(new_record: any): Promise<any>;
|
|
384
384
|
get isCollection(): boolean;
|
|
385
385
|
connect(incomingMessages: import("./IterableEventQueue").IterableEventQueue, query?: {}): AsyncIterable<any>;
|
|
386
386
|
getId(): Id;
|
|
387
387
|
getContext(): Context;
|
|
388
388
|
}> | {
|
|
389
|
-
#record: any;
|
|
390
|
-
#changes: any;
|
|
391
|
-
#version: number;
|
|
392
|
-
#entry: Entry;
|
|
393
|
-
#saveMode: boolean;
|
|
394
|
-
#loadedFromSource: boolean;
|
|
389
|
+
"__#private@#record": any;
|
|
390
|
+
"__#private@#changes": any;
|
|
391
|
+
"__#private@#version": number;
|
|
392
|
+
"__#private@#entry": Entry;
|
|
393
|
+
"__#private@#saveMode": boolean;
|
|
394
|
+
"__#private@#loadedFromSource": boolean;
|
|
395
395
|
/**
|
|
396
396
|
* This is a request to explicitly ensure that the record is loaded from source, rather than only using the local record.
|
|
397
397
|
* This will load from source if the current record is expired, missing, or invalidated.
|
|
@@ -523,9 +523,9 @@ export declare function makeTable(options: any): {
|
|
|
523
523
|
validate(record: any, patch?: any): void;
|
|
524
524
|
getUpdatedTime(): number;
|
|
525
525
|
wasLoadedFromSource(): boolean | void;
|
|
526
|
-
readonly #id: Id;
|
|
527
|
-
readonly #context: Context;
|
|
528
|
-
#isCollection: boolean;
|
|
526
|
+
readonly "__#private@#id": Id;
|
|
527
|
+
readonly "__#private@#context": Context;
|
|
528
|
+
"__#private@#isCollection": boolean;
|
|
529
529
|
post(new_record: any): Promise<any>;
|
|
530
530
|
get isCollection(): boolean;
|
|
531
531
|
connect(incomingMessages: import("./IterableEventQueue").IterableEventQueue, query?: {}): AsyncIterable<any>;
|
|
@@ -569,7 +569,7 @@ export declare function makeTable(options: any): {
|
|
|
569
569
|
/**
|
|
570
570
|
* Evicting a record will remove it from a caching table. This is not considered a canonical data change, and it is assumed that retrieving this record from the source will still yield the same record, this is only removing the local copy of the record.
|
|
571
571
|
*/
|
|
572
|
-
evict(id: any, existing_record: any, existing_version: any):
|
|
572
|
+
evict(id: any, existing_record: any, existing_version: any): any;
|
|
573
573
|
operation(operation: any, context: any): any;
|
|
574
574
|
/**
|
|
575
575
|
* This is responsible for ordering and select()ing the attributes/properties from returned entries
|
package/resources/blob.d.ts
CHANGED
|
@@ -11,6 +11,7 @@
|
|
|
11
11
|
* - Note that for compressed data, the size is the uncompressed size, and the compressed size in the file
|
|
12
12
|
*/
|
|
13
13
|
import type { LMDBStore } from 'lmdb';
|
|
14
|
+
import * as buffer from 'node:buffer';
|
|
14
15
|
type StorageInfo = {
|
|
15
16
|
storageIndex: number;
|
|
16
17
|
fileId: string;
|
|
@@ -26,6 +27,7 @@ type StorageInfo = {
|
|
|
26
27
|
end?: number;
|
|
27
28
|
saving?: Promise<void>;
|
|
28
29
|
asString?: string;
|
|
30
|
+
deleteOnFailure?: boolean;
|
|
29
31
|
};
|
|
30
32
|
export declare const Blob: {
|
|
31
33
|
new (blobParts?: BlobPart[], options?: BlobPropertyBag): Blob;
|
|
@@ -38,7 +40,7 @@ export declare const Blob: {
|
|
|
38
40
|
arrayBuffer(): Promise<ArrayBufferLike>;
|
|
39
41
|
get size(): number;
|
|
40
42
|
slice(): /*elided*/ any;
|
|
41
|
-
bytes(): Promise<Buffer>;
|
|
43
|
+
bytes(): Promise<buffer.Buffer>;
|
|
42
44
|
get type(): string;
|
|
43
45
|
};
|
|
44
46
|
};
|
|
@@ -52,7 +54,7 @@ declare namespace InstanceOfBlobWithNoConstructor {
|
|
|
52
54
|
arrayBuffer(): Promise<ArrayBufferLike>;
|
|
53
55
|
get size(): number;
|
|
54
56
|
slice(): /*elided*/ any;
|
|
55
|
-
bytes(): Promise<Buffer>;
|
|
57
|
+
bytes(): Promise<buffer.Buffer>;
|
|
56
58
|
get type(): string;
|
|
57
59
|
};
|
|
58
60
|
}
|
|
@@ -81,6 +83,7 @@ declare class FileBackedBlob extends InstanceOfBlobWithNoConstructor {
|
|
|
81
83
|
stream(): ReadableStream;
|
|
82
84
|
slice(start: number, end: number, type?: string): Blob;
|
|
83
85
|
save(): Promise<void>;
|
|
86
|
+
get written(): Promise<void>;
|
|
84
87
|
}
|
|
85
88
|
/**
|
|
86
89
|
* Delete the file for the blob
|
|
@@ -95,7 +98,7 @@ export type BlobCreationOptions = {
|
|
|
95
98
|
size?: number;
|
|
96
99
|
saveBeforeCommit?: boolean;
|
|
97
100
|
};
|
|
98
|
-
export declare function saveBlob(blob: FileBackedBlob): StorageInfo;
|
|
101
|
+
export declare function saveBlob(blob: FileBackedBlob, deleteOnFailure?: boolean): StorageInfo;
|
|
99
102
|
export declare function getFileId(blob: Blob): string;
|
|
100
103
|
export declare function isSaving(blob: Blob): string;
|
|
101
104
|
export declare function getFilePathForBlob(blob: FileBackedBlob): string;
|
package/resources/databases.d.ts
CHANGED
|
@@ -78,10 +78,10 @@ export declare function dropDatabase(database_name: any): Promise<void>;
|
|
|
78
78
|
*/
|
|
79
79
|
export declare function table(table_definition: TableDefinition): {
|
|
80
80
|
new (identifier: import("./ResourceInterface").Id, source: any): {
|
|
81
|
-
#record: any;
|
|
82
|
-
#changes: any;
|
|
83
|
-
#version: number;
|
|
84
|
-
#entry: {
|
|
81
|
+
"__#private@#record": any;
|
|
82
|
+
"__#private@#changes": any;
|
|
83
|
+
"__#private@#version": number;
|
|
84
|
+
"__#private@#entry": {
|
|
85
85
|
key: any;
|
|
86
86
|
value: any;
|
|
87
87
|
version: number;
|
|
@@ -89,8 +89,8 @@ export declare function table(table_definition: TableDefinition): {
|
|
|
89
89
|
expiresAt: number;
|
|
90
90
|
deref?: () => any;
|
|
91
91
|
};
|
|
92
|
-
#saveMode: boolean;
|
|
93
|
-
#loadedFromSource: boolean;
|
|
92
|
+
"__#private@#saveMode": boolean;
|
|
93
|
+
"__#private@#loadedFromSource": boolean;
|
|
94
94
|
ensureLoaded(): any;
|
|
95
95
|
get(query?: import("./ResourceInterface").Query | string): Promise<object | void> | object | void;
|
|
96
96
|
allowRead(user: any, query: any): any;
|
|
@@ -176,9 +176,9 @@ export declare function table(table_definition: TableDefinition): {
|
|
|
176
176
|
validate(record: any, patch?: any): void;
|
|
177
177
|
getUpdatedTime(): number;
|
|
178
178
|
wasLoadedFromSource(): boolean | void;
|
|
179
|
-
readonly #id: import("./ResourceInterface").Id;
|
|
180
|
-
readonly #context: import("./ResourceInterface").Context;
|
|
181
|
-
#isCollection: boolean;
|
|
179
|
+
readonly "__#private@#id": import("./ResourceInterface").Id;
|
|
180
|
+
readonly "__#private@#context": import("./ResourceInterface").Context;
|
|
181
|
+
"__#private@#isCollection": boolean;
|
|
182
182
|
post(new_record: any): Promise<any>;
|
|
183
183
|
get isCollection(): boolean;
|
|
184
184
|
connect(incomingMessages: import("./IterableEventQueue").IterableEventQueue, query?: {}): AsyncIterable<any>;
|
|
@@ -226,10 +226,10 @@ export declare function table(table_definition: TableDefinition): {
|
|
|
226
226
|
get isCaching(): any;
|
|
227
227
|
get shouldRevalidateEvents(): boolean;
|
|
228
228
|
getResource(id: import("./ResourceInterface").Id, request: import("./ResourceInterface").Context, resource_options?: any): Promise<{
|
|
229
|
-
#record: any;
|
|
230
|
-
#changes: any;
|
|
231
|
-
#version: number;
|
|
232
|
-
#entry: {
|
|
229
|
+
"__#private@#record": any;
|
|
230
|
+
"__#private@#changes": any;
|
|
231
|
+
"__#private@#version": number;
|
|
232
|
+
"__#private@#entry": {
|
|
233
233
|
key: any;
|
|
234
234
|
value: any;
|
|
235
235
|
version: number;
|
|
@@ -237,8 +237,8 @@ export declare function table(table_definition: TableDefinition): {
|
|
|
237
237
|
expiresAt: number;
|
|
238
238
|
deref?: () => any;
|
|
239
239
|
};
|
|
240
|
-
#saveMode: boolean;
|
|
241
|
-
#loadedFromSource: boolean;
|
|
240
|
+
"__#private@#saveMode": boolean;
|
|
241
|
+
"__#private@#loadedFromSource": boolean;
|
|
242
242
|
ensureLoaded(): any;
|
|
243
243
|
get(query?: import("./ResourceInterface").Query | string): Promise<object | void> | object | void;
|
|
244
244
|
allowRead(user: any, query: any): any;
|
|
@@ -324,19 +324,19 @@ export declare function table(table_definition: TableDefinition): {
|
|
|
324
324
|
validate(record: any, patch?: any): void;
|
|
325
325
|
getUpdatedTime(): number;
|
|
326
326
|
wasLoadedFromSource(): boolean | void;
|
|
327
|
-
readonly #id: import("./ResourceInterface").Id;
|
|
328
|
-
readonly #context: import("./ResourceInterface").Context;
|
|
329
|
-
#isCollection: boolean;
|
|
327
|
+
readonly "__#private@#id": import("./ResourceInterface").Id;
|
|
328
|
+
readonly "__#private@#context": import("./ResourceInterface").Context;
|
|
329
|
+
"__#private@#isCollection": boolean;
|
|
330
330
|
post(new_record: any): Promise<any>;
|
|
331
331
|
get isCollection(): boolean;
|
|
332
332
|
connect(incomingMessages: import("./IterableEventQueue").IterableEventQueue, query?: {}): AsyncIterable<any>;
|
|
333
333
|
getId(): import("./ResourceInterface").Id;
|
|
334
334
|
getContext(): import("./ResourceInterface").Context;
|
|
335
335
|
}> | {
|
|
336
|
-
#record: any;
|
|
337
|
-
#changes: any;
|
|
338
|
-
#version: number;
|
|
339
|
-
#entry: {
|
|
336
|
+
"__#private@#record": any;
|
|
337
|
+
"__#private@#changes": any;
|
|
338
|
+
"__#private@#version": number;
|
|
339
|
+
"__#private@#entry": {
|
|
340
340
|
key: any;
|
|
341
341
|
value: any;
|
|
342
342
|
version: number;
|
|
@@ -344,8 +344,8 @@ export declare function table(table_definition: TableDefinition): {
|
|
|
344
344
|
expiresAt: number;
|
|
345
345
|
deref?: () => any;
|
|
346
346
|
};
|
|
347
|
-
#saveMode: boolean;
|
|
348
|
-
#loadedFromSource: boolean;
|
|
347
|
+
"__#private@#saveMode": boolean;
|
|
348
|
+
"__#private@#loadedFromSource": boolean;
|
|
349
349
|
ensureLoaded(): any;
|
|
350
350
|
get(query?: import("./ResourceInterface").Query | string): Promise<object | void> | object | void;
|
|
351
351
|
allowRead(user: any, query: any): any;
|
|
@@ -431,9 +431,9 @@ export declare function table(table_definition: TableDefinition): {
|
|
|
431
431
|
validate(record: any, patch?: any): void;
|
|
432
432
|
getUpdatedTime(): number;
|
|
433
433
|
wasLoadedFromSource(): boolean | void;
|
|
434
|
-
readonly #id: import("./ResourceInterface").Id;
|
|
435
|
-
readonly #context: import("./ResourceInterface").Context;
|
|
436
|
-
#isCollection: boolean;
|
|
434
|
+
readonly "__#private@#id": import("./ResourceInterface").Id;
|
|
435
|
+
readonly "__#private@#context": import("./ResourceInterface").Context;
|
|
436
|
+
"__#private@#isCollection": boolean;
|
|
437
437
|
post(new_record: any): Promise<any>;
|
|
438
438
|
get isCollection(): boolean;
|
|
439
439
|
connect(incomingMessages: import("./IterableEventQueue").IterableEventQueue, query?: {}): AsyncIterable<any>;
|
|
@@ -455,7 +455,7 @@ export declare function table(table_definition: TableDefinition): {
|
|
|
455
455
|
coerceId(id: string): number | string;
|
|
456
456
|
dropTable(): Promise<void>;
|
|
457
457
|
_recordRelocate(existing_entry: any, entry: any): boolean;
|
|
458
|
-
evict(id: any, existing_record: any, existing_version: any):
|
|
458
|
+
evict(id: any, existing_record: any, existing_version: any): any;
|
|
459
459
|
operation(operation: any, context: any): any;
|
|
460
460
|
transformToOrderedSelect(entries: any[], select: (string | import("./ResourceInterface").SubSelect)[], sort: import("./ResourceInterface").Sort, context: import("./ResourceInterface").Context, read_txn: any, transformToRecord: Function): any;
|
|
461
461
|
transformEntryForSelect(select: any, context: any, read_txn: any, filtered: any, ensure_loaded?: any, can_skip?: any): (entry: any) => any;
|