You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Tim Ellison (JIRA)" <ji...@apache.org> on 2009/05/22 22:00:45 UTC
[jira] Resolved: (HARMONY-6074) [classlib][luni] JAR referenced in
a JAR's manifest 'Class-Path' that contains 'file' scheme URIs aren't
loaded
[ https://issues.apache.org/jira/browse/HARMONY-6074?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Tim Ellison resolved HARMONY-6074.
----------------------------------
Resolution: Fixed
Applied Sean's v2 fix to LUNI module at repo revision r777687.
Nathan, can you retry the failing app to verify this fix?
> [classlib][luni] JAR referenced in a JAR's manifest 'Class-Path' that contains 'file' scheme URIs aren't loaded
> ---------------------------------------------------------------------------------------------------------------
>
> Key: HARMONY-6074
> URL: https://issues.apache.org/jira/browse/HARMONY-6074
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Affects Versions: 5.0M8
> Reporter: Nathan Beyer
> Assignee: Nathan Beyer
> Fix For: 5.0M9
>
> Attachments: HARMONY-6074-V2.diff, HARMONY-6074.diff
>
> Original Estimate: 24h
> Remaining Estimate: 24h
>
> I ran into this while running Abdera's Maven build with the Harmony trunk. Surefire, the Maven plugin that invokes unit tests, when forked (default) creates an empty JAR file with a manifest like this.
> Manifest-Version: 1.0
> Main-Class: org.apache.maven.surefire.booter.SurefireBooter
> Class-Path: file:/C:/Users/nathan/.m2/repository/org/apache/maven/surefi
> re/surefire-booter/2.4.2/surefire-booter-2.4.2.jar file:/C:/Users/natha
> n/.m2/repository/org/apache/maven/surefire/surefire-api/2.4.2/surefire-
> api-2.4.2.jar file:/C:/dev/abdera/dependencies/i18n/target/test-classes
> / file:/C:/dev/abdera/dependencies/i18n/target/classes/ file:/C:/Users/
> nathan/.m2/repository/junit/junit/4.3/junit-4.3.jar file:/C:/Users/nath
> an/.m2/repository/org/apache/geronimo/specs/geronimo-activation_1.0.2_s
> pec/1.1/geronimo-activation_1.0.2_spec-1.1.jar
> When invoked, the Harmony JRE throws the following exception.
> Uncaught exception in main:
> java.lang.ClassNotFoundException: org.apache.maven.surefire.booter.SurefireBooter
> at java.net.URLClassLoader.findClass(URLClassLoader.java:892)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:489)
> at java.lang.ClassLoader$SystemClassLoader.loadClass(ClassLoader.java:871)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:268)
> at org.apache.harmony.vm.JarRunner.main(JarRunner.java:72)
> I did some debugging it seems the source of the issue is in the java.net.URLClassLoader in the method 'getInternalURLs(URL,String)'. While looping over the values in 'Class-Path', new URLs are created, but they're always created relative to the base JAR, even though the URI entry is absolute.
> I need to read over the manifest specification and make sure that absolute URIs should be treated differently. Regardless, the Sun RI seems to support this capability.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.