| Using Struts 1.2.1 with JDeveloper 10g
Using Struts 1.2.1 with JDeveloper 10g
Written by Duncan Mills, Oracle Corporation
July 2004
Introduction
Struts is used as the run time page flow controller for most
thin client ADF based applications. JDeveloper 10g (9.0.5.2) is shipped
with Apache Struts version 1.1, the current production version, in the /jakarta-struts
directory.
This tip covers how to replace the default Struts 1.1 implementation with a
newer version, specifically Struts 1.2.1 Beta. Note that this configuration
has not been fully tested and should only be used for evaluation and testing
purposes.
The 1.2.1 release of Struts can currently be downloaded from
http://cvs.apache.org/dist/struts/v1.2.1/
What's new in Struts 1.2.1?
.A full list of the new features in the 1.2.1 release
is published on the Struts website (http://struts.apache.org/userGuide/release-notes.html).
Most of the changes are minor and will have little impact on applications that
utilize ADF data Binding.
Installing Struts 1.2.1 in JDeveloper
10g
The process of installing Struts 1.2.1 is a simple directory
drop in - these instructions are valid for JDeveloper 10g 9.0.5.1 and
9.0.5.2.
- Close JDeveloper if it is running.
- In the file system, rename the %JDEVELOPER_HOME%/jakarta-struts
directory to %JDEVELOPER_HOME%/jakarta-struts_1_1. This will enable you to
simply switch back to the production version of Struts when ever you need
to.
- Download the jakarta-struts-1.2.1.zip
/ tar
and unpack it into the %JDEVELOPER_HOME% directory, preserving the internal
directory structure in the process. This should create a new directory %JDEVELOPER_HOME%/jakarta-struts-1.2.1,
containing contrib, lib and webapps sub directories.
- Rename (or copy) this directory to %JDEVELOPER_HOME%/jakarta-struts.
- Restart JDeveloper.
Once the new version of Struts has been plugged in in this
way the IDE will automatically start to use that version and any Applciation
that you package up for deployment will be deployed with the new version of
the Struts framework.
Known Issues / Restrictions with Struts 1.2.1 and JDeveloper
10g
- The new wildcard
capabilities of Action Mappings cannot be used with ADF DataPages and
DataActions. This is due to a limitation in the Struts Action Mapping cloning
code which cannot handle the indexed properties used by these Action Subclasses
(Oracle Tracking Bug 375994)
- If you use the new wildcard capabilities of Action Mappings
with non ADF actions, they will work, however, the diagram representation
of such Actions will show the warning symbol by the Action shape because the
implementation of the action is not resolved until runtime. Thus an Action
definition of:
<action path="/go*" type="view.Go{1}Action" parameter="Parameter to {1}"> <forward name="success" path="/page{1}.do"/> </action>
Will generate the following shape on the diagram:
- Any additional issues that you discover with Struts 1.2.1
relating to it's use in JDeveloper can be reported via the OTN
Forum
drmills v1.0
|