Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(server): project lookups stop flooding the server trace #16202

Closedt3dotgg(GitHub profile, opens in a new tab)wants to merge 1 commit intomain fromt3code/server-trace-volumeopened View on GitHub

Showing 3 changed files with 42 additions and 36 deletions.

x
0 of 3 viewed, 3 left
37 additions and 34 deletionsapps/server/src/project/ProjectEnrichmentService.tsModified
View file
@@ -210,7 +210,10 @@
{ concurrency: "unbounded", discard: true },
​
- const requestLane = Effect.fn("ProjectEnrichmentService.requestLane")(function* (
+ // requestLane, peek and request are cache reads that run on every project
+ // shell read, so they stay untraced; getAvailable and ProjectService record
+ // the call.
+ const requestLane = Effect.fnUntraced(function* (
lane: EnrichmentWorkLane,
workspaceRoot: string,
field: "repositoryIdentity" | "faviconPath",
@@ -225,40 +228,40 @@
});
​
- const peek: ProjectEnrichmentService["Service"]["peek"] = Effect.fn(
- "ProjectEnrichmentService.peek",
- )(function* (workspaceRoot) {
- const [repositoryIdentity, faviconPath] = yield* Effect.all(
- [
- Cache.getSuccess(repositoryIdentityCache, workspaceRoot),
- Cache.getSuccess(faviconCache, workspaceRoot),
- ] as const,
- { concurrency: "unbounded" },
- );
- return {
- repositoryIdentity: availableValue(repositoryIdentity),
- faviconPath: availableValue(faviconPath),