尝试使用以下命令创建数据库方案ER图,但由于graphViz配置的某些问题而无法生成ER图。schemaSpy正在创建所有表的基于html的文件,并且在指定的输出目录中也成功创建了. dot文件。但这些. dot文件未转换为ER图,无法添加到. html中进行显示。
- 版本:**
- Java:v8
1.模式间谍:版本6.1.0
1.图形可视化:点阵图形可视化版本7.0.2(20221119.0110) - mysql:mysql-连接器-Java-8.0.30.jar
- 命令:**
java -jar .\schemaspy-6.1.0.jar -t mysql -dp C:\mysql-connector-java-8.0.30.jar -db datagenerator_poc -gv 'C:\Program Files (x86)\Graphviz' -host 127.0.0.1 -port 5000 -s mysql -u root -p staging123 -o /SchemaSpy
- 命令:**
- 日志**
SchemaSpy generates an HTML representation of a database schema's relationships.
SchemaSpy comes with ABSOLUTELY NO WARRANTY.
SchemaSpy is free software and can be redistributed under the conditions of LGPL version 3 or later.
http://www.gnu.org/licenses/
INFO - Starting Main v6.1.0 on DESKTOP-O4DE6AA with PID 10936 (C:\Users\Ascend\Desktop\ATS Codebase\demo\src\main\resources\lib\schemaspy-6.1.0.jar started by Ascend in C:\Users\Ascen
d\Desktop\ATS Codebase\demo\src\main\resources\lib)
INFO - The following profiles are active: default
INFO - Started Main in 1.314 seconds (JVM running for 1.814)
INFO - Starting schema analysis
INFO - Connected to MySQL - 8.0.31
INFO - Gathering schema details
Gathering schema details.........................................(34sec)
Connecting relationships.........................................(14sec)
Writing/graphing summary.INFO - Gathered schema details in 14 seconds
INFO - Writing/graphing summary
INFO - Graphviz rendered set to ''
..ERROR - RelationShipDiagramError
Failed to produce diagram for: \SchemaSpy\diagrams\summary\relationships.implied.compact.dot
ERROR - RelationShipDiagramError
Failed to produce diagram for: \SchemaSpy\diagrams\summary\relationships.implied.large.dot
.ERROR - Failed to produce diagram for: \SchemaSpy\diagrams\orphans\help_keyword.1degree.dot
Failed to generate Orphan diagram
ERROR - Failed to produce diagram for: \SchemaSpy\diagrams\orphans\help_relation.1degree.dot
Failed to generate Orphan diagram
ERROR - Failed to produce diagram for: \SchemaSpy\diagrams\orphans\plugin.1degree.dot
Failed to generate Orphan diagram
ERROR - Failed to produce diagram for: \SchemaSpy\diagrams\orphans\replication_group_configuration_version.1degree.dot
Failed to generate Orphan diagram
ERROR - Failed to produce diagram for: \SchemaSpy\diagrams\orphans\time_zone.1degree.dot
Failed to generate Orphan diagram
ERROR - Failed to produce diagram for: \SchemaSpy\diagrams\orphans\time_zone_leap_second.1degree.dot
Failed to generate Orphan diagram
ERROR - Failed to produce diagram for: \SchemaSpy\diagrams\orphans\time_zone_name.1degree.dot
Failed to generate Orphan diagram
.....(1sec)
Writing/diagramming detailsINFO - Completed summary in 1 seconds
INFO - Writing/diagramming details
..Exception in thread "main" java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:48)
at org.springframework.boot.loader.Launcher.launch(Launcher.java:87)
at org.springframework.boot.loader.Launcher.launch(Launcher.java:50)
at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:51)
Caused by: org.schemaspy.output.diagram.DiagramException: Failed to generate Table diagram
at org.schemaspy.output.diagram.DiagramFactory.generateTableDiagram(DiagramFactory.java:71)
at org.schemaspy.output.html.mustache.diagrams.MustacheDiagramFactory.generateTableDiagram(MustacheDiagramFactory.java:44)
at org.schemaspy.output.html.mustache.diagrams.MustacheTableDiagramFactory.generateTableDiagrams(MustacheTableDiagramFactory.java:80)
at org.schemaspy.SchemaAnalyzer.generateHtmlDoc(SchemaAnalyzer.java:426)
at org.schemaspy.SchemaAnalyzer.analyze(SchemaAnalyzer.java:260)
at org.schemaspy.SchemaAnalyzer.analyze(SchemaAnalyzer.java:123)
at org.schemaspy.cli.SchemaSpyRunner.runAnalyzer(SchemaSpyRunner.java:98)
at org.schemaspy.cli.SchemaSpyRunner.run(SchemaSpyRunner.java:87)
at org.schemaspy.Main.main(Main.java:55)
... 8 more
Caused by: org.schemaspy.output.diagram.DiagramException: Dot missing or invalid version
at org.schemaspy.output.diagram.graphviz.GraphvizDot.generateDiagram(GraphvizDot.java:193)
at
org.schemaspy.output.diagram.DiagramFactory.generateTableDiagram(DiagramFactory.java:68)
... 16 more
1条答案
按热度按时间efzxgjgh1#
请尝试下载graphviz-install-2.49.0 https://graphviz.org/download/