dari
dari copied to clipboard
ClassFinder.JAR_CLASS_NAMES should check Class-Path in a jar manifest
A jar manifest file has a Class-Path
entry which specifies class path items.
In ClassFinder
, when searching for a class, a jar
file is processed by com.psddev.dari.util.ClassFinder#JAR_CLASS_NAMES
cache builder. Now this builder doesn't take into account the Class-Path
entry which results in a bug - some classes get skipped.
Real world example
When running a test, if the classpath value is too long IntellijIdea creates a dedicated jar
file with only a manifest file whose Class-Path
entry contains that long classpath value. So when running tests from within intellij idea with a dari database for tests, an exception is raised, which wasn't obvious that the problem is with classpath.