Ant task for generating ER diagram from JPA/Hibernate annotated classes

廉价感情. 提交于 2020-01-02 02:11:11

问题


Does anyone know of a tool that can do that?

Linguine maps seems to only work on old hibernate xml files. And the hibernate tool task hbm2hbmxml seems to have a bug so that I can't do the two step process "annotations->hbmxml->diagram"

Best, Anders


回答1:


Not quite what you're looking for but you could use API Viz which automatically produces UML like diagrams from class hierarchies and can be augmented with doclet tags.

You'd have to mark up your classes a little, but it's a great tool and worth using wherever you're trying to visualise large or complex projects.




回答2:


Hmm, I've found this great post on developerworks. There the author seems to generate entity diagrams from a live database. I wonder if I can go "annotated classes -> live db (eg. H2) -> SchemasSpy generated diagram?

And yes, API Viz looks great.

I've blogged my hacky solution with SchemaSpy.



来源:https://stackoverflow.com/questions/1017997/ant-task-for-generating-er-diagram-from-jpa-hibernate-annotated-classes

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!