Rush StackShopBlogEvents
Skip to main content

Home > @rushstack/operation-graph > IExecuteOperationContext

IExecuteOperationContext interface

This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.

Information provided to executeAsync by the OperationExecutionManager.

Signature:

export interface IExecuteOperationContext extends Omit<IOperationRunnerContext, 'isFirstRun' | 'requestRun'> 

Extends: Omit<IOperationRunnerContext, 'isFirstRun' | 'requestRun'>

Properties

Property

Modifiers

Type

Description

requestRun?

OperationRequestRunCallback

(BETA) (Optional) A callback to the overarching orchestrator to request that the operation be invoked again. Used in watch mode to signal that inputs have changed.

terminal

ITerminal

(BETA) Terminal to write output to.

Methods

Method

Description

afterExecute(operation, state)

(BETA) Function to invoke after execution of an operation, for logging.

beforeExecute(operation, state)

(BETA) Function to invoke before execution of an operation, for logging.

queueWork(workFn, priority)

(BETA) Function used to schedule the concurrency-limited execution of an operation.

Will return OperationStatus.Aborted if execution is aborted before the task executes.