Description
This is a legal statement in hibernate and eclipselink, but not in OpenJPA:
setup
<jar-file>file://${project.build.directory}</jar-file>
This will resolve to something like:
<jar-file>file:////home/user/git/apache/project/target/classes</jar-file>
Expected output
classes will be loaded
actual output
java.lang.IllegalArgumentException: The jar resource "file:////home/user/git/apache/project/target/classes" cannot be loaded
where to change
org/apache/openjpa/meta/AbstractCFMetaDataFactory.java:700
rmannibucau found this snippet which does not take directories into account:
for (Object obj : urls) { url = (URL) obj; clss = cparser.parseTypeNames(new URLMetaDataIterator (url)); List<String> newNames = Arrays.asList(clss); if (log.isTraceEnabled()) log.trace(_loc.get("scan-found-names", newNames, rsrc)); names.addAll(newNames); mapPersistentTypeNames(url, clss); }