| 6128 | // -- caller-only fetches ---------------------------------------------------- |
| 6129 | /** A fetcher call for its callers alone. A stream query's is its first element. */ |
| 6130 | const fetchOnce = ( |
| 6131 | def: QueryDef, |
| 6132 | build: Build, |
| 6133 | args: unknown, |
| 6134 | logKey: () => string |
| 6135 | ): Effect.Effect<any, any> => { |
| 6136 | const out = build.fetcher(args) |
| 6137 | return def.live === undefined ? out : def.live.once(def, out, logKey) |
| 6138 | } |
| 6139 | /** |
| 6140 | * Like a stored fetch, a caller-only one starts only once what it replaces has finished its cleanup: the stored |
| 6141 | * fetch it was converted from, or its own fetch under a build that closed. |