Theia API Documentation v1.71.0
    Preparing search index...

    Tracks the settlement of async work initiated by contributions during application startup.

    A contribution "settles" when all promises it returned from lifecycle methods (initialize, configure, onStart, etc.) have resolved. Individual settlement is only logged when a contribution returned promises from more than one lifecycle method; otherwise the single lifecycle measurement already describes the work. An aggregate "all settled" message is logged once all tracked promises across all contributions have resolved.

    Typical usage:

    1. Create the context at the start of the application lifecycle.
    2. Before each lifecycle call, call ensureEntry to start the per-contribution clock.
    3. After each lifecycle call, call trackSettlement with the return value.
    4. After the startup sequence completes, call armAllSettled to enable the aggregate message.

    Type Parameters

    • T extends object = object
    Index

    Constructors

    Properties

    owner: string
    stopwatch: Stopwatch
    thresholdMillis: number

    Methods

    • Arm the aggregate "all settled" log message. Call this after the startup sequence has finished collecting all promises. If all promises have already settled, the message is logged immediately.

      Returns void

    • Ensure that settlement tracking has been started for the given contribution. Starts the per-contribution measurement clock on the first call for each contribution.

      Parameters

      • item: T

      Returns void