@eyevinn/iaf-plugin-aws
Version:
Eyevinn Ingest Application Framework (IAF) plugin for upload and transcode in AWS
24 lines (23 loc) • 1.14 kB
TypeScript
import { MediaConvertDispatcher } from "./mediaConvertDispatcher";
import { S3Uploader } from "./s3Uploader";
import { Readable } from "stream";
import { IafUploadModule } from "eyevinn-iaf";
import { Logger } from "eyevinn-iaf";
export declare class AwsUploadModule implements IafUploadModule {
logger: Logger;
playlistName: string;
fileName: string;
uploader: S3Uploader;
dispatcher: MediaConvertDispatcher;
fileUploadedDelegate: (result: any, error?: any) => any;
progressDelegate: (result: any) => any;
constructor(mediaConvertEndpoint: string, awsRegion: string, ingestBucket: string, outputBucket: string, roleArn: string, playlistName: string, encodeParams: string, outputFiles: {}, logger: Logger, watcherTimeout?: number);
/**
* Method that runs when a FileWatcher detects a new file.
* Uploads the file to an S3 ingress bucket, and dispatches a transcoding job when
* the upload is completed.
* @param filePath the path to the file being added.
* @param readStream Readable stream of the file.
*/
onFileAdd: (filePath: string, readStream: Readable) => void;
}