UNPKG

reduct-js

Version:

ReductStore Client SDK for Javascript/NodeJS/Typescript

69 lines (68 loc) 1.92 kB
/** * Replication settings */ export declare class OriginalReplicationSettings { src_bucket: string; dst_bucket: string; dst_host: string; dst_token: string; entries: string[]; include?: Record<string, string>; exclude?: Record<string, string>; each_s?: number; each_n?: bigint; when?: any; } /** * Replication settings */ export declare class ReplicationSettings { /** * Source bucket. Must exist. */ readonly srcBucket: string; /** * Destination bucket. Must exist. */ readonly dstBucket: string; /** * Destination host. Must exist. */ readonly dstHost: string; /** * Destination token. Must have write access to the destination bucket. */ readonly dstToken: string; /** * List of entries to replicate. If empty, all entries are replicated. Wildcards are supported. */ readonly entries: string[]; /** * List of labels a records must include. If empty, all records are replicated. * If a few labels are specified, a record must include all of them. * @deprecated: use when instead */ readonly include?: Record<string, string>; /** * List of labels a records must not include. If empty, all records are replicated. * If a few labels are specified, a record must not include any of them. * @deprecated: use when instead */ readonly exclude?: Record<string, string>; /** * Replicate a record every S seconds * @deprecated: use $each_t instead */ readonly eachS?: number; /** * Replicate every Nth record * @deprecated use $each_n instead */ readonly eachN?: bigint; /** * Conditional query */ readonly when?: any; static parse(data: OriginalReplicationSettings): ReplicationSettings; static serialize(data: ReplicationSettings): OriginalReplicationSettings; }