upgrade to Servlet 2.4. CLK-763
git-svn-id: https://svn.apache.org/repos/asf/click/trunk/click@1096503 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/build/build.properties b/build/build.properties
index f6a3533..d6a21f8 100644
--- a/build/build.properties
+++ b/build/build.properties
@@ -52,7 +52,7 @@
junit.version=3.8.1
log4j.version=1.2.16
ognl.version=2.6.9
-servlet-api.version=2.3
+servlet-api.version=2.4
spring.version=2.5.6
velocity.version=1.7
diff --git a/build/build.xml b/build/build.xml
index b6352d0..a90675f 100644
--- a/build/build.xml
+++ b/build/build.xml
@@ -958,7 +958,7 @@
file="lib/${jar.log4j}"/>
<copy
todir="../${project-name}/lib"
- file="lib/servlet-api-2.3.jar"/>
+ file="lib/servlet-api-2.4.jar"/>
<copy
todir="../${project-name}"
file="template/build.xml"/>
diff --git a/build/click-mock.pom b/build/click-mock.pom
index 58c650a..7587382 100644
--- a/build/click-mock.pom
+++ b/build/click-mock.pom
@@ -39,7 +39,7 @@
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>
- <version>2.3</version>
+ <version>2.4</version>
<scope>provided</scope>
</dependency>
diff --git a/build/click-nodeps.pom b/build/click-nodeps.pom
index 9bb9df4..eb0631f 100644
--- a/build/click-nodeps.pom
+++ b/build/click-nodeps.pom
@@ -67,7 +67,7 @@
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>
- <version>2.3</version>
+ <version>2.4</version>
<scope>provided</scope>
</dependency>
</dependencies>
diff --git a/build/click.pom b/build/click.pom
index 0fbd86e..b77a315 100644
--- a/build/click.pom
+++ b/build/click.pom
@@ -32,7 +32,7 @@
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>
- <version>2.3</version>
+ <version>2.4</version>
<scope>provided</scope>
</dependency>
</dependencies>
diff --git a/documentation/docs/developer-guide/building.html b/documentation/docs/developer-guide/building.html
index 561d846..3b5c375 100644
--- a/documentation/docs/developer-guide/building.html
+++ b/documentation/docs/developer-guide/building.html
@@ -218,8 +218,8 @@
</tr>
<tr>
<td>Servlet API</td>
- <td>2.3</td>
- <td>servlet-2.3.jar</td>
+ <td>2.4</td>
+ <td>servlet-2.4.jar</td>
<td><a target="_blank" href="http://java.sun.com/products/servlet/">Sun Microsystems</a></td>
<td>JEE Servlet API</td>
</tr>
diff --git a/documentation/docs/velocity/velocity.html b/documentation/docs/velocity/velocity.html
index f6d6467..9dfdd68 100644
--- a/documentation/docs/velocity/velocity.html
+++ b/documentation/docs/velocity/velocity.html
@@ -83,16 +83,16 @@
of the page template to render.
</li>
<li><span class="st">request</span> -
- the pages <a class="external" target="_blank" href="http://java.sun.com/products/servlet/2.3/javadoc/javax/servlet/http/HttpServletRequest.html">HttpServletRequest</a>
+ the pages <a class="external" target="_blank" href="http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/http/HttpServletRequest.html">HttpServletRequest</a>
object.
</li>
<li><span class="st">response</span> -
- the pages <a class="external" target="_blank" href="http://java.sun.com/products/servlet/2.3/javadoc/javax/servlet/http/HttpServletResponse.html">HttpServletResponse</a>
+ the pages <a class="external" target="_blank" href="http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/http/HttpServletResponse.html">HttpServletResponse</a>
object.
</li>
<li><span class="st">session</span> -
the <a target="topic" href="../click-api/org/apache/click/util/SessionMap.html">SessionMap</a> adaptor
- for the users <a class="external" target="_blank" href="http://java.sun.com/products/servlet/2.3/javadoc/javax/servlet/http/HttpSession.html">HttpSession</a>.
+ for the users <a class="external" target="_blank" href="http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/http/HttpSession.html">HttpSession</a>.
</li>
</ul>
diff --git a/documentation/xdocs/src/docbook/click/chapter-best-practices.xml b/documentation/xdocs/src/docbook/click/chapter-best-practices.xml
index 7568fb8..c4bbd05 100644
--- a/documentation/xdocs/src/docbook/click/chapter-best-practices.xml
+++ b/documentation/xdocs/src/docbook/click/chapter-best-practices.xml
@@ -760,7 +760,7 @@
<para>Generally applications handle transactional errors using service layer code
or via a servlet
- <ulink url="http://java.sun.com/products/servlet/2.3/javadoc/javax/servlet/Filter.html">Filter</ulink>
+ <ulink url="http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/Filter.html">Filter</ulink>
and would not need to include error handling logic in an error page.
</para>
diff --git a/documentation/xdocs/src/docbook/click/chapter-configuration.xml b/documentation/xdocs/src/docbook/click/chapter-configuration.xml
index 2f511ee..90b0790 100644
--- a/documentation/xdocs/src/docbook/click/chapter-configuration.xml
+++ b/documentation/xdocs/src/docbook/click/chapter-configuration.xml
@@ -362,7 +362,7 @@
<para>When the Click application starts up it will check all the page
definitions. If there is a critical configuration error the ClickSerlvet
will log an <literal>ERROR</literal> message and throw an
- <ulink url="http://java.sun.com/products/servlet/2.3/javadoc/javax/servlet/UnavailableException.html">UnavailableException</ulink>.
+ <ulink url="http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/UnavailableException.html">UnavailableException</ulink>.
If this occurs the click application will be permanently unavailable until
the error is fixed and the web app is restarted.
</para>
@@ -725,7 +725,7 @@
<para>The <symbol>header</symbol> element defines header name and value
pairs which are applied to the
- <ulink url="http://java.sun.com/products/servlet/2.3/javadoc/javax/servlet/http/HttpServletResponse.html">HttpServletResponse</ulink>.
+ <ulink url="http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/http/HttpServletResponse.html">HttpServletResponse</ulink>.
</para>
<literallayout><!ELEMENT <symbol>header</symbol> (#PCDATA)>
diff --git a/documentation/xdocs/src/docbook/click/chapter-introduction.xml b/documentation/xdocs/src/docbook/click/chapter-introduction.xml
index bd1a3e9..2a38847 100644
--- a/documentation/xdocs/src/docbook/click/chapter-introduction.xml
+++ b/documentation/xdocs/src/docbook/click/chapter-introduction.xml
@@ -535,7 +535,7 @@
<para>Table is a <ulink url="../../click-api/org/apache/click/Stateful.html">Stateful</ulink>
control and provides methods for saving and restoring it's state.
Here we save the Table state in the
- <ulink url="http://java.sun.com/products/servlet/2.3/javadoc/javax/servlet/http/HttpSession.html">HttpSession</ulink>
+ <ulink url="http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/http/HttpSession.html">HttpSession</ulink>
which ensures sort and paging state is preserved while editing customers.
</para>
</callout>
diff --git a/documentation/xdocs/src/docbook/click/chapter-pages.xml b/documentation/xdocs/src/docbook/click/chapter-pages.xml
index 616bc45..ab3185e 100644
--- a/documentation/xdocs/src/docbook/click/chapter-pages.xml
+++ b/documentation/xdocs/src/docbook/click/chapter-pages.xml
@@ -239,13 +239,13 @@
</listitem>
<listitem>
<para>request - the pages
- <ulink url="http://java.sun.com/products/servlet/2.3/javadoc/javax/servlet/http/HttpServletRequest.html">HttpServletRequest</ulink>
+ <ulink url="http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/http/HttpServletRequest.html">HttpServletRequest</ulink>
object
</para>
</listitem>
<listitem>
<para>response - the pages
- <ulink url="http://java.sun.com/products/servlet/2.3/javadoc/javax/servlet/http/HttpServletResponse.html">HttpServletResponse</ulink>
+ <ulink url="http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/http/HttpServletResponse.html">HttpServletResponse</ulink>
object
</para>
</listitem>
@@ -253,7 +253,7 @@
<para>session - the
<ulink url="../../click-api/org/apache/click/util/SessionMap.html">SessionMap</ulink>
adaptor for the users
- <ulink url="http://java.sun.com/products/servlet/2.3/javadoc/javax/servlet/http/HttpSession.html">HttpSession</ulink>
+ <ulink url="http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/http/HttpSession.html">HttpSession</ulink>
</para>
</listitem>
</itemizedlist>
@@ -494,7 +494,7 @@
*/
public boolean onSecurityCheck() {
- if (getContext().getRequest().<ulink url="http://java.sun.com/products/servlet/2.3/javadoc/javax/servlet/http/HttpServletRequest.html#getRemoteUser()"><varname>getRemoteUser</varname></ulink>() != null) {
+ if (getContext().getRequest().<ulink url="http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/http/HttpServletRequest.html#getRemoteUser()"><varname>getRemoteUser</varname></ulink>() != null) {
return true;
} else {
@@ -523,7 +523,7 @@
*/
public boolean onSecurityCheck() {
- if (getContext().getRequest().<ulink url="http://java.sun.com/products/servlet/2.3/javadoc/javax/servlet/http/HttpServletRequest.html#isUserInRole(java.lang.String)"><varname>isUserInRole</varname></ulink>("admin")) {
+ if (getContext().getRequest().<ulink url="http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/http/HttpServletRequest.html#isUserInRole(java.lang.String)"><varname>isUserInRole</varname></ulink>("admin")) {
return true;
} else {
@@ -548,7 +548,7 @@
* @see Page#onInit()
*/
public void onInit() {
- getContext().getSession().<ulink url="http://java.sun.com/products/servlet/2.3/javadoc/javax/servlet/http/HttpSession.html#invalidate()"><varname>invalidate</varname></ulink>();
+ getContext().getSession().<ulink url="http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/http/HttpSession.html#invalidate()"><varname>invalidate</varname></ulink>();
}
}</programlisting>
@@ -566,7 +566,7 @@
<title>Forward</title>
<para> To forward to another page using the servlet
- <ulink url="http://java.sun.com/products/servlet/2.3/javadoc/javax/servlet/RequestDispatcher.html">RequestDispatcher</ulink>,
+ <ulink url="http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/RequestDispatcher.html">RequestDispatcher</ulink>,
set the Page's forward property. For example to forward to a page with a
path <varname>index.htm</varname>:
</para>
@@ -729,7 +729,7 @@
<para>Redirects are another very useful way to navigate between pages.
See HttpServletResponse.
- <ulink url="http://java.sun.com/products/servlet/2.3/javadoc/javax/servlet/http/HttpServletResponse.html#sendRedirect(java.lang.String)">sendRedirect</ulink>
+ <ulink url="http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/http/HttpServletResponse.html#sendRedirect(java.lang.String)">sendRedirect</ulink>
(location) for details.
</para>
@@ -786,7 +786,7 @@
<para>You can pass information between redirected pages using URL
request parameters. The ClickServlet will encode the URL for you using
- HttpServletResponse.<ulink url="http://java.sun.com/products/servlet/2.3/javadoc/javax/servlet/http/HttpServletResponse.html#encodeRedirectURL(java.lang.String)">encodeRedirectURL</ulink>
+ HttpServletResponse.<ulink url="http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/http/HttpServletResponse.html#encodeRedirectURL(java.lang.String)">encodeRedirectURL</ulink>
(url).
</para>
@@ -1330,7 +1330,7 @@
}</programlisting>
<para>Stateful page instances are stored in the user's
- <ulink url="http://java.sun.com/products/servlet/2.3/javadoc/javax/servlet/http/HttpSession.html">HttpSession</ulink>
+ <ulink url="http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/http/HttpSession.html">HttpSession</ulink>
using the pages class name as the key. In the example above the page would
be stored in the users session using the class name:
<classname>com.mycorp.page.SearchPage</classname>
diff --git a/examples/webapp/WEB-INF/click.xml b/examples/webapp/WEB-INF/click.xml
index f15f51f..50ff84b 100644
--- a/examples/webapp/WEB-INF/click.xml
+++ b/examples/webapp/WEB-INF/click.xml
@@ -22,7 +22,7 @@
<pages package="org.apache.click.examples.page" autobinding="annotation"/>
- <mode value="profile"/>
+ <mode value="trace"/>
<page-interceptor classname="org.apache.click.examples.interceptor.ProfilingInterceptor"/>
diff --git a/template/build.xml b/template/build.xml
index 8ed29e6..8c37940 100644
--- a/template/build.xml
+++ b/template/build.xml
@@ -12,7 +12,7 @@
-->
<path id="classpath">
- <pathelement location="lib/servlet-api-2.3.jar"/>
+ <pathelement location="lib/servlet-api-2.4.jar"/>
<fileset dir="WebContent/WEB-INF/lib">
<include name="*.jar"/>
</fileset>