1 | {"version":3,"sources":["../../../src/commands/WorkerCommand.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;AAAA,mCAA8B;AAC9B,oDAA+C;AAC/C,6CAAwC;AAIxC,MAAa,aAAa;IAA1B;QAME,YAAO,GAAG,QAAQ,CAAC;QAEnB,YAAO,GAAG,GAAG,CAAC;QAEd,aAAQ,GAAG,eAAe,CAAC;IAoB7B,CAAC;IAlBC,OAAO,CAAC,KAAU;QAChB,OAAO,KAAK,CAAC;IACf,CAAC;IAGK,OAAO,CAAC,IAAS;;YACrB,kDAAkD;YAElD,IAAI,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,MAAM,GAAG,CAAC,EAAE;gBACnC,SAAG,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,MAAM,GAAG,sBAAsB,CAAC,CAAC;gBAC/D,MAAM,IAAI,OAAO,CAAC,OAAO,CAAC,EAAE;gBAC5B,CAAC,CAAC,CAAC;aACJ;iBAAM;gBACL,OAAO,CAAC,GAAG,CAAC,mBAAmB,CAAC,CAAC;aAClC;QAEH,CAAC;KAAA;CAEF;AA1BC;IADC,eAAM,CAAC,iBAAO,CAAC,IAAI,CAAC;8BACZ,iBAAO;8CAAC;AAJnB,sCA8BC","file":"WorkerCommand.js","sourcesContent":["import {Inject} from 'typedi';\nimport {Workers} from '../libs/worker/Workers';\nimport {Log} from '../libs/logging/Log';\nimport {ICommand} from '../libs/commands/ICommand';\n\n\nexport class WorkerCommand implements ICommand {\n\n\n @Inject(Workers.NAME)\n workers: Workers;\n\n command = 'worker';\n\n aliases = 'w';\n\n describe = 'Handle worker';\n\n builder(yargs: any) {\n return yargs;\n }\n\n\n async handler(argv: any) {\n // worker are started in Startup if defined neewer\n\n if (this.workers.workers.length > 0) {\n Log.info(this.workers.workers.length + ' workers are online.');\n await new Promise(resolve => {\n });\n } else {\n console.log('No workers found.');\n }\n\n }\n\n}\n\n"],"sourceRoot":".."} |