Skip to content

feat(elk-server): rebuilt from its recovered source on ELK 0.10.0, elkjs pinned to match - #110

Merged
endrix merged 2 commits into
mainfrom
feat/elk-server-0.9
Oct 30, 2026
Merged

endrix merged 2 commits into
mainfrom
feat/elk-server-0.9

Conversation

@endrix

@endrix endrix commented Oct 30, 2026 •

Copy link
Copy Markdown
Owner

The Java ELK server bundled ELK 0.8.1 while elkjs was 0.9.3, and the two engines laid some graphs out differently. A diagram could therefore reshuffle its nodes as it grew past the size where layouts move to the server (tracker m1-19).

The source. Only the jar had ever been committed: here, in mlir-viewer, and in ascpp-graph-sprotty, where af9cc65 added the gzip framing.

  • Its six classes (io.typefox.elkserver) are recovered with CFR 0.152 into elk-server/, a Maven project (mvn package).
  • The logic, wire format and log lines are as the jar had them. That includes the gzip-framed socket mode: GZ10, a 4-byte big-endian length, then a gzip body, in both directions.
  • Check: built on ELK 0.8.1, the rebuild lays out the graphs the platform builds for six real documents identically to the 0.2.0 jar, through the platform's own framed client. The six are a chain whose every id holds braces, two grouped specification documents, a 148-node document, and two HDL modules.

The licence. The server stays under the Eclipse Public License 2.0 only, like ELK, and not the GPL secondary licence the rest of the repository is also offered under. elk-server/LICENSE holds the text, every source file carries SPDX-License-Identifier: EPL-2.0, the pom declares the licence, and the build puts it in the jar at META-INF/elk-server/LICENSE, next to the bundled libraries' own notices.

The ELK version. No ELK release matches elkjs 0.9.3:

Pair Result on the six documents
ELK 0.9.1 jar, elkjs 0.9.3 2 differ
ELK 0.10.0 jar, elkjs 0.9.3 1 differs
ELK 0.9.1 jar, elkjs 0.9.1 2 differ
ELK 0.10.0 jar, elkjs 0.10.0 all 6 identical, node for node and route for route

So the jar is built on ELK 0.10.0 (elk-server-0.3.0-all.jar), and elkjs is pinned to exactly 0.10.0, since a later patch release isn't known to match. SwitchingElk takes elkjs 0.10's generic layout signature.

The guard. test/elk-server-parity.test.ts lays out the graphs the platform builds for two real documents on both engines and requires them to match. The two are a grouped specification document and an HDL module, the two that told the engines apart; they are fixtures under test/fixtures/elk-parity/, with outline, panel text and paths trimmed. The test fails against the old jar, so raising elkjs without rebuilding the jar on the same ELK fails CI.

What changes for users and products

  • Small layouts move a little, since elkjs changes from 0.9.3 to 0.10.0. Rendered with the headless renderer, picorv32's trap.md lays out differently but cleanly.
  • ELK 0.10 is built for Java 17, so the server now needs Java 17 or later. Without it, layouts stay on elkjs as before. The jar tests skip below Java 17, judged from the Java the process would actually use.
  • Products must copy and name elk-server-0.3.0-all.jar. PRs for ndf-ide, sv-ide and vhdl-ide follow and should merge after this one.

Gates. npm run build and check:neutrality pass, and every test passes except the variant wizard's 5-second timeouts, which time out the same way on unchanged main on this machine (load).

https://claude.ai/code/session_01E8WfqKknDNN6xpNVcJL5K8

…kjs pinned to match

The Java ELK server bundled ELK 0.8.1 while elkjs was 0.9.3, and the two
laid some graphs out differently: a graph moved its nodes as it grew past
the size where layouts go to the server.

- Source: only the jar had ever been committed. Its six classes are
  recovered with CFR into `elk-server/` (Maven, `mvn package`), logic, wire
  format and log lines unchanged: the gzip-framed socket mode (`GZ10`, a
  4-byte length, gzip body, both ways) included. Built on ELK 0.8.1, the
  rebuild lays out six real documents identically to the 0.2.0 jar through
  the platform's framed client.
- ELK: no ELK release matches elkjs 0.9.3 (0.9.1 and 0.10.0 each differ on
  some graphs), but ELK 0.10.0 and elkjs 0.10.0 lay every graph tried out
  alike, node for node and route for route. The jar is built on ELK 0.10.0
  (`elk-server-0.3.0-all.jar`) and elkjs is pinned to exactly 0.10.0.
  `SwitchingElk` takes elkjs 0.10's generic `layout` signature.
- `test/elk-server-parity.test.ts` lays out the graphs the platform builds
  for two real documents (a grouped specification document and an HDL
  module, the two that told the engines apart) on both engines and requires
  them to match; it fails against the old jar.
- ELK 0.10 is built for Java 17: the jar tests skip below it (as the
  process would pick its Java), and the start failure says Java 17.

Products must copy and name `elk-server-0.3.0-all.jar`.

Claude-Session: https://claude.ai/code/session_01E8WfqKknDNN6xpNVcJL5K8
The server is under the Eclipse Public License 2.0 only, like ELK and the
server it was recovered from, not the GPL secondary licence the rest of the
repository is also offered under. elk-server/LICENSE holds the text, every
source file carries SPDX-License-Identifier: EPL-2.0, the pom declares it,
and the build puts the licence in the jar at META-INF/elk-server/LICENSE
(Bundle-License: EPL-2.0 in the manifest), beside the bundled libraries' own
notices. The rebuilt jar lays out the same; the jar README's checksum moves.

Claude-Session: https://claude.ai/code/session_01E8WfqKknDNN6xpNVcJL5K8
@endrix
endrix merged commit ab6f1ff into main Oct 30, 2026
1 check passed
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