{"record":{"id":"6bb508858003af24","repo":"hibernate/hibernate-orm","slug":"unable-to-create-archive-entry-uri-s-s","errorCode":null,"errorMessage":"Unable to create archive entry URI: %s - %s","messagePattern":"Unable to create archive entry URI: (.+?) - (.+?)","errorType":"exception","errorClass":"ArchiveException","httpStatus":null,"severity":"error","filePath":"hibernate-core/src/main/java/org/hibernate/boot/archive/internal/JarInputStreamBasedArchiveDescriptor.java","lineNumber":98,"sourceCode":"\t\t\t\t\t// This algorithm assumes that the zipped file is only the URL root (including entry), not\n\t\t\t\t\t// just any random entry\n\t\t\t\t\ttry {\n\t\t\t\t\t\tfinal JarInputStream subJarInputStream = new JarInputStream( jarInputStream );\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tZipEntry subZipEntry = jarInputStream.getNextEntry();\n\t\t\t\t\t\t\twhile (subZipEntry != null) {\n\t\t\t\t\t\t\t\tif ( ! subZipEntry.isDirectory() ) {\n\t\t\t\t\t\t\t\t\tfinal String subName = extractName( subZipEntry );\n\t\t\t\t\t\t\t\t\tfinal InputStreamAccess inputStreamAccess = buildByteBasedInputStreamAccess( subName, subJarInputStream );\n\n\t\t\t\t\t\t\t\t\tentryConsumer.accept( new ArchiveEntryImpl( subName, subName, new URI(archiveUrl + \"!/\" + subName), inputStreamAccess ) );\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\tsubZipEntry = jarInputStream.getNextJarEntry();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tcatch (URISyntaxException e) {\n\t\t\t\t\t\t\tthrow new ArchiveException(\n\t\t\t\t\t\t\t\t\tString.format( Locale.ROOT,\n\t\t\t\t\t\t\t\t\t\t\t\"Unable to create archive entry URI: %s - %s\",\n\t\t\t\t\t\t\t\t\t\t\tarchiveUrl,\n\t\t\t\t\t\t\t\t\t\t\tjarEntry.getName()\n\t\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\t\te\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tfinally {\n\t\t\t\t\t\t\tsubJarInputStream.close();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tcatch (ArchiveException e) {\n\t\t\t\t\t\tthrow e;\n\t\t\t\t\t}\n\t\t\t\t\tcatch (Exception e) {\n\t\t\t\t\t\tthrow new ArchiveException( \"Error accessing nested jar\", e );\n\t\t\t\t\t}","sourceCodeStart":80,"sourceCodeEnd":116,"githubUrl":"https://github.com/hibernate/hibernate-orm/blob/fad1729dce015f908198d57a8d80274a30f905a5/hibernate-core/src/main/java/org/hibernate/boot/archive/internal/JarInputStreamBasedArchiveDescriptor.java#L80-L116","documentation":"Thrown by JarInputStreamBasedArchiveDescriptor when a URI for an archive entry cannot be created while scanning a jar provided as an InputStream (URISyntaxException).","triggerScenarios":"Scanning a nested jar from an InputStream where an entry name or the base URI produces an invalid URI string.","commonSituations":"Nested jars (jar inside jar) whose entry names contain spaces or characters invalid in URIs.","solutions":["Remove spaces and special characters from entry and jar names inside nested archives.","Avoid nested-jar scanning by extracting the nested jar and referencing it directly."],"exampleFix":"The entry inside the jar input stream could not be turned into a URI. Make sure entry names in the jar are valid (no spaces or illegal URI characters) and that the base archive URL is well-formed.","handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"fad1729dce015f908198d57a8d80274a30f905a5","analyzedAt":"2026-08-22T04:13:57.527Z","schemaVersion":2},"datasetVersion":"2026-08-22T09:17:25.309Z"}