This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 21103 - warpackager:error when view war content with some web module.
Summary: warpackager:error when view war content with some web module.
Status: CLOSED FIXED
Alias: None
Product: obsolete
Classification: Unclassified
Component: jarpackager (show other bugs)
Version: -FFJ-
Hardware: PC Windows ME/2000
: P3 blocker (vote)
Assignee: _ rkubacki
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-03-02 01:15 UTC by _ hlu
Modified: 2003-07-01 10:03 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
JAR packager patch to avoid adding duplicated entries (1.87 KB, patch)
2002-03-18 13:57 UTC, _ rkubacki
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description _ hlu 2002-03-02 01:15:05 UTC
ea build020301:
To reproduce:
Create a new web module.
Add a extra files: examples/advanced(this is from the sampledir) to WEB-
INF/classes
Turn on the include dependent files to true.
View war contents.
There is an error: 
org.netbeans.modules.web.war.packager.WarException:java.util.zip.ZipException:du
plicate entry:WEB-INF/classes/examples/advanced/MemoryView$6.class.
if I copy examples/advanced to the WEB-INF/classes directory, turn on the 
include dependent files to true, view war content works fine.
Comment 1 _ rkubacki 2002-03-05 09:11:28 UTC
If I understand well the problem occurs when you add some directory
such as examples/advanced and set its target directory to
WEB-INF/classes/examples/advanced and set include dependent files to
true. That's how I reproduced this.

I am not sure if this is common case so I suggest to dowgrade this to P3.

Technically: Extra files (content examples/advanced) are added to
archive as ArchiveMember elements before begining of packing. The
duplicates classes are also calculated before packing but they are
added later when ArchiveMembers are processed to ArchiveEntries as
ArchiveEntry objects so it is difficult to check all these object for
duplicities. I don't see any simple fix and I would like to avoid
risky patches.
Comment 2 _ rkubacki 2002-03-18 13:57:16 UTC
Created attachment 5076 [details]
JAR packager patch to avoid adding duplicated entries
Comment 3 _ rkubacki 2002-03-18 13:59:38 UTC
Roger, can you review attached patch and evaluate whether it can be
applied to jar packager? It seems to be very difficult to fix it
inside web module but this looks like possible solution (at least it
fixes this bug).
Comment 4 brinkley 2002-03-22 18:19:47 UTC
Fix looks good to me. I've integrated it into trunk and will try to
get it into Orion release.
Comment 5 _ rkubacki 2002-03-27 13:15:12 UTC
Commited into orion_fcs too.
Comment 6 David Kaspar 2002-04-22 14:24:13 UTC
Verified
Comment 7 Quality Engineering 2003-07-01 10:02:19 UTC
Resolved for 3.4 or earlier, no new info since then -> closing.
Comment 8 Quality Engineering 2003-07-01 10:03:07 UTC
Resolved for 3.4 or earlier, no new info since then -> closing.