|
I have attached a project that generates a faulty war-file. To re-produce the problem <dependency> 3. Run maven war:war The new war-file contains duplicated Class-Path entries (my faulty war-file is included in the attached file) – Jöran Turns out I couldn't reproduce it because I wasn't updating a source file I'm not sure that it is a good idea to remove the update attribute, because if your application server uses this war (during the dev), I'm not sure that you can replace it. Arnaud, I was wondering if the update=true was there for some reason (as all other plugins like jar, ear, rar and ejb didn't set it), now I got the answer Anyway, if that's the case, it's just a matter of adding a new property (something like maven.war.update), which by default should be false (that would break backward compatibility, but I think the expected behaviour is always to create a fresh archive). – Felipe PS: again, I think it's important for the archive plugins (jar, war, ejb, ear, etc..) to be consistent, so if we add this property here we should add it to the others as well |
|||||||||||||||||||||||||||||||||||||||||
Joran,
Could you please write a simple test-case for this issue (i.e., a simple project.xml whose consecutive calls to maven war:war generates the invalid war)? I've tried to reproduce it, but the error didn't happens...
Anyway, I think the fix is essy, it's just a matter of removing the 'update=true' attribute from <ant:jar>:
<ant:jar
destfile="${maven.war.build.dir}/${maven.war.final.name}"
basedir="${maven.war.webapp.dir}"
update="true"
index="${maven.war.index}">
– Felipe