[jbosstools-dev] JBIDE-2311 and Archives
Galder Zamarreno
galder.zamarreno at redhat.com
Tue Jun 10 09:11:31 EDT 2008
Hi Rob,
To get the fix for this, I need to get grab the latest nightly build,
correct? http://reports.qa.atl.jboss.com/binaries/RHDS/nightly/
If so, I'll download and try it once I'm back from hol next week.
Cheers,
Rob Stryker wrote:
> I thought I'd update on the state of archives as it relates to all these
> pesky NPE's floating around.
>
> This one actually wasn't caused by my poor VFS, but rather by the
> underlying library (truezip) and their VFS.
> Basically, without doing a huge deep deep dive into TrueZip, it seems
> very difficult to successfully ensure
> that, once inside an archive, you can be sure that some elements are
> treated as files and others as internal archives.
>
> I've fixed the bug, 2311, without regressing on jbide-2290 by checking
> first if the destination is inside something that's
> already zipped up. If it is, then I use a default "archive detector" to
> determine if my file is a nested zip or an exploded
> file inside a zip.
>
> The long and the short of it is that, without a much more in-depth model
> / xml file, there's going to be a
> difficult time with the use case shown below:
>
> /project
> |-dest
> |- zipped.war
> |- unzipped.jar
> |- someFile.txt
> |- src
> |- zipped.war (just a folder)
> |- unzipped.jar (also a folder)
> |- someFile.txt (plain file)
>
> fileset: /src/** -> /dest/zipped.war exploded=false
>
> In the above example, with the current code (post-patch), it is almost
> guaranteed that unzipped.jar
> will actually be zipped because the fileset itself does not give any
> advice on what to do with other
> elements below it that may have extensions that want to be zipped.
>
> I've got the unit tests in and a patch that fixes the two most egregious
> problems (jbide-2311 and jbide-2290).
> This issue has not been complained about yet by anyone, but I can
> already tell it will be a problem.
> I'll try to make a unit test for that next.
>
> - Rob Stryker
> _______________________________________________
> jbosstools-dev mailing list
> jbosstools-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/jbosstools-dev
--
Galder Zamarreño
Sr. Software Maintenance Engineer
JBoss, a division of Red Hat
More information about the jbosstools-dev
mailing list