You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by Apache Wiki <wi...@apache.org> on 2006/01/09 01:32:47 UTC
[Struts Wiki] Update of "StrutsUpgradeNotes12to13" by NiallPemberton
Dear Wiki user,
You have subscribed to a wiki page or wiki category on "Struts Wiki" for change notification.
The following page has been changed by NiallPemberton:
http://wiki.apache.org/struts/StrutsUpgradeNotes12to13
The comment on the change is:
Add notes about dependencies
------------------------------------------------------------------------------
* struts-el-1.3.x.jar (in addition to struts-taglib) if you want to use the JSTL expression language
* struts-tiles-1.3.x.jar (if you want to use Tiles)
+ == 3. Dependencies ==
+ A number of dependencies have changed from Struts 1.2.x
+
+ === 3.1 Chain 1.0 ===
+ Struts 1.3 introduces a new dependency on
+ [http://jakarta.apache.org/commons/chain/ Commons Chain] version 1.0. - remember to deploy the Chain jar
+
+ === 3.2 File Upload 1.1 ===
+ Struts 1.3 now depends on
+ [http://jakarta.apache.org/commons/fileupload/ Commons FileUpload] version 1.1 (previously was version 1.0). As well as needing to upgrade the !FileUpload jar you will now also need the
+ [http://jakarta.apache.org/commons/io/ Commons IO] Version 1.1 jar.
+
+ === 3.3 Commons Validator 1.2.0 ===
+ Struts 1.3 now depends on
+ [http://jakarta.apache.org/commons/validator/ Commons Validator] version 1.2.0 (previous was version 1.1.4) - remember to upgrade the Validator jar.
+
+ * Validator 1.2 will recognize config files from prior versions. Optionally, you may
+
+ * Change the doctype declaration at the top of validation.xml to refer to the dtd for version 1.2
+
+ {{{
+ <!DOCTYPE form-validation PUBLIC
+ "-//Apache Software Foundation//DTD Commons Validator Rules Configuration 1.2.0//EN"
+ "http://jakarta.apache.org/commons/dtds/validator_1_2_0.dtd">
+ }}}
+
+ * You must upgrade to the new version of validator-rules.xml. This file is included in struts-action.jar, so the easiest way to upgrade is to delete any copies you may have in your application and use the following Validator Plugin configuration:
+
+ {{{
+ <plug-in className="org.apache.struts.validator.ValidatorPlugIn">
+ <set-property
+ property="pathnames"
+ value="/org/apache/struts/validator/validator-rules.xml,
+ /WEB-INF/validation.xml"/>
+ </plug-in>
+ }}}
+
+ === 3.4 CGLib 2.1_3 ===
+ Struts 1.3 introduces a new dependency on
+ [http://cglib.sourceforge.net/ CGLib] version 2.1_3 - you should only need to deploy the CGLib jar if you use the new '''''enhanced''''' feature for dyna forms.
+
+ {{{
+ <form-bean type="org.apache.struts.action.DynaActionForm" enhanced="true">
+ <form-property name="..." />
+ </form-bean>
+ }}}
+
- == 3. Configuration ==
+ == 4. Configuration ==
The ''default'' Request Processor for Struts 1.3 is the new Chain (CoR) based ''ComposableRequestProcessor''.
- === 3.1 CoR Request Processor ===
+ === 4.1 CoR Request Processor ===
By default, the ComposableRequestProcessor will use a configuration file included in the struts-core JAR, and you won't need to do anything.
However, if you want to use Tiles, you must instruct Struts to use a configuration file included in the struts-tiles JAR instead. To do this:
@@ -34, +81 @@
You can do much more to configure the ComposableRequestProcessor, but those details are outside the scope of this document.
- === 3.2 Original Request Processors ===
+ === 4.2 Original Request Processors ===
If you want to continue using either of the existing Request Processors (i.e. RequestProcessor or TilesRequestProcessor) then you need to specify this in the controller element of the ''struts-config.xml''
@@ -42, +89 @@
<controller processorClass="org.apache.struts.tiles.TilesRequestProcessor" />
}}}
- === 3.3 Commons Validator ===
+ == 5 Deprecations which have been removed ==
- * Validator 1.2 will recognize config files from prior versions. Optionally, you may
-
- * Change the doctype declaration at the top of validation.xml to refer to the dtd for version 1.2
-
- {{{
- <!DOCTYPE form-validation PUBLIC
- "-//Apache Software Foundation//DTD Commons Validator Rules Configuration 1.2.0//EN"
- "http://jakarta.apache.org/commons/dtds/validator_1_2_0.dtd">
- }}}
-
- * Upgrade to the new version of validator-rules.xml. This file is included in struts-action.jar, so the easiest way to upgrade is to delete any copies you may have in your application and use the following Validator Plugin configuration:
-
- {{{
- <plug-in className="org.apache.struts.validator.ValidatorPlugIn">
- <set-property
- property="pathnames"
- value="/org/apache/struts/validator/validator-rules.xml,
- /WEB-INF/validation.xml"/>
- </plug-in>
- }}}
-
- == 4 Deprecations which have been removed ==
-
- === 4.1 struts-config_1_3.dtd ===
+ === 5.1 struts-config_1_3.dtd ===
Removed the contextRelative attribute of the forward element.
- === 4.2 Classes ===
+ === 5.2 Classes ===
ActionError has been removed. Use ActionMessage instead.
- === 4.3 Methods and properties ===
+ === 5.3 Methods and properties ===
||Class||Member||Comments||
||Action||defaultLocale||Use Locale.getDefault directly.||
||Action||saveErrors(HttpServletRequest request, ActionErrors errors)||Use saveErrors(HttpServletRequest, ActionMessages) instead.||
@@ -109, +133 @@
||TagUtils (Taglib)||getActionErrors()||use getActionMessages() instead.||
||TagUtils (Tiles)||getProperty()||Use PropertyUtils.getProperty() directly.||
- === 4.4 TLD URLs ===
+ === 5.4 TLD URLs ===
The struts-taglib and struts-tiles distributions no longer include TLDs which are configured with
the old URIs under the ''jakarta.apache.org'' domain name. You must make the following changes:
@@ -120, +144 @@
||http://jakarta.apache.org/struts/tags-nested||http://struts.apache.org/tags-nested||
||http://jakarta.apache.org/struts/tags-tiles||http://struts.apache.org/tags-tiles||
- === 4.5 Tag Attributes ===
+ === 5.5 Tag Attributes ===
||Tag||Attribute||Comments||
||bean:include||name||Use page instead.||
||html:html||locale||Use lang instead.||
||html:img||contextRelative||Use module instead.||
||html:img||lowsrc||Non-standard attribute; No longer supported.||
- == 5. Deployment ==
+ == 6. Deployment ==
* If you experience NoClassDefFoundErrors in JSP code after deploying a Struts 1.3 webapp using the same context name it had under a prior version, try deleting the generated .java and .class files related to the JSP files. In Tomcat, these are found under the $TOMCAT_HOME/work directory.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org