fix(graphile): isolate plugin caches by owner - #1751
Draft
Zetazzz wants to merge 1 commit into
Draft
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.
Summary
Implements F08 from constructive-io/constructive-planning#1693 on top of the shared performance harness in #1716.
These changes prevent a long-lived plugin or preset instance from serving mutable discovery state produced by another build, tenant, or physical pool. Weak owner keys also allow cache state to be collected with its owner.
Contract changes
getLlmBillingConfignow requires an explicit cache owner; the metering plugin supplies its exact Graphile build.getLlmBillingCacheStatsreports one explicit owner's cache.bm25IndexStoreandbm25ExtensionDetectedare no longer exported. Callers that intentionally supply an external BM25 store may continue to use the existingcreateBm25Adapter({ bm25IndexStore })option.Boundary
This PR is intentionally limited to F08 cache ownership:
pgSettingschanges (F13)F08's retained-memory effect depends on which plugins are enabled, so this PR makes no isolated performance claim and does not add a benchmark arm before a representative multi-build fixture exists.
Validation
Passed:
scoreMetaKeywarning in graphile-search)git diff --checkKnown environment/baseline limitations:
permission denied for schema integration_test, the same repository fixture limitation documented in fix(graphile): qualify built-in plugin SQL #1748; its other six suites pass and the package builds successfully.Refs constructive-io/constructive-planning#1693.