docs(spec): Java config-read edges and the entrypoint report - #63
Merged
Conversation
Design record for codeanalyzer-java#231, goals 1 and 2.
Adds `application.config_uses[]`, `application.config_reads_unresolved[]` and
`application.entrypoint_report{}` to `analysis.json`, plus `J_USES_CONFIG`,
`J_READS_CONFIG_UNRESOLVED` and two `:JApplication` properties to the Neo4j
projection.
Two deliberate divergences from codeanalyzer-python, both recorded with their
cost: `src` widens to the annotated element (Java's dominant config-read idiom
is `@Value`, which has no call site to anchor on), and the literal tier runs at
L1 rather than L2 (Java's call body nodes already carry the argument text).
Closes out #231's third goal by fact rather than by work: codeanalyzer-python
does not project comment nodes either — it collapses them to a `docstring`
property, exactly as Java does — so there is no parity gap and no term to match.
The graph contract stays at 2.0.0; a re-baseline is #50's decision.
… settled Three amendments, all bringing the spec in line with what shipped. D6 states the resolution rule the spec never had: one `J_USES_CONFIG` edge per matching declared key, unresolved only when zero match. The tracking issue's first draft said "exactly one", which is wrong — a key legitimately appears in both application.properties and application-dev.properties, and a `@ConfigurationProperties` prefix claims every key beneath it by design, so a uniqueness rule would drop both on the floor. D1 gains the two shapes it left open: an unresolved annotation read ghosts the annotation type, and a prefix binding emits one edge per declared key beneath it. D3 replaces the one-line dataflow sketch with the two tiers as built, plus the three refusals that make them safe — including why the `ssa` filter is what keeps `-a 3` a subset of `-a 4`. D5a records the decision behind `frameworks_detected`: attribution lives on the node, because a warm cache skips the build entirely and a tally kept during the walk would under-report exactly the empty this record exists to prevent. D5's `unresolved`/`errors` description is corrected to what the code does, with the ceiling named. Also: the decomposition table now carries the filed issue and PR numbers and the branch stacking, and the verification section says what the corpus runs can and cannot prove.
Contributor
Author
|
Pushed 487c056 — the spec now states the resolution rule and records what implementation settled. One correction to my own earlier note: the "exactly one declared key" wording was never in this spec. It was in codeanalyzer-java#232's Goals checkbox, which I have also corrected. The spec's gap was different and worse — it never stated the resolution rule at all, so "exactly one" was a reasonable reading of the silence.
|
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.
Design record for the epic in #62, covering codeanalyzer-java#231 goals 1 and 2.
Adds
application.config_uses[],application.config_reads_unresolved[]andapplication.entrypoint_report{}toanalysis.json, plusJ_USES_CONFIG,J_READS_CONFIG_UNRESOLVEDand two:JApplicationproperties to the Neo4j projection.Two deliberate divergences from codeanalyzer-python, each recorded with its cost:
srcwidens to the annotated element (Java's dominant config-read idiom is@Value, which has no call site to anchor on), and the literal tier runs at L1 rather than L2 (Java's call body nodes already carry the argument text).#231's third goal is closed by fact rather than by work: codeanalyzer-python does not project comment nodes either — it collapses them to a
docstringproperty, exactly as Java does — so there is no parity gap and no term to match.The graph contract stays at 2.0.0; a re-baseline is #50's decision, and the spec records what that costs a consumer in the meantime.