Skip to main content
Version: v1

LoaderContainerTracker Class

Signature

export declare class LoaderContainerTracker implements IOpProcessingController

Implements: IOpProcessingController

Constructors

Constructor Description
(constructor)(syncSummarizerClients) Constructs a new instance of the LoaderContainerTracker class

Methods

Method Return Type Description
add(loader) void Add a loader to start to track any container created from them
ensureSynchronized(containers) Promise<void> Make sure all the tracked containers are synchronized. - No isDirty (non-readonly) containers - No extra clientId in quorum of any container that is not tracked and still opened. - i.e. no pending Join/Leave message. - No unresolved proposal (minSeqNum \>= lastProposalSeqNum) - lastSequenceNumber of all container is the same - clientSequenceNumberObserved is the same as clientSequenceNumber sent - this overlaps with !isDirty, but include task scheduler ops. - Trailing NoOp is tracked and don't count as pending ops.
pauseProcessing(containers) Promise<void> Pause all queue activities on the containers given, or all tracked containers Any containers given that is not tracked will be ignored.
processIncoming(containers) Promise<void> Pause all queue activities on all tracked containers, and resume only inbound to process ops until it is idle. All queues are left in the paused state after the function
processOutgoing(containers) Promise<void> Pause all queue activities on all tracked containers, and resume only outbound to process ops until it is idle. All queues are left in the paused state after the function
reset() void Reset the tracker, closing all containers and stop tracking them.
resumeProcessing(containers) IContainer[] Resume all queue activities on all paused tracked containers and return them

Constructor Details

(constructor)

Constructs a new instance of the LoaderContainerTracker class

Signature

constructor(syncSummarizerClients?: boolean);

Parameters

Parameter Modifiers Type Description
syncSummarizerClients optional boolean

Method Details

add

Add a loader to start to track any container created from them

Signature

add<LoaderType extends IHostLoader>(loader: LoaderType): void;
Type Parameters
Parameter Constraint Description
LoaderType IHostLoader

Parameters

Parameter Type Description
loader LoaderType loader to start tracking any container created.

ensureSynchronized

Make sure all the tracked containers are synchronized. - No isDirty (non-readonly) containers - No extra clientId in quorum of any container that is not tracked and still opened. - i.e. no pending Join/Leave message. - No unresolved proposal (minSeqNum >= lastProposalSeqNum) - lastSequenceNumber of all container is the same - clientSequenceNumberObserved is the same as clientSequenceNumber sent - this overlaps with !isDirty, but include task scheduler ops. - Trailing NoOp is tracked and don't count as pending ops.

Signature

ensureSynchronized(...containers: IContainer[]): Promise<void>;

Parameters

Parameter Type Description
containers IContainer[]

Returns

Return type: Promise<void>

pauseProcessing

Pause all queue activities on the containers given, or all tracked containers Any containers given that is not tracked will be ignored.

Signature

pauseProcessing(...containers: IContainer[]): Promise<void>;

Parameters

Parameter Type Description
containers IContainer[]

Returns

Return type: Promise<void>

processIncoming

Pause all queue activities on all tracked containers, and resume only inbound to process ops until it is idle. All queues are left in the paused state after the function

Signature

processIncoming(...containers: IContainer[]): Promise<void>;

Parameters

Parameter Type Description
containers IContainer[]

Returns

Return type: Promise<void>

processOutgoing

Pause all queue activities on all tracked containers, and resume only outbound to process ops until it is idle. All queues are left in the paused state after the function

Signature

processOutgoing(...containers: IContainer[]): Promise<void>;

Parameters

Parameter Type Description
containers IContainer[]

Returns

Return type: Promise<void>

reset

Reset the tracker, closing all containers and stop tracking them.

Signature

reset(): void;

resumeProcessing

Resume all queue activities on all paused tracked containers and return them

Signature

resumeProcessing(...containers: IContainer[]): IContainer[];

Parameters

Parameter Type Description
containers IContainer[]

Returns

Return type: IContainer[]