@@ -33,20 +33,6 @@ import {
3333 SuspendedProcessError ,
3434} from "@trigger.dev/core/v3/errors" ;
3535
36- export type OnWaitForDurationMessage = InferSocketMessageSchema <
37- typeof ExecutorToWorkerMessageCatalog ,
38- "WAIT_FOR_DURATION"
39- > ;
40- export type OnWaitForTaskMessage = InferSocketMessageSchema <
41- typeof ExecutorToWorkerMessageCatalog ,
42- "WAIT_FOR_TASK"
43- > ;
44- export type OnWaitForBatchMessage = InferSocketMessageSchema <
45- typeof ExecutorToWorkerMessageCatalog ,
46- "WAIT_FOR_BATCH"
47- > ;
48- export type OnWaitMessage = InferSocketMessageSchema < typeof ExecutorToWorkerMessageCatalog , "WAIT" > ;
49-
5036export type TaskRunProcessOptions = {
5137 workerManifest : WorkerManifest ;
5238 serverWorker : ServerBackgroundWorker ;
@@ -82,11 +68,6 @@ export class TaskRunProcess {
8268 public onExit : Evt < { code : number | null ; signal : NodeJS . Signals | null ; pid ?: number } > =
8369 new Evt ( ) ;
8470 public onIsBeingKilled : Evt < TaskRunProcess > = new Evt ( ) ;
85- public onReadyToDispose : Evt < TaskRunProcess > = new Evt ( ) ;
86-
87- public onWaitForTask : Evt < OnWaitForTaskMessage > = new Evt ( ) ;
88- public onWaitForBatch : Evt < OnWaitForBatchMessage > = new Evt ( ) ;
89- public onWait : Evt < OnWaitMessage > = new Evt ( ) ;
9071
9172 private _isPreparedForNextRun : boolean = false ;
9273 private _isPreparedForNextAttempt : boolean = false ;
@@ -191,20 +172,9 @@ export class TaskRunProcess {
191172
192173 resolver ( result ) ;
193174 } ,
194- READY_TO_DISPOSE : async ( ) => {
195- logger . debug ( `task run process is ready to dispose` ) ;
196-
197- this . onReadyToDispose . post ( this ) ;
198- } ,
199175 TASK_HEARTBEAT : async ( message ) => {
200176 this . onTaskRunHeartbeat . post ( message . id ) ;
201177 } ,
202- WAIT_FOR_TASK : async ( message ) => {
203- this . onWaitForTask . post ( message ) ;
204- } ,
205- WAIT_FOR_BATCH : async ( message ) => {
206- this . onWaitForBatch . post ( message ) ;
207- } ,
208178 UNCAUGHT_EXCEPTION : async ( message ) => {
209179 logger . debug ( "uncaught exception in task run process" , { ...message } ) ;
210180 } ,
0 commit comments