mirror of
https://github.com/trustgraph-ai/trustgraph.git
synced 2026-07-01 09:29:38 +02:00
Make gateway dispatcher requestors Effect-scoped
This commit is contained in:
parent
a0d2575273
commit
64fb23e7d0
6 changed files with 395 additions and 66 deletions
|
|
@ -13,7 +13,7 @@ import { Config, Effect, Exit, Scope } from "effect";
|
|||
import * as O from "effect/Option";
|
||||
import * as RpcSerialization from "effect/unstable/rpc/RpcSerialization";
|
||||
import * as EffectSocket from "effect/unstable/socket/Socket";
|
||||
import { optionalStringConfig, registry, toTgError } from "@trustgraph/base";
|
||||
import { optionalStringConfig, registry, toTgError, type PubSubBackend } from "@trustgraph/base";
|
||||
import { makeDispatcherManager } from "./dispatch/manager.js";
|
||||
import { makeGatewayRpcServer } from "./rpc-server.js";
|
||||
|
||||
|
|
@ -22,6 +22,7 @@ export interface GatewayConfig {
|
|||
metricsPort: number;
|
||||
secret?: string;
|
||||
natsUrl?: string;
|
||||
pubsub?: PubSubBackend;
|
||||
}
|
||||
|
||||
export async function createGateway(config: GatewayConfig) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue