Tyler Furman
Tyler Furman

Reputation: 41

SchemaSpy providing Graphviz errors/warnings

I am running SchemaSpy and am able to produce graphviz summaries, but receive two repeated errors/warnings. Here is a sample of the output from my run:

INFO  - Starting Main v6.2.2 on DESKTOP-43FMD5O with PID 17072 (C:\Users\TJF\Utils\SchemaSpy\schemaspy-6.2.2.jar started by TJF in C:\Users\TJF)
INFO  - The following profiles are active: default
INFO  - Found configuration file: C:\Users\TJF\Utils\SchemaSpy\config.file.txt
INFO  - Started Main in 1.595 seconds (JVM running for 2.174)
INFO  - Starting schema analysis
INFO  - Connected to Microsoft SQL Server - 12.00.5168
INFO  - Gathering schema details
Gathering schema details......(0sec)
Connecting relationships......(0sec)
Writing/graphing summary.INFO  - Gathered schema details in 0 seconds
INFO  - Writing/graphing summary
INFO  - Graphviz renderer set to ':cairo'
.ERROR - dot -Tpng:cairo relationships.real.compact.dot -orelationships.real.compact.png -Tcmapx: Warning: cell size too small for content
ERROR - dot -Tpng:cairo relationships.real.compact.dot -orelationships.real.compact.png -Tcmapx: Warning: cell size too small for content
ERROR - dot -Tpng:cairo relationships.real.compact.dot -orelationships.real.compact.png -Tcmapx: in label of node ValueEnumerationKey

The two messages I see repeatedly are:

I'm struggling to find documentation on how to resolve these issues and any help would be appreciated.

Haven't found any documentation to support these issues and unsure where to begin.

Upvotes: 3

Views: 1215

Answers (2)

Attila
Attila

Reputation: 1

I've had the same issue, for me, font size decrease solved the problem, I've added

-fontsize 9

to the command line argument list (decreasing it from the deafault 11, see https://schemaspy.readthedocs.io/en/latest/configuration/commandline.html#diagram-related) and it works fine for now.

Upvotes: 0

kacsta
kacsta

Reputation: 11

Been there, done that...

What I've learnt on my journey:

  • newer versions of SchemaSpy works better, pretty obvious, mine is schemaSpy_6.2.4
  • some Java version may not support Dot library (Dot missing or invalid version error) even if you installed it and added to the path. "JDK version 17 was not working for me. I had to install JDK 8" "Java removed the Javascript engine in Java 15 or 16. So 11 would have worked." ~from: https://github.com/schemaspy/schemaspy/issues/719
  • instead of Graphviz you can use vizjs, what is in my own experience more solid solution nowadays, had some problems with older Java versions, but with openJDK Java 17.0.1 everything works smooth and nice. To do that add -vizjs option
  • you'll need postgres jar also, mine is postgresql-42.2.10.jar
  • today was the first day for a long time I had no problems with generating diagrams (no missing tables, broken dependencies, glitching diagrams...), so improvment is visible. Want to support developers, come here! https://github.com/schemaspy/schemaspy

Working solution, with SchemaSpy 6.2.4, Java 17.0.1 and vizjs:

<path to java17.0.1 exe> -jar schemaSpy_6.2.4.jar -t pgsql -db <your db name> -host <postgres address with port, usually <host>:5432> -u <database user> -p <database password> -o <output directory> -dp <path to postgres jar> -s <your db schema> -vizjs

Upvotes: 1

Related Questions