Skip to content

docs(plan): can://<app>/java/… identity migration - #245

Open
rahlk wants to merge 1 commit into
mainfrom
feat/can-uri-app-outermost-plan
Open

docs(plan): can://<app>/java/… identity migration#245
rahlk wants to merge 1 commit into
mainfrom
feat/can-uri-app-outermost-plan

Conversation

@rahlk

@rahlk rahlk commented Sep 8, 2026

Copy link
Copy Markdown
Collaborator

Implementation plan for #244. Spec: codellm-devkit/.github#68.

Eight tasks, TDD, one commit each. The surface is smaller than the 180 can:// references suggest — ids are minted in exactly one class, so the code change is small and the fixture churn is the work.

The two non-obvious breakages, both of which compile fine and fail at runtime:

  • L2CallGraph.java:267 tests hint.startsWith(CanId.SCHEME) to decide "is this already an id?". With SCHEME no longer carrying the language, that keeps working — but only because Task 1 redefines SCHEME as "can://". Left alone it would silently stop recognising ids.
  • L3WalaOverlays.java:375 composes CanId.SCHEME + "/unknown" as a fallback application id.

One decision deferred to you (Task 7): whether the payload schema_version moves to 3.0.0. Leaving it at 2.0.0 makes an incompatible id change undetectable; moving it re-creates the unilateral drift #238 warned against, since the siblings stay at 2.0.0. The plan recommends moving the payload version and leaving the graph constant alone, and says to confirm before implementing rather than deciding it silently.

The migration note is the part most likely to bite. Old and new ids do not collide, so re-pushing an existing database yields a second disconnected copy, and the prefix-scoped delete cannot clean the old one because it scopes on the new prefix. Worse, pre-3.1.1 application roots have no id property at all, so neither prefix match reaches them — the plan carries all three Cypher statements.

Implementation plan for the spec at codellm-devkit/.github#68, scoped to
codeanalyzer-java and shipping in 3.1.1 per the maintainer's decision.

Eight tasks. The mint point is one class, so the code change is small; the work
is the two places that pattern-match the old language-first prefix
(L2CallGraph:267, L3WalaOverlays:375), the graph root's merge key, and 92 fixture
references.

Task 7 carries the one decision that is not mechanical: whether the payload
schema_version moves to 3.0.0. Leaving it at 2.0.0 makes an incompatible id
change undetectable; moving it re-creates the unilateral drift #238 warned
against. The plan recommends moving the payload version and leaving the graph
constant alone, and says to confirm before implementing.

Also records the operator migration the spec's section 5 identified: old and new
ids do not collide, so a re-push produces a second disconnected copy, and the
pre-3.1.1 application root has no id at all so neither prefix match reaches it.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant