Tool to remove unnecessary dependencies in a Java project

前端 未结 6 1223
逝去的感伤
逝去的感伤 2020-12-03 04:18

I have a Java project that currently has a lot of JARs in its libraries directory, which are all included in the resulting package when building. I know, however, that some

6条回答
  •  青春惊慌失措
    2020-12-03 04:55

    Beware of the case that a class is loaded via Class.forName() and not specified as a dependency in the manifest file (there is a Depends-On: attribute that is for that, but many people don't specify it, which breaks tools like this, the bane of my existence when I worked on such a tool).

提交回复
热议问题