Hyperlinkv0.8.0-beta.28

Types

Types.Concurrencytypeeffect/Types.ts:440
Concurrency

Describes the concurrency level for Effect operations that run multiple effects.

When to use

Use to type options that control how many effects may run at the same time.

Details

  • number — run at most N effects concurrently.
  • "unbounded" — run all effects concurrently with no limit.
  • "inherit" — inherit the concurrency from the surrounding context.

Example (Setting concurrency values)

import type { Types } from "effect"

const sequential: Types.Concurrency = 1
const limited: Types.Concurrency = 5
const unbounded: Types.Concurrency = "unbounded"
const inherit: Types.Concurrency = "inherit"
models
Source effect/Types.ts:4401 lines
export type Concurrency = number | "unbounded" | "inherit"
Referenced by 8 symbols