Files
t3code/apps/server/src/orchestration-v2/ThreadCommandExecutor.ts
T
2026-10-04 21:31:52 -07:00

13 lines
544 B
TypeScript

import type { ThreadId } from "@t3tools/contracts";
import * as KeyedLock from "@t3tools/shared/KeyedLock";
import * as Context from "effect/Context";
import * as Layer from "effect/Layer";
/** Shared by thread commands and project deletion so both plan against current thread state. */
export class ThreadCommandExecutor extends Context.Service<
ThreadCommandExecutor,
KeyedLock.KeyedLock<ThreadId>
>()("t3/orchestration-v2/ThreadCommandExecutor") {}
export const layer = Layer.effect(ThreadCommandExecutor, KeyedLock.make<ThreadId>());