Type Alias MultiServerUpload
MultiServerUpload: (
servers: readonly string[],
blob: Blob,
options: {
onAuth: (
server: string,
sha256: string,
type: "upload" | "media",
) => Promise<SignedEvent>;
onError: (
server: string,
sha256: string,
blob: Blob,
error: Error,
) => void;
onUpload: (server: string) => void;
},
) => Promise<Map<string, BlobDescriptor>>
Type Declaration
-
- (
servers: readonly string[],
blob: Blob,
options: {
onAuth: (
server: string,
sha256: string,
type: "upload" | "media",
) => Promise<SignedEvent>;
onError: (
server: string,
sha256: string,
blob: Blob,
error: Error,
) => void;
onUpload: (server: string) => void;
},
): Promise<Map<string, BlobDescriptor>>
-
Parameters
- servers: readonly string[]
- blob: Blob
- options: {
onAuth: (
server: string,
sha256: string,
type: "upload" | "media",
) => Promise<SignedEvent>;
onError: (server: string, sha256: string, blob: Blob, error: Error) => void;
onUpload: (server: string) => void;
}
Returns Promise<Map<string, BlobDescriptor>>
Uploads to several servers, the first first and the rest as mirrors; hzrd149's
multiServerUploadfits.