Contributor Howto
Eclipse
web site
Building from Sources Howto
Javadocs
|
Eclipse Setup
Howto
Introduction
This How-To describes how you can set up a working Jiplet project using
the
Eclipse IDE 3.2. Setting up an Eclipse project is only required if you
are an active developer for the Jiplet project. If you merely want to
build
the distribution from the source code, use the howto for building the jiplet container from the sources
instead. If the steps listend below
turn out to be little different from what is available on the screen,
you will need to improvise. From this howto, you'll learn how to setup,
compile, and run the
Jiplet Container in Standalone mode or as a JBoss service. There are
probably many ways to achieve the desired result, but these steps are
straightforward enough for Eclipse newbies.
Content
Get Eclipse
ready
Before we begin, you'll need to get Eclipse
3.2 (or above) installed along with the following plugin(s). You
can download the latest stable version of the Eclipse from http://www.eclipse.org:
- Subclipse Plugin: The jiplet source code is managed using Subversion.
The repository resides in the Sourceforge site. The Subclipse plugin
lets you manage revision control operations directly from the Eclipse
IDE. For more details on installing and using Subclipse, visit http://subclipse.tigris.org/
.
- The Calisto Web Tools Project (WTP) Plugin: The jiplet
container and other cafesip projects contains J2EE and web components.
If you develop software in these areas, the WTP plugin comes in handy.
You can find more information on this plugin from http://www.eclipse.org/webtools/main.php
. Note that this plugin is optional.
Download and install the above plugin(s) as per the instructions
provided
by the authors.
Create a
new Eclipse project from the Subversion Repository
- Create a directory called cafesip in a location where you
want to store the source code for the jiplet project. This is your
development workspace. Create an environment variable called
CAFESIP_HOME to point to this location.
- From the Eclipse IDE, select menu options Window->Show
View->Other.
- From the Show View dialog box, select the SVN folder
and select SVN Repository. An empty SVN repostory panel will be
created and docked into the Eclipse screen.
- Select the SVN Repository panel, right click on the panel
to bring up the popup menu. Select New->Repository Location.
- From the repository dialog box, enter the URL - http://cafesip.svn.sourceforge.net/svnroot/cafesip
.
- Once the above step is completed, you will see the CafeSip
source tree on the panel. First select the jiplet project and choose
the sub-directory called "trunk" to select the latest code base. The
trunk has the latest software but may not always work and even
may not compile. If you want to create a project that is more stable,
under the jiplet project, select the labels/stable sub-directory
instead. If
you are working on a branch, you may have to choose a different
sub-directory.
- Right-click on the trunk, from the context menu, select the
Checkout option. The Eclipse IDE will contact the repository to gather
project information. We have included all the Eclipse project files
with the jiplet source code so that the project can be setup easily.
- From the Checkout dialog box, select Next. Uncheck the "Use
default workspace location". Instead enter the location of the
directory where you created the cafesip directory above
($CAFESIP_HOME). Clck on the Finish button.
- The Eclipse IDE will download the source code and create
the project. Depending on your connection speed, the download time will
vary. The download is more than 15MB. Once the download is completed,
you will see the project on the Package Explorer panel.
Run the build
- From the Package Explorer, open the build.xml file. From
the outline, select the target "build".
- Run the target by right-clicking and selecting the Run
As->Ant Build menu items.
- When you execute the above targets, you would have built
the entire project.
- Alternatively, run the targets explained below to execute
individual tasks:
- compile: Generate XML parser classes and compile
the entire source code
- build-standalone: Create the standalone deployment. You
must run the compile target before running this target.
- build-jboss: Create the jboss deployment. You must run
the compile target before running this target.
- build-console: Create the console deployment. You must
run the compile target before running this target.
- Select the jiplet project from the project explorer,
right-click and select the Refresh menu item so that Eclipse picks up
all the generated Java files. Although this may not be necessary, you
may also want to build the project using the Project menu. The Eclipse
project should not display any errors at this point.
Run it!
If you want to run the jiplet container as a standalone application:
- Jiplet container: Select the jiplet project from the
Package Explorer. From the Run menu and select Run... menu item. Select
Java Application. Right-click and select the "New" menu item. Enter a
name and setup
the rest of the parameters as follows:
Runtime vm parms
=-Dorg.apache.commons.logging.Log=org.apache.commons.logging.impl.Log4JLogger
-Djiplet.container.home=$CAFESIP_HOME/jiplet
-Djiplet.jmx.enabled=true -Djiplet.jmx.rmi.port=9999
Class =
org.cafesip.jiplet.standalone.boot.Main
- Jiplet console: Run it as a standard webapp under a
servlet container like
Tomcat. You'll need to add user/password for logging into the webapp -
if
you're using Tomcat, add your username/password in Tomcat's
conf/tomcat-users.xml file. Read the configuration howto for more
details.
The following diagrams show the same Run dialog box settings.


If you want to run the piplet container as a Jboss application:
- Setup an environment variable called JBOSS_HOME pointing to
the directory where Jboss is installed.
- Start the Jboss server by executing the following command:
$ cd $JBOSS_HOME/bin
$ run -c default
- Run the ant target - deploy-jboss. Note that you must have
run the compile, build-jboss and build-console targets.
Use your browser to access te Mgmt application at
http://localhost:8080/jiplet-console
|