Thanks to visit codestin.com
Credit goes to effect-ts.github.io

Skip to main content Codestin Search App Codestin Search App Codestin Search App Codestin Search App Codestin Search App Codestin Search App

SqlRunnerStorage.ts overview

Since v1.0.0


Exports Grouped by Category


Constructors

make

Signature

declare const make: (options: {
  readonly prefix?: string | undefined
}) => Effect.Effect<
  {
    readonly register: (runner: Runner, healthy: boolean) => Effect.Effect<MachineId, PersistenceError>
    readonly unregister: (address: RunnerAddress) => Effect.Effect<void, PersistenceError>
    readonly getRunners: Effect.Effect<Array<readonly [runner: Runner, healthy: boolean]>, PersistenceError>
    readonly setRunnerHealth: (address: RunnerAddress, healthy: boolean) => Effect.Effect<void, PersistenceError>
    readonly acquire: (
      address: RunnerAddress,
      shardIds: Iterable<ShardId.ShardId>
    ) => Effect.Effect<Array<ShardId.ShardId>, PersistenceError>
    readonly refresh: (
      address: RunnerAddress,
      shardIds: Iterable<ShardId.ShardId>
    ) => Effect.Effect<Array<ShardId.ShardId>, PersistenceError>
    readonly release: (address: RunnerAddress, shardId: ShardId.ShardId) => Effect.Effect<void, PersistenceError>
    readonly releaseAll: (address: RunnerAddress) => Effect.Effect<void, PersistenceError>
  },
  SqlError,
  SqlClient.SqlClient | ShardingConfig.ShardingConfig | Scope.Scope
>

Source

Since v1.0.0

Layers

layer

Signature

declare const layer: Layer.Layer<
  RunnerStorage.RunnerStorage,
  SqlError,
  SqlClient.SqlClient | ShardingConfig.ShardingConfig
>

Source

Since v1.0.0

layerWith

Signature

declare const layerWith: (options: {
  readonly prefix?: string | undefined
}) => Layer.Layer<RunnerStorage.RunnerStorage, SqlError, SqlClient.SqlClient | ShardingConfig.ShardingConfig>

Source

Since v1.0.0