hibernate/hibernate-orm · error · ArchiveException
Unable to create archive entry URI: {}
Error message
Unable to create archive entry URI: {} What it means
Error "Unable to create archive entry URI: {}" thrown in hibernate/hibernate-orm.
Source
Thrown at hibernate-core/src/main/java/org/hibernate/boot/archive/internal/JarInputStreamBasedArchiveDescriptor.java:207
final String subName = extractName( subZipEntry );
if ( path.equals( subName ) ) {
return new ArchiveEntryImpl(
subName,
subName,
URI.create("jar:" + getArchiveUrl().toURI() + "!/" + subName),
buildByteBasedInputStreamAccess( subName, subJarInputStream )
);
}
}
subZipEntry = jarInputStream.getNextJarEntry();
}
}
finally {
subJarInputStream.close();
}
}
catch (URISyntaxException e) {
throw new ArchiveException( "Unable to create archive entry URI: " + jarEntryName, e );
}
catch (Exception e) {
throw new ArchiveException( "Error accessing nested jar", e );
}
}
else if ( path.equals( jarEntryName ) ) {
final String entryName = extractName( jarEntry );
final String relativeName = extractRelativeName( jarEntry );
try {
return new ArchiveEntryImpl(
entryName,
relativeName,
URI.create( "jar:" + getArchiveUrl().toURI() + "!/" + entryName ),
buildByteBasedInputStreamAccess( entryName, jarInputStream )
);
}
catch (URISyntaxException e) {View on GitHub (pinned to fad1729dce)
Solutions
- Ensure the archive path passed to Hibernate is a valid, existing jar or exploded directory path; a malformed file path produces an illegal URI.
- Check that the URL/URL protocol for the archive location (e.g. file:, jar:) is supported by the ArchiveDescriptorFactory; register a custom ArchiveDescriptorFactory if the location is non-standard.
- Verify file permissions and that the path contains no illegal characters (spaces or special characters that are not URL-encoded).
When it happens
Trigger: Hibernate cannot construct a URI for an entry inside a JAR archive during classpath scanning.
Common situations: Persistence units pointing at nested jars or exploded archives with unusual layouts, e.g. <jar-file/> references or jars inside EARs.
AI-assisted analysis of hibernate/hibernate-orm@fad1729dce (2026-08-22).
Data as JSON: /api/errors/9aba9758a44d7099.
Report an issue: GitHub.