ProtectedconstructorReadonlyShutdownIdentifier surfaced in graceful-shutdown logs.
StaticInstanceProcess-wide singleton accessor.
The Global Object Store is a place to store global objects that need to be shared across the application. Depending on the execution environment, this could be the window object in a browser, or the global object in a node environment, or something else in other contexts. The key here is that in some cases static variables are not truly shared because it is possible that a given class might have copies of its code in multiple paths in a deployed application. This approach ensures that no matter how many code copies might exist, there is only one instance of the object in question by using the Global Object Store.
Requests an assembly of sessionID after delayMs. One pending timer per session: a request
replaces the pending one only when it would fire sooner (at the same time, the merged request keeps
forcePartial if either had it). A timer that fires while the session's previous run is still going
is remembered and run right after it, never alongside it.
Trade-off: a sooner un-forced request replaces a pending forced one. If that run comes back
Deferred (still incomplete), the forced Partial is re-scheduled a full grace from then, so a
forced Partial can land up to ~2× the grace after the first terminal signal. Accepted: the sooner
run completes the recording outright whenever the missing shards did arrive.
Cancels every pending timer and stops accepting requests until the next Start. A running
assembly is not awaited: if the process exits under it, the session stays Assembling and the
janitor's stale re-claim finishes it. Idempotent.
Configures the scheduler and enables it; calling again replaces the configuration.
Protected StaticgetReturns the singleton instance of the class. If the instance does not exist, it is created and stored in the Global Object Store. If className is provided it will be used as part of the key in the Global Object Store, otherwise the actual class name will be used. NOTE: the class name used by default is the lowest level of the object hierarchy, so if you have a class that extends another class, the lowest level class name will be used.
OptionalclassName: string
Process-wide scheduler of recording assemblies (see the file overview). Call Start once at server startup; requests made before it (or after Shutdown) are logged and dropped, leaving the session to the janitor.