nl_tokens: safely stop the execution without setting the ex status to stopping or stopped
pl_tokens: function finishExecution ( exId , err ) { if ( err ) { const error = new TSError ( err , { reason : ` ${ exId } ` , context : { ex_id : exId , } } ) ; logger . error ( error ) ; } return getExecutionContext ( exId ) . then ( ( execution ) => { const status = execution . _status ; if ( [ 'stopping' , 'stopped' ] . includes ( status ) ) { logger . debug ( ` ${ exId } ` ) ; return true ; } logger . debug ( ` ${ exId } ` ) ; return clusterService . stopExecution ( exId ) . catch ( ( stopErr ) => { const stopError = new TSError ( stopErr , { <mask> : 'error finishing the execution' , context : { ex_id : exId , } } ) ; logger . error ( stopError ) ; } ) ; } ) ; }