@launchdarkly/js-server-sdk-common - v2.26.1
    Preparing search index...

    Interface LDTransactionalDataSourceUpdates

    Transactional version of LDDataSourceUpdates with support for applyChanges

    interface LDTransactionalDataSourceUpdates {
        applyChanges(
            basis: boolean,
            data: LDFeatureStoreDataStorage,
            callback: () => void,
            initMetadata?: InitMetadata,
            selector?: string,
        ): void;
        init(
            allData: LDFeatureStoreDataStorage,
            callback: () => void,
            initMetadata?: InitMetadata,
        ): void;
        upsert(
            kind: DataKind,
            data: LDKeyedFeatureStoreItem,
            callback: () => void,
        ): void;
    }

    Hierarchy (View Summary)

    Index
    • Parameters

      • basis: boolean

        If true, completely overwrites the current contents of the data store with the provided data. If false, upserts the items in the provided data. Upserts are made only if provided items have newer versions than existing items.

      • data: LDFeatureStoreDataStorage

        An object in which each key is the "namespace" of a collection (e.g. "features") and the value is an object that maps keys to entities. The actual type of this parameter is interfaces.FullDataSet<VersionedData>.

      • callback: () => void

        Will be called after the changes are applied.

      • OptionalinitMetadata: InitMetadata

        Optional metadata to initialize the data source with.

      • Optionalselector: string

        opaque string that uniquely identifies the state that contains the changes

      Returns void