-
1. Re: how to retrieve the metadata in nest jar by vfs interface
bondchan921 Nov 26, 2012 12:19 AM (in response to bondchan921)can anybody give a hint ?
-
2. Re: how to retrieve the metadata in nest jar by vfs interface
bondchan921 Nov 26, 2012 12:21 AM (in response to bondchan921)I also try to get all the children by call vfs.getChildrenRecursively(), and then traverse the returnlist, if the item is end with jar/, I call newVFS.getChildrenRecursively(), but only the 1st level of children return
-
3. Re: how to retrieve the metadata in nest jar by vfs interface
alesj Nov 26, 2012 6:02 AM (in response to bondchan921)What's the root of your lookup?
Can you paste some code you use to do this.
//vfs is point to a.jar ---> where you actually have a.sar
-
4. Re: how to retrieve the metadata in nest jar by vfs interface
bondchan921 Nov 30, 2012 1:17 AM (in response to alesj)our app need to support jboss 4.2.3 and jboss 5.1.0, due to the Mbean MainDeployer.listDeployed() return null in jboss 5.1.2, so I call MainDeployer.getKernelMainDeployer().getTopLevel(), returns the Collection of Deployment instances(all the deployments including our app jars/sars/wars),
for echo instances{
Deployment de = (Deployment)object
moduleMetaDataRet.setDeployName(de.getName(), object, null));
URL deployURL = new URL(moduleMetaDataRet.getDeployName());
VFSContextFactoryLocator vfsCFL = new VFSContextFactoryLocator();
VFSContextFactory vfsCF = vfsCFL.getFactory(deployURL);
VFSContext vfsContext = vfsCF.getVFS(deployURL);
VFS vfs = new VFS(vfsContext);
vfs.getChildrenRecursively("xyz.xm") can't get the a.sar/b.jar/Meta-Info/xyz.xml
}
-
5. Re: how to retrieve the metadata in nest jar by vfs interface
alesj Nov 30, 2012 1:49 AM (in response to bondchan921)Uh, you're definitely using too much impl details with that code.
Try casting the deployment into VFSDeployment, that should have getRoot method on it, which you can then use.
-
6. Re: how to retrieve the metadata in nest jar by vfs interface
bondchan921 Dec 3, 2012 1:47 AM (in response to alesj)yeah, that's true, and my problem is can't retriving the metadata of the nest jar
Suppose the root is zipfile:/a.sar/, then how can I get the metadata: a.sar/b.jar/Meta-Info/xyz.xml ?