Skip to main content
Version: v1

@fluidframework/tool-utils Package

Interfaces

Interface Description
IAsyncCache
IOdspTokenManagerCacheKey
IResources
ISnapshotNormalizerConfig

Classes

Class Description
OdspTokenManager

Types

TypeAlias Description
OdspTokenConfig

Functions

Function Return Type Description
getNormalizedSnapshot(snapshot, config) ITree Helper function that normalizes the given snapshot tree. It sorts objects and arrays in the snapshot. It also normalizes certain blob contents for which the order of content does not matter. For example, garbage collection blobs contains objects / arrays whose element order do not matter.
loadRC() Promise<IResources>
lockRC() Promise<any>
saveRC(rc) Promise<void>

Variables

Variable Type Description
gcBlobPrefix The prefix that all GC blob names start with.
getMicrosoftConfiguration () => IClientConfig
odspTokensCache IAsyncCache<IOdspTokenManagerCacheKey, IOdspTokens>

Function Details

getNormalizedSnapshot

Helper function that normalizes the given snapshot tree. It sorts objects and arrays in the snapshot. It also normalizes certain blob contents for which the order of content does not matter. For example, garbage collection blobs contains objects / arrays whose element order do not matter.

Signature

export declare function getNormalizedSnapshot(snapshot: ITree, config?: ISnapshotNormalizerConfig): ITree;

Parameters

Parameter Modifiers Type Description
snapshot ITree The snapshot tree to normalize.
config optional ISnapshotNormalizerConfig Configs to use when normalizing snapshot. For example, it can contain paths of blobs whose contents should be normalized as well.

Returns

a copy of the normalized snapshot tree.

Return type: ITree

loadRC

Signature

export declare function loadRC(): Promise<IResources>;

Returns

Return type: Promise<IResources>

lockRC

Signature

export declare function lockRC(): Promise<any>;

Returns

Return type: Promise<any>

saveRC

Signature

export declare function saveRC(rc: IResources): Promise<void>;

Parameters

Parameter Type Description
rc IResources

Returns

Return type: Promise<void>

Variable Details

gcBlobPrefix

The prefix that all GC blob names start with.

Signature

gcBlobPrefix = "__gc"

getMicrosoftConfiguration

Signature

getMicrosoftConfiguration: () => IClientConfig

Type: () => IClientConfig

odspTokensCache

Signature

odspTokensCache: IAsyncCache<IOdspTokenManagerCacheKey, IOdspTokens>

Type: IAsyncCache<IOdspTokenManagerCacheKey, IOdspTokens>