...
The Geronimo Eclipse Plugin (GEP) provides integration between Geronimo and the Web Tools Platform (WTP). With this plugin, users will be able to use the features in WTP to create, deploy and debug applications on Geronimo.
INLINE
This section provides a quick tutorial for developing and running applications with GEP in Geronimo.
...
Table of Contents |
---|
Getting the software
The Geronimo Eclipse Plugin (GEP) requires the following prerequisite software (all of which is platform specific):
- Sun JDK 56.0 (J2SE 56.0)
- Eclipse IDE for Java EE Developers
Sun JDK 56.0 can be downloaded from Sun's J2SE 5.0 Downloads site. The Eclipse IDE for Java EE Developers can be downloaded in from the Eclipse Downloads site. Download and extract the Eclipse IDE for Java EE Developers archives to a directory of your choice (for e.g. example, C:\eclipse). The archive will be extracted to a directory named eclipse under the directory you specified (for e.g. example, C:\eclipse\eclipse), referred to as <eclipse<ECLIPSE_home>HOME> from now on. Make sure that the JDK in the PATH is Sun JDK 56.0. Launch Eclipse by running <eclipse<ECLIPSE_home>HOME>/eclipse.
The Geronimo server can be installed using the Geronimo Eclipse Plugin, or optionally you may install the manually. To install it manually, download the Geronimo 2.1.1 2 server from http://wwwgeronimo.apache.org/dist/geronimo/downloads.html and extract the archive to a directory of your choice (for e.g. C:\g). The archive will be extracted to a directory geronimo-tomcat6-javaee5-2.1.12 (for e.g. C:\g\geronimo-tomcat6-javaee5-2.1.12) or geronimo-jetty6-javaee5-2.1.12 depending on whether you downloaded Geronimo 2.1.1 2 distribution with Tomcat or Jetty as the web container. We will refer to this directory as <geronimo<GERONIMO_home>HOME> from now on.
Installing Geronimo Eclipse Plugin
...
Geronimo Eclipse Plugin
...
The Geronimo Eclipse Plugin ( GEP ) can be installed using the following options:
- Using WTP
- Using Eclipse Update Manager
- Manual Installation
Install GEP Using WTP
The GEP can be installed directly from within WTP while defining a server runtime. Follow the steps below to install GEP:
- Launch Eclipse by running <eclipse_home>/eclipse.
- Launch the Define a New Server dialog using one of the following:
- From the Servers view in the Java EE Perspective: Right-click, New, Server.
- From any Perspective: Select File, New, Other, Server
- Click on the Download additional server adapters link.
- In the Install New Server Adapter dialog, select Geronimo v2.1 Server Adapter and click Next.
- Read and accept any License Agreements and click Finish. Click OK to continue installation.
...
Install GEP Using Eclipse Update Manager
The GEP can also be installed via the Eclipse Update manager by creating a new remote site pointing to http://www.apache.org/dist/geronimo/eclipse/updates/. Follow the steps below to install GEP:
- Launch Eclipse by running <eclipse<ECLIPSE_home>HOME>/eclipse.
- Open the Eclipse Update Manager as follows:
- Select Help, Software Updates, Find and Install.
- Select Search for new features to install and click Next.
- Create a Eclipse Remote Update Site as follows:
- Click the New Remote Site... button.
- Type Geronimo Eclipse Update Site (or other suitable unique name) in the Name field.
- Type the URL of the Geronimo Eclipse Update site http://www.apache.org/dist/geronimo/eclipse/updates in the URL field.
- Click OK.
- Click the New Remote Site... button.
- Select only the Geronimo Eclipse Update Site in the Sites to include in search selection box and click Finish.
- Select a mirror and click OK if prompted to do so.
- In the Search Results, expand Geronimo Eclipse Update Site and Geronimo WTP Server Adapters.
- Select Geronimo Core Feature 2.12.0 and Geronimo v2.1 2 Server Adapter 2.12.0 and click Next.
- Read and accept any license agreements and click Next.
- Click Finish to download the selected features.
- Click Install All.
- Click Finish to complete the installation.
- Click Yes to restart Eclipse for the changes to take effect.
Manual Installation of GEP
Download the GEP 2.1 from http://www.apache.org/dist/geronimo/eclipse/. Close Eclipse if it is already running. Extract the archive to <eclipse_home>. Launch Eclipse by running <eclipse_home>/eclipse -clean.
...
title | Important |
---|
...
The definitive and current version of the GEP installation instructions may be found here: Installing Geronimo Eclipse Plugin.
...
Verify GEP Installation
To verify that the GEP installation has been successful, start your new Eclipse installation and from the workspace select " Help --> About Eclipse Platform". In the panel that appears you will see anywhere from 4-6 Eclipse icons representing the various Eclipse projects and/or components installed. You must also see the Geronimo icon as shown below. If not something has not been installed correctly. If the Geronimo icon does appear, that is a very good indication that Eclipse and the GEP have been installed correctly, and you can confidently continue to the next step.
...
Follow the steps below to define a new Geronimo v2.1 2 Server Runtime:
- Launch the Define a New Server dialog using one of the following:
- From the Servers view in the Java EE Perspective: Right-right click, select New, and Server.
- From any Perspective: Select File, New, Other, Server.
- Select Apache Geronimo v2.1 2 Server and click Next.
- Select a 56.0 JRE (click Click Installed JREs to add any new JREs and return to this dialog once done).
- If you already have Geronimo v2.1 2 installation that you want to use with GEP, enter the directory name or browse to <geronimo<GERONIMO_home>HOME> and click Next. Skip the next three steps and go to selecting source archive.
- Enter a directory for Application Server Installation Directory, under Download Options select the web Web container and click Download and Install.
Note title ImportantThe directory specified for Application Server Installation Directory must exist in order to select Download Options.
- Click OK for Install Confirmation. This will install the selected Geronimo v2.1 2 server and fill the Application Server Installation Directory field accordingly.
- Click Next.
- Select the location of the archive containing Geronimo source and click Next. This is required only if you intend to debug into Geronimo source code.
- Modify Hostname, Administrator Id, Administrator password, Web Connector port and RMI Naming port if necessary and click Finish. Normally you will not need to change the default values for these fields for a newly installed Geronimo 2.1 server.
This completes defining a new Geronimo 2.1 Server runtime. The newly added server will appear in the Servers view. The server can be started by selecting the server and clicking on the Start server button.
...
- Select File, Import to launch the Select dialog.
- Based on your application type, select as given below:
- For Web application, Select Web, WAR file.
- For EAR application, Select J2EE, EAR file.
- For EJB application, Select EJB, EJB JAR file.
- Click Next.
Note webRemaining steps are based on a
Web application.
- Type the name of the WAR file or select the WAR file by clicking on Browse, enter/edit the Project Name and select Apache Geronimo v2.1 2 Runtime as Target Runtime.
- Click Finish to complete the import.
The imported application can be viewed in the Project Explorer view. The GEP will create a Geronimo specific deployment plan, in this case geronimo-web.xml under WebContent/WEB-INF, if one is not already present in the archive. You may might need to edit the deployment plan to map any resources used by your application.
...
To deploy the application on Geronimo, follow the steps below:
- In the Servers view, Right-right click on Apache Geronimo v2.1 2 Server at localhost and select Add and Remove Projects.
- In the Add and Remove Projects dialog, select the project under Available projects and click on Add button. The project will now be listed under Configured projects.
- Click Finish.
...
In order to run the application follow the steps below:
- In the Project Explorer view, Right-right click on the project, select Run As, Run on server.
- Select Choose an existing server and select Apache Geronimo v2.1 2 server at localhost.
- Click Finish.
...