|  |
Web Data Access Developer
A simple, easy-to-use, Eclipse plug-in development environment for building a basic data access client.
Date Posted: June 30, 2005
|
|
 |
 |
|
Platform requirements for Web Data Access Developer
Operating systems: Any system that will support Eclipse, the target application, and the database servers
For the base-level tool, which supports an autogenerated JSF interface and Tomcat/Derby run-time environment:
For the AUIML component:
For Web Data Access Client Developer support: com.ibm.extremeblue.expresswebdev_1.0.1
Installation instructions for Web Data Access Developer
Base-level tool, which supports an autogenerated JSF interface and Tomcat/Derby run-time environment
- Install Tomcat 4.1 or equivalent (see the Tomcat readme file).
- Install Apache Derby or equivalent, such as Cloudscape 10.0.
- Connect to Cloudscape (Derby) from Eclipse WTP, using the following connection parameters:
- Database: patientdb (See sample database files included in plug-in.)
- JDBC driver class: com.ibm.db2.jcc.DB2Driver
- Class location: Go to <cloudscape_install_dir>\lib\ and select both db2jcc.jar and db2jcc_license_c.jar.
- Connection URL: jdbc:derby:net://localhost:1527/patientdb
Note: We used "PATIENT" for the user name because it is the database schema we used in our sample scripts. Otherwise, use your actual schema name, because Apache Torque assumes the schema name equals the user name. It doesn't matter what you use for the password (they're not set up by default), but you must provide a non-null value.
- Install the Eclipse base (M4 build) required for the M2 build of the Web Tools Platform.
- Install the M2 build of the Web Tools Platform.
- Install the following plug-ins from the M3 build (wtp-sdk-1.0M3.zip) of the Web Tools Platform (copy over the M2 WTP plug-ins):
org.eclipse.wst.rdb.connection.ui_1.0.0
org.eclipse.wst.rdb.core_1.0.0
- Install the Web Data Access Client plug-in: com.ibm.extremeblue.expresswebdev_1.0.1
- A patched torque-gen-3.1.1.jar file must be created by using the following steps to configure it with the relevant webdev object model:
- Download the torque-gen-3.1.1.src.zip file (Apache DB Torque project 3.1.1 - Torque Generator).
- Extract the files.
- Copy the torque-gen.patch file into the top-level directory (torque-3.1.1-src) (where the directories conf/, contrib/, examples/ ... and src/ reside).
- Open a shell (cygwin or any UNIX shell) and run the command "patch -Np1 -i ./torque-gen.patch".
- Verify the output as below:
$ patch -Np1 -i ./torque-gen.patch
patching file src/generator/src/java/org/apache/torque/engine/database/model/Col
umn.java
patching file src/generator/src/java/org/apache/torque/engine/database/model/For
eignKey.java
patching file src/generator/src/java/org/apache/torque/task/TorqueDataModelTask.
java
patching file src/generator/src/java/org/apache/torque/task/TorqueJDBCTransformT
ask.java
patching file src/generator/src/templates/om/Control.vm
patching file src/generator/src/templates/om/DataException.vm
patching file src/generator/src/templates/om/ExtensionObject.vm
patching file src/generator/src/templates/om/InitializationException.vm
patching file src/generator/src/templates/om/MapBuilder.vm
patching file src/generator/src/templates/om/Object.vm
patching file src/generator/src/templates/om/auiml/CreateAUIML.vm
patching file src/generator/src/templates/om/auiml/ExtensionAUIML.vm
patching file src/generator/src/templates/om/auiml/RetrieveAUIML.vm
patching file src/generator/src/templates/om/auiml/SearchAUIML.vm
patching file src/generator/src/templates/om/auiml/TableCreate.vm
patching file src/generator/src/templates/om/auiml/TableRetrieve.vm
patching file src/generator/src/templates/om/auiml/TableSearch.vm
patching file src/generator/src/templates/om/auiml/TableUpdate.vm
patching file src/generator/src/templates/om/auiml/TableWelcome.vm
patching file src/generator/src/templates/om/auiml/UpdateAUIML.vm
patching file src/generator/src/templates/om/auiml/WelcomeAUIML.vm
patching file src/generator/src/templates/om/jsf/ExtensionJSF.vm
patching file src/generator/src/templates/om/jsf/ExtensionJSFBacking.vm
patching file src/generator/src/templates/sql/base/mysql/table.vm
patching file src/generator/src/templates/sql/load/db2/row.vm
- Build the Torque Generator JAR file with Apache Ant using the build.xml file in the torque-3.1.1-src\src\generator directory.
- Add (using the "jar -uvf" command) the file content from all the subdirectories (data, doc, ojb, om, and sql) under the torque-3.1.1-src\src\generator\src\templates directory.
- Create a lib directory in the root of the plug-in directory and add the following third-party libraries:
AUIML component
- Update the Eclipse base with the following features from the Eclipse update site:
- Java EMF Model 1.0.2.1
- Visual Editor 1.0.2.1
- Download and install the Abstract User Interface Markup Language Toolkit (AUIML) 5.1.
- Install the com.ibm.extremeblue.expresswebdev_1.0.1 plug-in, create the following directories in the plug-in root directory, and add the following files:
- auiml/resources/* and subdirectories -> auiml\Toolkit\csa_runtime\aui_war_template.zip -> resources (AUIML Toolkit)
- auiml/redirect.jsp -> auiml\Toolkit\csa_runtime\auiwebdemos.war -> html (AUIML Toolkit)
- auiml/web.xml -> auiml\Toolkit\csa_runtime\auiwebdemos.war -> WEB-INF (AUIML Toolkit)
- Add the following AUIML libraries into a lib/auiml directory in the plug-in:
Toolkit/csa_runtime/lib/auibase.jar
Toolkit/csa_runtime/lib/auifw.jar
Toolkit/csa_runtime/lib/auihtmlpreview.jar
Toolkit/csa_runtime/lib/aui18n.jar
Toolkit/csa_runtime/lib/auiswing.jar
Toolkit/csa_runtime/lib/auiweb.jar
Toolkit/csa_runtime/lib/ext/jhall.jar
Toolkit/csa_runtime/lib/ext/jtoe.jar
Toolkit/csa_runtime/lib/ext/swing11spinner.jar
Toolkit/csa_runtime/lib/ext/uil.jar
Toolkit/csa_runtime/lib/ext/wcl.jar
Toolkit/csa_runtime/lib/ext/wcl_en.jar
Toolkit/csa_runtime/lib/ext/wua.jar
Toolkit/csa_runtime/lib/ext/wua_en.jar
Toolkit/csa_runtime/lib/ext/xhtml-csa.jar
Toolkit/csa_runtime/lib/ext/xml-apis.jar
Once you follow the tutorial and generate the sample data support for the data access client, extract the auiml_sample.zip file over the JavaSource folder in the project. This will give you the sample AUIML client implementation panels.
WCTME support
- Install the WCTME 5.8.1 product/trial.
- Install the com.ibm.extremeblue.expresswebdev_1.0.1 plug-in:
- icons/wctme.gif -> eclipse\plugins\com.ibm.eswe.workbench_5.8.1\icons\ws_16x16.gif (Note: rename to wctme.gif after copying.) (WCTME-EO product/trial)
- lib/wctme/jasper-compiler.jar -> eclipse\plugins\org.eclipse.tomcat_4.1.30 (Eclipse M4 build)
- lib/wctme/jasper-runtime.jar -> eclipse\plugins\org.eclipse.tomcat_4.1.30 (Eclipse M4 build)
- lib/wctme/servlet.jar -> eclipse\plugins\org.eclipse.tomcat_4.1.30 (Eclipse M4 build)
- lib/wctme/webapplication.jar -> WCTME\eclipse\plugins\com.ibm.osg.webapp_1.1.1 (WCTME-EO 5.8.1)
- Copy the wctme581.server file to the C:\eclipse\plugins\org.eclipse.jst.server.generic.core_1.0.0\servers directory. This is a generic implementation of a generic server that represents a non-rich client version of WCTME. You can use it to represent the target server in the project when you create it. You can also create the application with Tomcat as the target server and simply export it as a WCTME WAB file and it will still run on WCTME. This server implementation is incomplete and was used with a proof-of-concept version of WCTME that ran without the rich-client interface.
To run the WCTME application from within Eclipse, simply configure the target platform location value under Window -> Preferences and Plug-in Development -> Target Platform to point to your <WCTME install dir>\eclipse directory. Then when you launch an Eclipse Application, it will launch an instance of WCTME.
|
|
 |
|
| |
|