• Preparing search index...
  • The search index is not available
@daiso-tech/core - v0.56.0
  • @daiso-tech/core
  • Semaphore
  • withSemaphorePrefix

Function withSemaphorePrefix

  • withSemaphorePrefix(prefix: string): PluginFn<ISemaphoreAdapter>
  • Creates a plugin that prefixes all keys passed to a semaphore adapter.

    Every method that accepts a semaphore key will have the given prefix prepended before the call is forwarded to the underlying adapter. This is useful for namespacing semaphore state when multiple independent consumers share the same backend.

    Parameters

    • prefix: string

      The string to prepend to every semaphore key.

    Returns PluginFn<ISemaphoreAdapter>

    A middleware plugin that wraps an ISemaphoreAdapter.

    IMPORT_PATH: "@daiso-tech/core/semaphore/plugins"

    • Defined in src/semaphore/implementations/plugins/with-semaphore-prefix/with-semaphore-prefix.ts:22

Settings

Member Visibility
@daiso-tech/core - v0.56.0
  • Loading...

Generated using TypeDoc