web.xml is now optional in Java EE. I've tweaked <war> to warn but continue if it is omitted, and not to say anything if there is a duplicate reference to the same web.xml, but to complain a lot if there are two conflicting ones (with diagnostics).
We may want to have an attribute to indicate that a web.xml file is needed, or that we dont want to see the warning message. Say nowebxml="fail", "warn" or "skip", with the default being fail for backwards compatibility. Thoughts? Now is the time to add it...
git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@468180 13f79535-47bb-0310-9956-ffa450edef68
@@ -33,7 +33,20 @@ treatment for files that should end up in the
<p>(The War task is a shortcut for specifying the particular layout of a WAR file.
The same thing can be accomplished by using the <i>prefix</i> and <i>fullpath</i>
attributes of zipfilesets in a Zip or Jar task.)</p>
<p>The extended zipfileset element from the zip task (with attributes <i>prefix</i>, <i>fullpath</i>, and <i>src</i>) is available in the War task.</p>
<p>The extended zipfileset element from the zip task
(with attributes <i>prefix</i>, <i>fullpath</i>, and <i>src</i>)
is available in the War task. The task is also resource-enabled
and will add nested resources and resource collections to the archive.</p>
<p>
Before Servlet API 2.5/Java EE 5, a WEB-INF/web.xml file was mandatory in a
WAR file, so this task failed if the <code>webxml</code> attribute was missing.
As the web.xml file is now optional, the <code>webxml</code> attribute is now
downgraded to being optional. The task will warn if the file is not
included as an attribute or in a fileset, but still succeed. The task
will also complain if more than one web.xml file is added to the JAR.
</p>
<p><b>Please note that the zip format allows multiple files of the same
fully-qualified name to exist within a single archive. This has been
@@ -55,13 +68,13 @@ to a value other than its default, <code>"add"</code>.</b></p>
</tr>
<tr>
<td valign="top">warfile</td>
<td valign="top"><i>Deprecated<i> name of the file to create
<td valign="top"><i>Deprecated</i> name of the file to create
-use <tt>destfile</tt> instead.</td>
</tr>
<tr>
<td valign="top">webxml</td>
<td valign="top">The deployment descriptor to use (WEB-INF/web.xml).</td>
<td valign="top" align="center">Yes, unless update is set to true</td>
Thank you for your continuous support to the Openl Qizhi Community AI Collaboration Platform. In order to protect your usage rights and ensure network security, we updated the Openl Qizhi Community AI Collaboration Platform Usage Agreement in January 2024. The updated agreement specifies that users are prohibited from using intranet penetration tools. After you click "Agree and continue", you can continue to use our services. Thank you for your cooperation and understanding.