Options
All
  • Public
  • Public/Protected
  • All
Menu

Module @aws-sdk/property-provider

@aws-sdk/property-provider

NPM version NPM downloads

An internal package

Usage

You probably shouldn't, at least directly.

Index

References

CredentialsProviderError

Re-exports CredentialsProviderError

ProviderError

Re-exports ProviderError

chain

Re-exports chain

fromStatic

Re-exports fromStatic

memoize

Re-exports memoize

Functions

chain

  • Compose a single credential provider function from multiple credential providers. The first provider in the argument list will always be invoked; subsequent providers in the list will be invoked in the order in which the were received if the preceding provider did not successfully resolve.

    If no providers were received or no provider resolves successfully, the returned promise will be rejected.

    Type parameters

    • T

    Parameters

    Returns Provider<T>

Const fromStatic

  • fromStatic<T>(staticValue: T): Provider<T>

Const memoize

  • memoize<T>(provider: Provider<T>, isExpired?: (resolved: T) => boolean, requiresRefresh?: (resolved: T) => boolean): MemoizedProvider<T>
  • Type parameters

    • T

    Parameters

    • provider: Provider<T>
    • Optional isExpired: (resolved: T) => boolean
        • (resolved: T): boolean
        • Parameters

          • resolved: T

          Returns boolean

    • Optional requiresRefresh: (resolved: T) => boolean
        • (resolved: T): boolean
        • Parameters

          • resolved: T

          Returns boolean

    Returns MemoizedProvider<T>