Repository navigation
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Superseded by #1881 on
fix/graphile-readiness-disposal. Both PRs have identical base/head commits and diffs; review continues in #1881. The old branch is retained.Graphile instances need explicit build readiness and reliable cleanup across cache entry generations. This Draft targets the complete readiness and generation-scoped disposal work described in #1747, developed incrementally with review before each next step.
The current implementation covers build readiness only.
createGraphileInstancewaits for schema construction, HTTP attachment, and Grafserv readiness before returning an entry or starting realtime. Success values usevoid; the upstream schema result object is explicitly adapted withPromise.resolve(pgl.getSchemaResult()).then(() => {}). Adapter, readiness, and release callbacks accept their actual synchronous orPromiseLike<void>returns.Schema rejections are observed immediately. Failed builds wait for schema work to settle before releasing PostGraphile and the unique preset services. Cleanup attempts continue after individual release errors. A successful cleanup preserves the original build error; additional cleanup or reporting failures are aggregated with that error as the cause. This helper is limited to failed builds; external pool ownership, normal cache disposal, and realtime startup behavior remain unchanged.
The readiness coordinator, failed-build release helper, and ModuleConfigCache implementation live in
src/utils. The package entry continues to exportModuleConfigCacheandModuleConfigCacheOptions. The formergraphile-cache/module-config-cachesubpath has been removed.Generation-scoped disposal and drain, realtime subscription lifecycle changes, performance harness migration, and later memory/cache management are still pending. These lifecycle features are not implemented by the current diff and will be added only through subsequent review steps. The PR remains a Draft awaiting review of the current build-readiness increment.
The branch was independently based on main
735479ba289c73a1cafb3a7a3e38dfd9c9a9dda7. Current code validation on Node 24.19.0 / pnpm 10.34.5:git diff --checkpassed.unregistervariable.No database or real-service operations were used for local validation. The repository skips build/test CI jobs for Draft PRs; those skipped jobs are not a cloud validation pass.