factories to create DataSystemInitializers, in priority order.
factories to create DataSystemSynchronizers, in priority order.
factories to fallback to if we need to fallback to FDv1.
Optional
_logger: LDLoggerfor logging
Optional
to control automated transition between datasources. Typically only used for testing.
to control delay between transitions. Typically only used for testing.
Private
Readonly
_backoffto control delay between transitions. Typically only used for testing.
Private
_cancelPrivate
_externalPrivate
Optional
_externalPrivate
_fdv1Private
_initPrivate
_initPrivate
Optional
Readonly
_loggerfor logging
Private
_stoppedPrivate
_syncPrivate
Readonly
_transitionto control automated transition between datasources. Typically only used for testing.
Private
_cancellablePrivate
_consumePrivate
_lookupthe transition condition for the provided data source state or undefined if there is no transition condition
Private
_pickDetermines the next datasource and returns that datasource as well as a closure to cull the datasource from the datasource lists. One example where the cull closure is invoked is if the datasource has an unrecoverable error.
Optional
transition: TransitionOptional
Private
_resetPrivate
_wrapThis wrapper will ensure the following:
Don't report DataSourceState.Initializing except as first status callback. Map underlying DataSourceState.Closed to interrupted. Don't report the same status and error twice in a row.
Optional
err: anyOptional
This wrapper will ensure the following:
Don't report DataSourceState.Initializing except as first status callback. Map underlying DataSourceState.Closed to interrupted. Don't report the same status and error twice in a row.
Optional
err: anyOptional
May be called any number of times, if already started, has no effect
that will be called when data arrives, may be called multiple times.
that will be called when data source state changes or an unrecoverable error has been encountered.
Optional
err: anyOptional
Optional
selectorGetter: (() => undefined | string)that can be invoked to provide the FDv2 selector/basis if one exists
Optional
Generated using TypeDoc
The CompositeDataSource can combine a number of DataSystemInitializers and DataSystemSynchronizers into a single DataSource, implementing fallback and recovery logic internally to choose where data is sourced from.