jruaux 2003/02/26 09:24:27
Modified: documentation/docs/xdocs/integration/eclipse
eclipse_plugin.xml
Log:
Redid the documentation (updates and new sections)
Revision Changes Path
1.4 +157 -100
jakarta-cactus/documentation/docs/xdocs/integration/eclipse/eclipse_plugin.xml
Index: eclipse_plugin.xml
===================================================================
RCS file:
/home/cvs/jakarta-cactus/documentation/docs/xdocs/integration/eclipse/eclipse_plugin.xml,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- eclipse_plugin.xml 6 Feb 2003 09:04:56 -0000 1.3
+++ eclipse_plugin.xml 26 Feb 2003 17:24:27 -0000 1.4
@@ -10,22 +10,63 @@
</properties>
<body>
+ <section title="Requirements">
+ <p>
+ The Cactus plugin requires a version of the Eclipse platform higher
+ than 2.1 M5.
+ </p>
+ </section>
+ <section title="Installation">
+ <p>
+ Uncompress the zip file and copy the
+ 'org.apache.cactus.integration.eclipse_[version]' folder to your
+ Eclipse 'plugins' folder and restart Eclipse.
+ </p>
+ </section>
+ <section title="Configuration">
+ <p>Go to Window -> Preferences -> Cactus and set your preferences.</p>
+ </section>
+ <section title="How to use the plug-in">
+ <p>
+ While the Cactify action is not implemented you must do the
+ following :
+ <ul>
+ <li>
+ add Cactus client and common libraries to your Java project
+ </li>
+ <li>
+ your Java project must have the following directory structure :
+ [project's root]/web/WEB-INF/lib (create these as 'folders')
+ </li>
+ </ul>
+ Select any Cactus test class file and select from the toolbar :
+ Run As -> Cactus Test
+ <figure src="images/eclipse_launchShortcut.png"
+ alt="Cactus launch shortcut"/>
+ </p>
+ </section>
<section title="Overview">
<p>
- Cactus uses and extends JUnit. It might then seem natural
- that the Cactus plugin for Eclipse extends in a certain manner
- the existing JUnit plugin. For example
- <code>JUnitLaunchShortcut</code> is overloaded to be able to:
+ The Cactus framework extends JUnit. In the same way the Cactus plugin
+ for Eclipse extends in a certain manner the existing JUnit plugin. For
+ example
+ <code>JUnitLaunchShortcut</code>
+ is overloaded to be able to:
</p>
<ul>
- <li>prepare tests: setup of the container (deployment) and startup</li>
- <li>execute tests using the JUnit plugin methods</li>
- <li>tear down tests: stop the container and clean the deployment.</li>
+ <li>
+ prepare tests: set up the container (deployment) and start it
+ up
+ </li>
+ <li>execute tests using the JUnit plugin</li>
+ <li>
+ tear down tests: stop the container and clean the deployment.
+ </li>
</ul>
<p>
- In its actual state the plugin uses Ant scripts for these
- container setup and teardown.
+ The plugin uses Ant scripts from the Ant integration subproject for
+ container management.
</p>
</section>
@@ -34,14 +75,16 @@
<section title="Extension points">
<ul>
<li>
- <em>org.eclipse.debug.core.launchConfigurationTypes</em>
+ <em>
+ org.eclipse.debug.core.launchConfigurationTypes
+ </em>
registers cactusLaunchConfiguration
</li>
<li>
<em>org.eclipse.debug.ui.launchShortcuts</em>
- registers a shortcut which appears in the run
- and debug cascade menus to launch the current workbench
- selection in the Java perspective
+ registers a shortcut which appears in the run and debug
+ cascade menus to launch the current workbench selection in the Java
+ perspective
</li>
<li>
<em>org.eclipse.ui.preferencePages</em>
@@ -51,14 +94,14 @@
</section>
<section title="GUI: preference page">
<p>
- A preference page is contributed to the Eclipse
- preferences. It shows the following entries:
+ A preference page is contributed to the Eclipse preferences. It shows
+ the following entries:
</p>
<ul>
<li>Cactus properties (contextURL)</li>
<li>
- directory of all the jars needed for Cactus
- tests (client side and server side)
+ directory of all the jars needed for Cactus tests (client
+ side and server side)
</li>
<li>setting of the container homes</li>
</ul>
@@ -66,24 +109,23 @@
<section title="IContainerProvider">
<p>
- To enable different ways to setup, start, and stop
- containers the idea of container providers has been
- introduced in the plugin.
+ To enable different ways to setup, start, and stop containers the
+ idea of container providers has been introduced in the plugin.
</p>
<p>
- A container provider is responsible for deploying a web
- application to the container, starting and stopping it, and
- undeploying the web app. This concept is concretized in the
- interface
+ A container provider is responsible for deploying a web application
+ to the container, starting and stopping it, and undeploying the web
+ app. This concept is concretized in the interface
<code>IContainerProvider</code>
. See its javadoc for more information.
</p>
<p>
- A container provider is implemented in the current version
- of the plugin, which uses Ant scripts to carry out these
- actions. It is called
+ A container provider is implemented in the current version of the
+ plugin, which uses Ant scripts to carry out these actions. It is
+ called
<code>GenericAntProvider</code>
- and may be used to execute tests on Tomcat 4.0 and Weblogic 7.0.
+ and may be used to execute tests on all the containers supported by
+ the Ant integration subproject.
</p>
</section>
<section title="What happens when a test is launched">
@@ -92,9 +134,9 @@
<code>launch(IType theType, String theMode)</code>
method of the
<code>CactusLaunchShortcut</code>
- class is called, which sets up the container, launches
- the tests by delegating these to the JUnit plugin, and then
- tears down the container setup.
+ class is called, which sets up the container, launches the tests
+ by delegating these to the JUnit plugin, and then tears down the
+ container setup.
</p>
<ul>
<li>
@@ -102,29 +144,36 @@
<p>This includes:</p>
<ul>
<li>
- creating the war file for the cactus
- tests: this is done by the
- <code>WarBuilder</code>
+ creating the war file for the cactus tests: this is done
+ by the
+ <code>
+ WarBuilder
+ </code>
class, and relies on an Ant script for that.
</li>
<li>
- setting up the container: prepares the
- configuration for the selected container
+ setting up the container: prepares the configuration for
+ the selected container
</li>
<li>starting the container.</li>
</ul>
<p>
In the case of
- <code>GenericAntProvider</code>:
+ <code>GenericAntProvider</code>
+ :
</p>
<ul>
- <li>setting up is done by an Ant script</li>
+ <li>
+ setting up is done by an Ant script
+ </li>
<li>
starting the container is delegated to the
- <code>StartServerHelper</code>
- class, which initiates a thread starting
- the container and then pings it constantly to
- see if it has been effectively launched.
+ <code>
+ StartServerHelper
+ </code>
+ class, which initiates a thread starting the container and
+ then pings it constantly to see if it has effectively been
+ launched.
</li>
</ul>
</li>
@@ -134,38 +183,25 @@
This behaviour is inherited from the JUnit plugin since
<code>CactusLaunchShortcut</code>
extends
- <code>JUnitLaunchShortcut</code> .
+ <code>JUnitLaunchShortcut</code>
+ .
</p>
</li>
<li>
Tests end
<p>
- To know when tests have ended we register our
- TestListener to the JUnit plugin.
- </p>
-
- <p>
- For that the JUnit plugin had to be modified, a
- patch is avaible at the root of the Cactus CVS.
- </p>
-
- <p>
- The
- <code>JUnitViewFinder</code>
- class is launched which looks for the
- JUnitView, so that we can eventually register our
- listener.
+ To know when tests have ended we register our TestListener to
+ the JUnit plugin. To this end the JUnit plugin needed a
+ modification which has been integrated in the release 2.1 M5 of
+ the Eclipse platform.
</p>
</li>
<li>
- Tests environment cleaning
-
+ Test environment cleaning
<p>
- After the tests have completed, work has to be
- done to stop the container and delete all
- configuration files and the war file we created
- before.
+ After the tests have completed we stop the container, and
+ delete the configuration and war files created beforehand.
</p>
</li>
</ul>
@@ -173,66 +209,87 @@
</section>
<section title="What has been done so far">
<p>
- In its actual state the plugin is a proof of concept. It is
- able to run the distribution sample tests.
+ The plug-in currently incorporates the basic functionalities to be
+ able to run Cactus tests on the variety of containers supported by the
+ Ant integration subproject.
</p>
</section>
<section title="Features">
<ul>
- <li>a minimalistic launch configuration</li>
- <li>a minimalistic launch shortcut</li>
- <li>a minimalistic launch configuration tab group</li>
- </ul>
- <ul>
<li>
- Validates calling Ant script before and after running
- the tests to package and deploy the application to the
- container and start it.
+ Adds a shortcut for Cactus tests launching.
+ <figure src="images/eclipse_launchShortcut.png"
+ alt="Cactus launch shortcut"/>
</li>
+ </ul>
+ <ul>
<li>
- Executes the Cactus Ant script for Tomcat before
- starting the JUnit Test Runner (and after). This Ant script
- needs to be part of the Cactus plugin and does the
- following: creates a WAR from the application sources and
- start Tomcat. After the test is finished a second script is
- run to stop Tomcat.
+ Relies on the Eclipse Ant integration to :
+ <ul>
+ <li>
+ package a WAR containing the Web application
+ </li>
+ <li>deploy the application</li>
+ <li>
+ start the container before running the tests
+ </li>
+ <li>
+ stop the container when tests have ended
+ </li>
+ </ul>
</li>
</ul>
<ul>
- <li>Cactus preference page (see below for content)</li>
- <li>Support for several containers</li>
+ <p>
+ Cactus preference page
+ <figure src="images/eclipse_preferences.png"
+ alt="Cactus preference page"/>
+ </p>
+ <li>Port on which the container is started.</li>
<li>
- On preference page and on Cactus TabGroup page: ability to
- choose the port on which the container is started.
+ Working directory where the Cactus plugin will create temporary
+ files (packaged war, container configuration files, etc).
</li>
+ <li>Support for several containers</li>
+ <figure src="images/eclipse_preferences_containers.png"
+ alt="Preferences for containers"/>
+ </ul>
+ <ul>
<li>
- On preference page, ability to specify the working
- directory where the Cactus plugin will create all its files
- (packaged war, app server config files, etc)
+ The user can provide its own web.xml file. If this is not the case
+ the plug-in will use the one by default.
</li>
- <li>
- Plugin documentation and development documentation
- (for todos, etc).
- </li>
</ul>
<ul>
- <li>
- The user can provide its own web.xml file.
- Otherwise the plugin will use the one provided by default.
- </li>
+ <li>
+ Relies on the JUnit plug-in for test runs and result reports.
+ <figure src="images/eclipse_junit.png"
+ alt="JUnit plug-in"/>
+ </li>
</ul>
</section>
<section title="What is next">
<p>
- In order to have a production-quality tool the following
- points must be done:
+ In order to release a production-quality tool the following features
+ are needed :
</p>
<ul>
- <li>automate tests on the plugin</li>
- <li>ability to leave the container running between redeployments</li>
+ <li>
+ Ability to Cactify a Java project :
+ <ul>
+ <li>
+ add the client-side jars to the project's build path
+ </li>
+ <li>
+ create a web application folder structure
+ </li>
+ </ul>
+ </li>
+ <li>Automate tests on the plugin</li>
+ <li>Ability to leave the container running between redeployments</li>
+ <li>Add a log console a la Ant</li>
</ul>
-
</section>
</body>
</document>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]