Liberty and Eclipse: Installing the development environment

Share this post:

WebSphere Liberty is the next generation application server. Liberty and Eclipse make a great local development environment for developing Java EE applications. To develop Java EE applications to deploy to Liberty, you’re going to need a Liberty development environment. You’ll also need an integrated development environment (IDE) for editing your code. While any Java EE IDE will work, the Eclipse IDE is one of the best, if for no other reason than because IBM has developed plugins for Eclipse for developing Liberty applications and for working with Bluemix.

In this excerpt from “Java EE, the next inception: Install a local Java EE development environment for WebSphere Liberty,” we’ll see how to install a Java EE development environment using Liberty and Eclipse.

Next, we’ll discuss common development tasks and how to perform them in this environment, starting with creating a Liberty server using Eclipse.

To start at the beginning of this series, see WebSphere Liberty: Developing Java EE applications for the cloud.

Install the development environment

To develop Java applications for Liberty, it’s helpful to have a local development environment consisting not only of the Liberty runtime environment, but also the Eclipse development tools. This section shows how to install and configure a development environment consisting of Eclipse and Liberty.

To install Liberty and Eclipse, you will:

These steps are explained in detail below.

1. Set up installation directories

The first question is where should you install Eclipse and Liberty? The Java runtime (JRE, JDK, or SDK) is an executable and the Eclipse IDE installs like an executable, so they are typically installed in the computer’s default directory for applications or program files. But Eclipse requires a workspace directory, and Liberty requires an installation directory. Where should these directories go?

Pretty much any set of directories will work. Table 1 shows a set of directories that work well. (You should name the directory after the version of Liberty that you’re installing. Therefore, the wlp directory name used here assumes you’re installing v8.5.5.6.)

Table 1. Sample installation directory structure
Directory Purpose
/dev All development artifacts
/dev/ApplicationServers Server product installs
/dev/ApplicationServers/wlp- Liberty profile v8.5.5.6
/dev/Eclipse Eclipse artifacts
/dev/Eclipse/workspace Default Eclipse workspace
/dev/git Projects from Git

Whatever directory structure you choose, this installation process will need these two directories:

  • <Liberty_Root> – Where you install LibertyFor example: /dev/ApplicationServers/wlp-
  • <Eclipse_Workspace> – Where you create Eclipse’s workspaceFor example: /dev/Eclipse/workspace

2. Install a JDK

Liberty requires a separately installed JRE, and Eclipse requires a JDK. Since a JDK includes a JRE, you will install a JDK. These resources can provide help:

You have now installed a JDK that will be used by Liberty and Eclipse.

3. Install Liberty profile

To run and test your applications locally, you’ll need a local Liberty profile and server. Remember that this procedure does not install the full WebSphere Application Server product (which includes the Full profile and Liberty profile). Rather, you will install a Liberty developer build, which includes the Liberty profile only. It’s a small download that is quick to install:

Store the download file somewhere convenient so that you can reinstall it whenever you need to.

To install the Liberty download, simply unpack the archive. Put the resulting wlp directory somewhere convenient such as <Liberty_Root>. In the Java EE 7 build of Liberty, the feature manager is configured by default to enable the javaee-7.0 feature.

The Liberty documentation is available in Liberty profile overview in WebSphere Application Server (Distributed and IBM i operating systems), Version 8.5.5.

The Liberty profile is now installed in <Liberty_Root>/wlp.

4. Install Eclipse

To develop Java applications for Liberty, it’s helpful to have an integrated development environment (IDE). There are several available and you can use the one you prefer. This tutorial uses Eclipse because it’s free and because this tutorial uses some helpful Java development toolkits from IBM that run in Eclipse.

Install the Eclipse IDE for Java EE Developers:

  • The latest version (code named Mars, as if this writing) is available from Eclipse Downloads.
  • Install this package: Eclipse IDE for Java EE Developers.
  • It’s easiest to use the Eclipse Installer. Otherwise, download and install an Eclipse Package by following the Eclipse/Installation directions.

Eclipse with the Java development tools is now installed so you can run it.

To run Eclipse, see Running Eclipse in Eclipse documentation – Current Release.

You now have Eclipse installed and running.

5. Install the WebSphere Developer Tools

The WebSphere Developer Tools make it easier to use Eclipse to deploy applications to WebSphere Application Server, including the Liberty profile.

You can also use the Install button for WAS Liberty Profile V8.5.5 to download and install the tools. Drag it from the web page and drop it on the Eclipse window.

The documentation is available from IBM WebSphere Developer Tools, Version 8.5.

The WebSphere Developer Tools are now installed in Eclipse.

6. Install Liberty Server in Eclipse

With a local Liberty profile installed, you’ll need a Liberty server, and you’ll need to link to it in Eclipse so that you can use it in Eclipse.

Create a Liberty server by creating these elements (the names shown here are for Liberty v8.5.5.6):

  • Runtime environment in Eclipse – Named wlp-, with the path <Liberty_Root>/wlp.
  • Server in the Liberty profile – Named defaultServer.
  • Server in Eclipse – Named wlp- defaultServer at localhost.

Experienced users can perform all of this in the New Server dialog. For a more step-by-step process, see below.

You now have a Liberty server created and accessible from Eclipse.


At this point, you have installed Liberty and Eclipse, and connected them together so that you can use Eclipse to deploy applications to Liberty. The next section explains common tasks for using Eclipse with Liberty.


—Bobby Woolf (@bobby_woolf)

Add Comment
No Comments

Leave a Reply

Your email address will not be published.Required fields are marked *

More Compute Services Stories

Scaling analytics with Message Hub on IBM Bluemix

Building an analytics application with realtime data, when you have no control over that data, can create hours of worry for a developer. Are the data volume estimates accurate? What will happen if the volume suddenly spikes? Can we scale up, or will our application be overloaded? IBM Message Hub is a developer-friendly service that can help manage these problems, leaving developers free to focus on the analytics.

Continue reading

Identifying insecure configurations with IBM Vulnerability Advisor

Security is hard. Using IBM Vulnerability Advisor on Bluemix Containers Service removes some of your security concerns by identifying vulnerable packages or policy violations in your container image. It now goes further by identifying insecure application configurations and Vulnerability Advisor advises how to correct them.

Continue reading

5 Reasons You Can’t Miss the “Getting Started with Workload Scheduler Service on Bluemix” Webinar

To provide you with details about our Workload Scheduler service, join us on Wednesday, March 23rd at 10 AM EST. During the webinar you’ll be inspired and entertained with cutting-edge technologies, apps, and more. Here’s 5 reasons why you should register!

Continue reading