[jboss-jira] [JBoss JIRA] (AS7-4553) Error during VFS get virtual file

Zhang Lan (JIRA) jira-events at lists.jboss.org
Thu Apr 19 00:03:18 EDT 2012


     [ https://issues.jboss.org/browse/AS7-4553?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Zhang Lan updated AS7-4553:
---------------------------

    Description: 
I have a jar file ,in which have "seam.properties" to load the seam components in it.
I put the jar file as a module.
But I got the following error when I start jboss.

java.lang.IllegalArgumentException: Null path		
        at org.jboss.vfs.VFS.getChild(VFS.java:187) [jboss-vfs-3.1.0.Final.jar:3.1.0.Final]		
        at org.jboss.vfs.VFS.getChild(VFS.java:173) [jboss-vfs-3.1.0.Final.jar:3.1.0.Final]		
        at org.jboss.vfs.VFS.getChild(VFS.java:154) [jboss-vfs-3.1.0.Final.jar:3.1.0.Final]		
        at org.jboss.seam.integration.jbossas.vfs.VFSScanner.getRoot(VFSScanner.java:36) [jboss-seam-int.jar:6.0.0.GA]

VFS.java:187 is following source.
   return getChild(uri.getPath());

But in my case ,the uri pattern is create by org.jboss.modules.JarFileResourceLoader#getJarURI use the following method.
   return new URI("jar", b.toString(), null);

It is the [scheme:]scheme-specific-part[\#fragment] pattern 's URI.it's path is null.
So when I change the VFS.java:187 to the following ,my problem is ok.IT's a bug?

public static VirtualFile getChild(URI uri) {
    if(uri.getPath() != null){
      return getChild(uri.getPath());
    }else{
      return getChild(uri.getSchemeSpecificPart());
    }
}


  was:
I have a jar file ,in which have "seam.properties" to load the seam components in it.
I put the jar file as a module.
But I got the following error when I start jboss.

java.lang.IllegalArgumentException: Null path		
        at org.jboss.vfs.VFS.getChild(VFS.java:187) [jboss-vfs-3.1.0.Final.jar:3.1.0.Final]		
        at org.jboss.vfs.VFS.getChild(VFS.java:173) [jboss-vfs-3.1.0.Final.jar:3.1.0.Final]		
        at org.jboss.vfs.VFS.getChild(VFS.java:154) [jboss-vfs-3.1.0.Final.jar:3.1.0.Final]		
        at org.jboss.seam.integration.jbossas.vfs.VFSScanner.getRoot(VFSScanner.java:36) [jboss-seam-int.jar:6.0.0.GA]

VFS.java:187 is following source.
   return getChild(uri.getPath());

But in my case ,the uri pattern is create by org.jboss.modules.JarFileResourceLoader#getJarURI use the following method.
   return new URI("jar", b.toString(), null);

It is the [scheme:]scheme-specific-part[#fragment] pattern 's URI.it's path is null.
So when I change the VFS.java:187 to the following ,my problem is ok.IT's a bug?

public static VirtualFile getChild(URI uri) {
    if(uri.getPath() != null){
      return getChild(uri.getPath());
    }else{
      return getChild(uri.getSchemeSpecificPart());
    }
}



    
> Error during VFS get virtual file
> ---------------------------------
>
>                 Key: AS7-4553
>                 URL: https://issues.jboss.org/browse/AS7-4553
>             Project: Application Server 7
>          Issue Type: Bug
>          Components: VFS
>    Affects Versions: 7.1.0.Final
>            Reporter: Zhang Lan
>            Assignee: John Bailey
>              Labels: jboss
>
> I have a jar file ,in which have "seam.properties" to load the seam components in it.
> I put the jar file as a module.
> But I got the following error when I start jboss.
> java.lang.IllegalArgumentException: Null path		
>         at org.jboss.vfs.VFS.getChild(VFS.java:187) [jboss-vfs-3.1.0.Final.jar:3.1.0.Final]		
>         at org.jboss.vfs.VFS.getChild(VFS.java:173) [jboss-vfs-3.1.0.Final.jar:3.1.0.Final]		
>         at org.jboss.vfs.VFS.getChild(VFS.java:154) [jboss-vfs-3.1.0.Final.jar:3.1.0.Final]		
>         at org.jboss.seam.integration.jbossas.vfs.VFSScanner.getRoot(VFSScanner.java:36) [jboss-seam-int.jar:6.0.0.GA]
> VFS.java:187 is following source.
>    return getChild(uri.getPath());
> But in my case ,the uri pattern is create by org.jboss.modules.JarFileResourceLoader#getJarURI use the following method.
>    return new URI("jar", b.toString(), null);
> It is the [scheme:]scheme-specific-part[\#fragment] pattern 's URI.it's path is null.
> So when I change the VFS.java:187 to the following ,my problem is ok.IT's a bug?
> public static VirtualFile getChild(URI uri) {
>     if(uri.getPath() != null){
>       return getChild(uri.getPath());
>     }else{
>       return getChild(uri.getSchemeSpecificPart());
>     }
> }

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the jboss-jira mailing list