Skip to content

Releases: ekalinin/gopuml

Release list

v0.2.0

Choose a tag to compare

@github-actions github-actions released this 24 Oct 18:59
a21e6ba

gopuml v0.2.0

The second release of gopuml, a Go reimplementation of
PlantUML v1.2026.9 (MIT variant). It reads the same
diagram language and produces the same SVG, PNG and text output, as a command
line that replaces java -jar plantuml.jar, a Go library, an HTTP server and
a WebAssembly module. No JVM is needed.

Changes since v0.1.0

  • Upstream target: PlantUML v1.2026.9 instead of v1.2026.8, with its style
    engine and the changes of its sequence, class, state and activity diagrams
    and of its preprocessor (include selectors such as file!1, !import of
    zip archives, !include_once reporting a file already included)
  • Packet diagrams (@startpacketdiag), in SVG and PNG. They do not need
    Graphviz, so they also render in the WebAssembly module
  • The standard library of upstream v1.2026.9 is bundled: !include <lib/path>,
    -stdlib, %get_stdlib, %get_all_stdlib, %load_json("<lib/file.json>")
    and !theme name from <lib/dir> read it
  • Sprites are drawn: monochrome, color, image and SVG sprites defined in a
    diagram, and the sprites and images of the standard library
  • The WebAssembly module embeds the standard library too, and a files value
    may also be a Uint8Array, so that a zip archive can be given to !import
  • The WebAssembly archive contains LICENSE and NOTICE, and NOTICE lists
    the licenses of the linked Go code

Supported diagrams and formats

Diagram type SVG PNG TXT / UTXT
Sequence yes yes yes
Class and object yes (needs dot) yes (needs dot) no
Use case, component and deployment yes (needs dot) yes (needs dot) no
State yes (needs dot) yes (needs dot) no
Activity (new syntax) yes yes no
Activity (legacy syntax) yes (needs dot) yes (needs dot) no
Packet yes yes no

The preprocessor (!include, !define, functions, all 74 builtins, JSON),
themes, skin parameters, styles and creole are supported, including diagrams
embedded in text with {{ ... }}, and so is the PREPROC output
(--preproc).

The standard library of upstream v1.2026.9 is bundled (!include <C4/C4_Container>, !include <awslib/AWSCommon> and the other libraries that
plantuml -stdlib lists), apart from nine libraries whose license could not
be verified or does not allow bundling them (see NOTICE).

Not supported yet

Other diagram types (archimate, timing, gantt, mindmap, and so on) are
reported with an explicit "... diagrams are not supported yet" error image
instead of a wrong drawing. Command line flags that this implementation does
not provide (for example --pdf) are rejected with exit status 1.

The internal sprites of the jar (the archimate icons) and the drawing of
OpenIconic icons and emoji are not included yet.

Graphviz

Class, object, use case, component, deployment, state and legacy activity
diagrams are laid out by Graphviz dot, as upstream does, so dot must be
installed for them. Sequence diagrams, activity diagrams in the new syntax
and packet diagrams do not need it. The WebAssembly module has no Graphviz:
it reports that graph layout is not available for the diagram types that
need it.

Conformance

make conformance REQUIRE=all compares this release with upstream PlantUML
v1.2026.9 on 686 cases (upstream's Vega test corpus plus curated cases):

  • 594 cases pass
  • 42 cases are documented known differences
    (testdata/conformance/known-differences.yaml)
  • 50 cases are diagram types that are not supported yet
  • 0 cases fail

Comparison with upstream

make bench runs the command line of this release and the upstream jar on
the same machine, with the same dot for both. The start time is the median
time of separate processes that each render a small sequence diagram with
-tsvg -pipe. The rendering time of a diagram type is the median time of one
process that renders the curated conformance cases of that type with
-tsvg -o <dir>; both use their default of one thread per processor. The
numbers depend on the machine.

PlantUML 1.2026.9 (Java) gopuml
Start time (one small sequence diagram) 698 ms 15 ms
Rendering: sequence (84 cases) 936 ms (11 ms per case) 120 ms (1.4 ms per case)
Rendering: class (23 cases) 883 ms (38 ms per case) 97 ms (4.2 ms per case)
Rendering: description (16 cases) 1.02 s (63 ms per case) 142 ms (8.9 ms per case)
Rendering: state (21 cases) 883 ms (42 ms per case) 138 ms (6.6 ms per case)
Rendering: activity (29 cases) 860 ms (30 ms per case) 108 ms (3.7 ms per case)
  • Machine: darwin/arm64, Apple M3 Pro, 12 CPUs
  • Java: openjdk version "25.0.4.1" 2026-08-18 LTS
  • Go: go1.27.1
  • Graphviz: dot - graphviz version 15.0.0 (20260523.1842)
  • Runs: median of 10 start runs and of 5 rendering runs per type

Some curated cases are errors by design (for example syntax errors, a failing
assertion, a missing include or library, an unknown theme, a transition out
of a region) or have no diagram: both implementations report the same cases
and exit with status 200.

Installation

Each archive of the command line (gopuml_0.2.0_<os>_<arch>.tar.gz, .zip
on windows) contains the plantuml binary, LICENSE, NOTICE and
README.md. gopuml_0.2.0_wasm.tar.gz contains plantuml.wasm,
wasm_exec.js, plantuml.mjs, LICENSE and NOTICE. checksums.txt has
the SHA-256 of every archive:

shasum -a 256 --ignore-missing -c checksums.txt   # sha256sum on linux
tar xzf gopuml_0.2.0_darwin_arm64.tar.gz plantuml
./plantuml --version   # gopuml v0.2.0 (PlantUML 1.2026.9 compatible)

The macOS binaries are not signed. When a browser downloaded the archive,
macOS blocks the binary until its quarantine attribute is removed:

xattr -d com.apple.quarantine plantuml

With Go 1.26 or later:

go install github.com/ekalinin/gopuml/cmd/plantuml@v0.2.0

v0.1.0

Choose a tag to compare

@github-actions github-actions released this 22 Oct 11:12
90bef41

gopuml v0.1.0

The first release of gopuml, a Go reimplementation of
PlantUML v1.2026.8 (MIT variant). It reads the same
diagram language and produces the same SVG, PNG and text output, as a command
line that replaces java -jar plantuml.jar, a Go library, an HTTP server and
a WebAssembly module. No JVM is needed.

Supported diagrams and formats

Diagram type SVG PNG TXT / UTXT
Sequence yes yes yes
Class and object yes (needs dot) yes (needs dot) no
Use case, component and deployment yes (needs dot) yes (needs dot) no
State yes (needs dot) yes (needs dot) no
Activity (new syntax) yes yes no
Activity (legacy syntax) yes (needs dot) yes (needs dot) no

The preprocessor (!include, !define, functions, all 74 builtins, JSON),
themes, skin parameters, styles and creole are supported, including diagrams
embedded in text with {{ ... }}, and so is the PREPROC output
(--preproc).

Not supported yet

Other diagram types (archimate, timing, gantt, mindmap, and so on) are
reported with an explicit "... diagrams are not supported yet" error image
instead of a wrong drawing. Command line flags that this implementation does
not provide (for example --pdf) are rejected with exit status 1.

Graphviz

Class, object, use case, component, deployment, state and legacy activity
diagrams are laid out by Graphviz dot, as upstream does, so dot must be
installed for them. Sequence diagrams and activity diagrams in the new syntax
do not need it. The WebAssembly module has no Graphviz: it reports that graph
layout is not available for the diagram types that need it.

Conformance

make conformance REQUIRE=all compares this release with upstream PlantUML
v1.2026.8 on 502 cases (upstream's Vega test corpus plus curated cases):

  • 372 cases pass
  • 25 cases are documented known differences
    (testdata/conformance/known-differences.yaml)
  • 105 cases are diagram types that are not supported yet
  • 0 cases fail

Comparison with upstream

make bench runs the command line of this release and the upstream jar on
the same machine, with the same dot for both. The start time is the median
time of separate processes that each render a small sequence diagram with
-tsvg -pipe. The rendering time of a diagram type is the median time of one
process that renders the curated conformance cases of that type with
-tsvg -o <dir>; both use their default of one thread per processor. The
numbers depend on the machine.

PlantUML 1.2026.8 (Java) gopuml
Start time (one small sequence diagram) 721 ms 18 ms
Rendering: sequence (53 cases) 897 ms (17 ms per case) 86 ms (1.6 ms per case)
Rendering: class (19 cases) 959 ms (50 ms per case) 110 ms (5.8 ms per case)
Rendering: description (12 cases) 869 ms (72 ms per case) 105 ms (8.8 ms per case)
Rendering: state (19 cases) 934 ms (49 ms per case) 147 ms (7.8 ms per case)
Rendering: activity (24 cases) 895 ms (37 ms per case) 107 ms (4.5 ms per case)
  • Machine: darwin/arm64, Apple M3 Pro, 12 CPUs
  • Java: openjdk version "25.0.4.1" 2026-08-18 LTS
  • Go: go1.27.1
  • Graphviz: dot - graphviz version 15.0.0 (20260523.1842)
  • Runs: median of 10 start runs and of 5 rendering runs per type

Some curated cases are errors by design (syntax errors, a failing assertion,
a missing include, an unknown theme, a transition out of a region) or have no
diagram: both implementations report the same cases and exit with status 200.
The jar also fails on preprocessor/layout-pragma-elk, because the MIT
variant has no ELK layout.

Installation

Each archive of the command line (gopuml_0.1.0_<os>_<arch>.tar.gz, .zip
on windows) contains the plantuml binary, LICENSE, NOTICE and
README.md. gopuml_0.1.0_wasm.tar.gz contains plantuml.wasm,
wasm_exec.js and plantuml.mjs. checksums.txt has the SHA-256 of every
archive:

shasum -a 256 --ignore-missing -c checksums.txt   # sha256sum on linux
tar xzf gopuml_0.1.0_darwin_arm64.tar.gz plantuml
./plantuml --version   # gopuml v0.1.0 (PlantUML 1.2026.8 compatible)

The macOS binaries are not signed. When a browser downloaded the archive,
macOS blocks the binary until its quarantine attribute is removed:

xattr -d com.apple.quarantine plantuml

With Go 1.26 or later:

go install github.com/ekalinin/gopuml/cmd/plantuml@v0.1.0