@hpcc-js/comms
Version:
hpcc-js - Communications
104 lines (103 loc) • 4.89 kB
TypeScript
import { Cache, StateCallback, StateEvents, StateObject, StatePropCallback } from "@hpcc-js/util";
import { IConnection, IOptions } from "../connection";
import { WsSMC } from "../services/wsSMC";
import { FileSpray, FileSprayService, UpdateDFUWorkunitEx } from "../services/fileSpray";
import * as WsTopology from "../services/wsTopology";
export declare class DFUWorkunitCache extends Cache<{
BaseUrl: string;
ID: string;
}, DFUWorkunit> {
constructor();
}
export type DFUWorkunitEvents = "finished" | StateEvents;
export type UDFUWorkunitState = FileSpray.DFUWorkunit;
export type IDFUWorkunitState = FileSpray.DFUWorkunit | WsSMC.ActiveWorkunit;
export declare class DFUWorkunit extends StateObject<UDFUWorkunitState, IDFUWorkunitState> implements FileSpray.DFUWorkunit {
connection: FileSprayService;
topologyConnection: WsTopology.TopologyService;
readonly BaseUrl: string;
readonly properties: FileSpray.DFUWorkunit;
readonly ID: string;
readonly DFUServerName: string;
readonly ClusterName: string;
readonly JobName: string;
readonly Queue: string;
readonly User: string;
readonly isProtected: boolean;
readonly Command: number;
readonly CommandMessage: string;
readonly PercentDone: number;
readonly SecsLeft: number;
readonly ProgressMessage: string;
readonly SummaryMessage: string;
readonly State: number;
readonly SourceLogicalName: string;
readonly SourceIP: string;
readonly SourceFilePath: string;
readonly SourceDali: string;
readonly SourceRecordSize: number;
readonly SourceFormat: number;
readonly RowTag: string;
readonly SourceNumParts: number;
readonly SourceDirectory: string;
readonly DestLogicalName: string;
readonly DestGroupName: string;
readonly DestDirectory: string;
readonly DestIP: string;
readonly DestFilePath: string;
readonly DestFormat: number;
readonly DestNumParts: number;
readonly DestRecordSize: number;
readonly Replicate: boolean;
readonly Overwrite: boolean;
readonly Compress: boolean;
readonly SourceCsvSeparate: string;
readonly SourceCsvQuote: string;
readonly SourceCsvTerminate: string;
readonly SourceCsvEscape: string;
readonly TimeStarted: string;
readonly TimeStopped: string;
readonly StateMessage: string;
readonly MonitorEventName: string;
readonly MonitorSub: boolean;
readonly MonitorShotLimit: number;
readonly SourceDiffKeyName: string;
readonly DestDiffKeyName: string;
readonly Archived: boolean;
readonly encrypt: string;
readonly decrypt: string;
readonly failIfNoSourceFile: boolean;
readonly recordStructurePresent: boolean;
readonly quotedTerminator: boolean;
readonly preserveCompression: boolean;
readonly expireDays: number;
readonly PreserveFileParts: boolean;
readonly FileAccessCost: number;
readonly KbPerSecAve: number;
readonly KbPerSec: number;
static create(optsConnection: IOptions | IConnection, dfuServerQueue: string): Promise<DFUWorkunit>;
static attach(optsConnection: IOptions | IConnection, wuid: string, state?: IDFUWorkunitState): DFUWorkunit;
static sprayFixed(server: IOptions | IConnection, request: Partial<FileSpray.SprayFixed>): Promise<DFUWorkunit>;
static sprayVariable(server: IOptions | IConnection, request: Partial<FileSpray.SprayVariable>): Promise<DFUWorkunit>;
static despray(server: IOptions | IConnection, request: Partial<FileSpray.Despray>): Promise<DFUWorkunit>;
update(request: Partial<UpdateDFUWorkunitEx>): Promise<FileSpray.UpdateDFUWorkunitResponse>;
isComplete(): boolean;
isFailed(): boolean;
isDeleted(): boolean;
isRunning(): boolean;
abort(): Promise<FileSpray.AbortDFUWorkunitResponse>;
delete(): Promise<FileSpray.DFUWorkunitsActionResponse>;
refresh(full?: boolean): Promise<this>;
fetchXML(callback?: void): Promise<string>;
protected _monitor(): void;
protected _monitorTimeoutDuration(): number;
protected DFUWUFile(_request?: Partial<FileSpray.DFUWUFileRequest>): Promise<string>;
protected DFUWUAction(actionType: FileSpray.DFUWUActions): Promise<FileSpray.DFUWorkunitsActionResponse>;
on(eventID: DFUWorkunitEvents, propIDorCallback: StateCallback | keyof UDFUWorkunitState, callback?: StatePropCallback): this;
watchUntilComplete(callback?: StateCallback): Promise<this>;
watchUntilRunning(callback?: StateCallback): Promise<this>;
protected constructor(optsConnection: IOptions | IConnection, wuid?: string);
clearState(wuid?: string): void;
protected GetDFUWorkunit(_request?: Partial<FileSpray.GetDFUWorkunit>): Promise<FileSpray.GetDFUWorkunitResponse>;
}
//# sourceMappingURL=dfuWorkunit.d.ts.map