sliftutils 1.7.10 → 1.7.12
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/.claude/settings.local.json +2 -1
- package/examplestorage/exampleserver.ts +0 -2
- package/index.d.ts +301 -54
- package/misc/dist/environment.ts.cache +3 -3
- package/misc/dist/getSecret.ts.cache +139 -0
- package/misc/dist/strings.ts.cache +13 -0
- package/misc/dist/zip.ts.cache +9 -0
- package/misc/getSecret.ts +38 -16
- package/misc/https/cloudflareHelpers.d.ts +19 -0
- package/misc/https/cloudflareHelpers.ts +69 -0
- package/misc/https/dist/certs.ts.cache +115 -179
- package/misc/https/dist/cloudflareHelpers.ts.cache +68 -0
- package/misc/https/dist/dns.ts.cache +112 -100
- package/misc/https/dist/hostServer.ts.cache +130 -0
- package/misc/https/dist/httpsCerts.ts.cache +24 -5
- package/misc/https/dist/persistentLocalStorage.ts.cache +3 -2
- package/misc/https/dns.d.ts +41 -12
- package/misc/https/dns.ts +104 -101
- package/misc/https/hostServer.d.ts +0 -6
- package/misc/https/hostServer.ts +9 -5
- package/package.json +2 -2
- package/render-utils/dist/observer.tsx.cache +3 -2
- package/spec.txt +0 -90
- package/storage/ArchivesDisk.d.ts +2 -0
- package/storage/ArchivesDisk.ts +7 -3
- package/storage/BulkDatabase2/dist/BulkDatabaseBase.ts.cache +1242 -0
- package/storage/BulkDatabase2/dist/BulkDatabaseFormat.ts.cache +513 -0
- package/storage/BulkDatabase2/dist/BulkDatabaseMerge.ts.cache +352 -0
- package/storage/BulkDatabase2/dist/BulkDatabaseReader.ts.cache +306 -0
- package/storage/BulkDatabase2/dist/LoadedIndex.ts.cache +435 -0
- package/storage/BulkDatabase2/dist/WriteOverlay.ts.cache +58 -0
- package/storage/BulkDatabase2/dist/blockCache.ts.cache +179 -0
- package/storage/BulkDatabase2/dist/mergeLock.ts.cache +149 -0
- package/storage/BulkDatabase2/dist/mergeMarkers.ts.cache +101 -0
- package/storage/BulkDatabase2/dist/streamLog.ts.cache +227 -0
- package/storage/BulkDatabase2/dist/syncClient.ts.cache +104 -0
- package/storage/IArchives.d.ts +47 -15
- package/storage/IArchives.ts +86 -31
- package/storage/backblaze.d.ts +15 -0
- package/storage/backblaze.ts +199 -79
- package/storage/dist/ArchivesDisk.ts.cache +373 -0
- package/storage/dist/FileFolderAPI.tsx.cache +508 -65
- package/storage/dist/IArchives.ts.cache +44 -0
- package/storage/dist/IndexedDBFileFolderAPI.ts.cache +8 -2
- package/storage/dist/JSONStorage.ts.cache +6 -2
- package/storage/dist/PendingManager.tsx.cache +1 -1
- package/storage/dist/TransactionStorage.ts.cache +231 -92
- package/storage/dist/backblaze.ts.cache +797 -0
- package/storage/dist/fileSystemPointer.ts.cache +36 -3
- package/storage/dist/remoteFileStorage.ts.cache +495 -0
- package/storage/remoteStorage/ArchivesRemote.d.ts +5 -1
- package/storage/remoteStorage/ArchivesRemote.ts +28 -8
- package/storage/remoteStorage/ArchivesUrl.d.ts +2 -0
- package/storage/remoteStorage/ArchivesUrl.ts +16 -4
- package/storage/remoteStorage/blobStore.d.ts +63 -3
- package/storage/remoteStorage/blobStore.ts +419 -101
- package/storage/remoteStorage/createArchives.d.ts +31 -10
- package/storage/remoteStorage/createArchives.ts +470 -253
- package/storage/remoteStorage/dist/ArchivesRemote.ts.cache +197 -0
- package/storage/remoteStorage/dist/ArchivesUrl.ts.cache +85 -0
- package/storage/remoteStorage/dist/accessPage.tsx.cache +222 -0
- package/storage/remoteStorage/dist/blobStore.ts.cache +837 -0
- package/storage/remoteStorage/dist/cliArgs.ts.cache +16 -0
- package/storage/remoteStorage/dist/createArchives.ts.cache +610 -0
- package/storage/remoteStorage/dist/remoteConfig.ts.cache +206 -0
- package/storage/remoteStorage/dist/sourceWrapper.ts.cache +223 -0
- package/storage/remoteStorage/dist/storageController.ts.cache +500 -0
- package/storage/remoteStorage/dist/storageServer.ts.cache +106 -0
- package/storage/remoteStorage/dist/storageServerCli.ts.cache +39 -0
- package/storage/remoteStorage/dist/storageServerState.ts.cache +518 -0
- package/storage/remoteStorage/remoteConfig.d.ts +8 -0
- package/storage/remoteStorage/remoteConfig.ts +105 -5
- package/storage/remoteStorage/sourceWrapper.d.ts +41 -0
- package/storage/remoteStorage/sourceWrapper.ts +223 -0
- package/storage/remoteStorage/spec.md +31 -0
- package/storage/remoteStorage/storageController.d.ts +11 -0
- package/storage/remoteStorage/storageController.ts +109 -40
- package/storage/remoteStorage/storageServer.d.ts +0 -5
- package/storage/remoteStorage/storageServer.ts +17 -10
- package/storage/remoteStorage/storageServerCli.ts +0 -3
- package/storage/remoteStorage/storageServerState.d.ts +7 -1
- package/storage/remoteStorage/storageServerState.ts +230 -48
- package/testsite/server.ts +0 -2
- package/yarn.lock +11 -6
|
@@ -3,19 +3,23 @@
|
|
|
3
3
|
import { IArchives, RemoteConfig, RemoteConfigBase, HostedConfig, BackblazeConfig, ArchiveFileInfo, ArchivesConfig, ArchivesSyncStatus } from "../IArchives";
|
|
4
4
|
export declare function createApiArchives(source: HostedConfig | BackblazeConfig): IArchives;
|
|
5
5
|
export declare class ArchivesChain implements IArchives {
|
|
6
|
-
private
|
|
7
|
-
private
|
|
8
|
-
private
|
|
6
|
+
private configured;
|
|
7
|
+
private activeConfig;
|
|
8
|
+
private statePromise;
|
|
9
|
+
private initRetryDelay;
|
|
10
|
+
private initRetryTimer;
|
|
11
|
+
private pollTimer;
|
|
12
|
+
private disposed;
|
|
9
13
|
constructor(config: RemoteConfig | RemoteConfigBase);
|
|
10
14
|
getDebugName(): string;
|
|
11
|
-
private
|
|
12
|
-
private getSources;
|
|
15
|
+
private getState;
|
|
13
16
|
private init;
|
|
14
|
-
private
|
|
15
|
-
private
|
|
16
|
-
private
|
|
17
|
-
private
|
|
18
|
-
private
|
|
17
|
+
private buildSources;
|
|
18
|
+
private startConfigPoll;
|
|
19
|
+
private checkForNewConfig;
|
|
20
|
+
private run;
|
|
21
|
+
private runWrite;
|
|
22
|
+
private request;
|
|
19
23
|
waitingForAccess(): Promise<{
|
|
20
24
|
link: string;
|
|
21
25
|
machineId: string;
|
|
@@ -35,11 +39,14 @@ export declare class ArchivesChain implements IArchives {
|
|
|
35
39
|
}): Promise<{
|
|
36
40
|
data: Buffer;
|
|
37
41
|
writeTime: number;
|
|
42
|
+
size: number;
|
|
38
43
|
} | undefined>;
|
|
39
44
|
getInfo(fileName: string): Promise<{
|
|
40
45
|
writeTime: number;
|
|
41
46
|
size: number;
|
|
42
47
|
} | undefined>;
|
|
48
|
+
private selectCoveringSources;
|
|
49
|
+
private runOnApi;
|
|
43
50
|
find(prefix: string, config?: {
|
|
44
51
|
shallow?: boolean;
|
|
45
52
|
type: "files" | "folders";
|
|
@@ -51,14 +58,28 @@ export declare class ArchivesChain implements IArchives {
|
|
|
51
58
|
getChangesAfter(time: number): Promise<ArchiveFileInfo[]>;
|
|
52
59
|
getSyncStatus(): Promise<ArchivesSyncStatus>;
|
|
53
60
|
getConfig(): Promise<ArchivesConfig>;
|
|
61
|
+
/** True only when EVERY write-receiving source would accept our writes (partial write access
|
|
62
|
+
* desynchronizes sources, so it counts as no access). */
|
|
63
|
+
hasWriteAccess(): Promise<boolean>;
|
|
64
|
+
private assertNotBareVariableShard;
|
|
54
65
|
set(fileName: string, data: Buffer, config?: {
|
|
55
66
|
lastModified?: number;
|
|
56
67
|
}): Promise<void>;
|
|
57
68
|
del(fileName: string): Promise<void>;
|
|
69
|
+
/** Writes a key containing the VARIABLE_SHARD sentinel: picks the lowest-latency up write
|
|
70
|
+
* shard, materializes the key with a random value inside that shard's route, writes it, and
|
|
71
|
+
* returns the FULL key actually written (the caller needs it to ever read the value back).
|
|
72
|
+
* Unlike normal writes this CAN move to another shard when the preferred one is down (error +
|
|
73
|
+
* socket down, same rule as reads) - each shard receives a different key, so write
|
|
74
|
+
* consistency is preserved. */
|
|
75
|
+
setVariableShard(key: string, data: Buffer, config?: {
|
|
76
|
+
lastModified?: number;
|
|
77
|
+
}): Promise<string>;
|
|
58
78
|
setLargeFile(config: {
|
|
59
79
|
path: string;
|
|
60
80
|
getNextData(): Promise<Buffer | undefined>;
|
|
61
81
|
}): Promise<void>;
|
|
62
82
|
getURL(path: string): Promise<string>;
|
|
83
|
+
dispose(): void;
|
|
63
84
|
}
|
|
64
85
|
export declare function createArchives(config: RemoteConfig | RemoteConfigBase): ArchivesChain;
|