Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(server): thread list reads no longer freeze the server on large databases #14703

Closedsaphid(GitHub profile, opens in a new tab)wants to merge 7 commits intomain fromrefs/pull/14703/headopened View on GitHub

Showing 6 changed files with 93 additions and 11 deletions (loading 3).

x
0 of 6 viewed, 6 left
73 additions and 0 deletionsapps/server/src/orchestration-v2/ShellStream.test.tsModified
View file
@@ -1,17 +1,23 @@
import { describe, expect, it } from "@effect/vitest";
import type {
ApplicationStoredEvent,
+ OrchestrationProjectShell,
OrchestrationV2ShellSnapshot,
OrchestrationV2ShellStreamItem,
OrchestrationV2StoredEvent,
OrchestrationV2ThreadShell,
} from "@t3tools/contracts";
import { ProjectId, ProviderInstanceId, ThreadId } from "@t3tools/contracts";
+import * as NodeServices from "@effect/platform-node/NodeServices";
import * as NodeSqliteClient from "@t3tools/shared/nodeSqliteClient";
import * as DateTime from "effect/DateTime";
import * as Duration from "effect/Duration";
import * as Effect from "effect/Effect";
+import * as Fiber from "effect/Fiber";
+import * as FileSystem from "effect/FileSystem";
+import * as Deferred from "effect/Deferred";
import * as Option from "effect/Option";
+import * as Path from "effect/Path";
import * as SqlClient from "effect/sql/SqlClient";
import * as Stream from "effect/Stream";
import * as TestClock from "effect/testing/TestClock";
@@ -144,6 +150,73 @@
expect(snapshot.threads.threads).toEqual([thread]);
}).pipe(Effect.provide(NodeSqliteClient.layer({ filename: ":memory:" }))),
+​
+ it.effect(