DZone
Thanks for visiting DZone today,
Edit Profile
  • Manage Email Subscriptions
  • How to Post to DZone
  • Article Submission Guidelines
Sign Out View Profile
  • Post an Article
  • Manage My Drafts
Over 2 million developers have joined DZone.
Log In / Join
Refcards Trend Reports Events Over 2 million developers have joined DZone. Join Today! Thanks for visiting DZone today,
Edit Profile Manage Email Subscriptions Moderation Admin Console How to Post to DZone Article Submission Guidelines
View Profile
Sign Out
Refcards
Trend Reports
Events
Zones
Culture and Methodologies Agile Career Development Methodologies Team Management
Data Engineering AI/ML Big Data Data Databases IoT
Software Design and Architecture Cloud Architecture Containers Integration Microservices Performance Security
Coding Frameworks Java JavaScript Languages Tools
Testing, Deployment, and Maintenance Deployment DevOps and CI/CD Maintenance Monitoring and Observability Testing, Tools, and Frameworks
Culture and Methodologies
Agile Career Development Methodologies Team Management
Data Engineering
AI/ML Big Data Data Databases IoT
Software Design and Architecture
Cloud Architecture Containers Integration Microservices Performance Security
Coding
Frameworks Java JavaScript Languages Tools
Testing, Deployment, and Maintenance
Deployment DevOps and CI/CD Maintenance Monitoring and Observability Testing, Tools, and Frameworks
  1. DZone
  2. Software Design and Architecture
  3. Cloud Architecture
  4. Getting Started With IBM WAS Liberty

Getting Started With IBM WAS Liberty

Follow along as you get an introduction to IBM's WAS Liberty Profile server. In the first part of a series, see what you can expect to do when setting up a server.

Roan Bester user avatar by
Roan Bester
·
Oct. 25, 16 · Tutorial
Like (3)
Save
Tweet
Share
14.67K Views

Join the DZone community and get the full member experience.

Join For Free

For a recent project requiring WebSockets and JMS, I needed to make use of IBM’s WAS Liberty Profile server, as WAS 8.5 ND only supports JEE 6. I want to share some of my learnings with you, starting with the basics: a short intro on what to expect and setting up a server.

Highlights

Some highlights of WAS Liberty are:

  • The server configuration is easily version controlled, as the server is separate from the WAS Liberty runtime.
  • You can use the server as a deployment artifact (as opposed to an EAR or WAR).
  • You choose which features you want to use and the server runtime spins up only those. This makes for faster start-up times and less waste. For a recent project, I used parts of JEE 7 (web sockets, JMS, CDI, etc).
  • The runtime comes with various flavors:
    • Manual ZIP download (which is what I did, you can grab a JEE7 at WASDev)
    • You can install it via Eclipse and Websphere Developer Tools (I used eclipse Neon and pointed the WAS Liberty tools to my already-installed JEE 7 runtime);
    • You can install it using the Liberty Maven plugin, which also comes with toys to manage the server as part of integration tests.
    • You can use a Docker image. Have a look at this article on Eclipse WDT and Docker. 
  • Once the server is running, you can hot-deploy applications and configuration to it, no restart required.
  • You can develop on it for free and run a VERY small prod setup with it (total JVM heap space of 2GB across all Liberty servers);        
  • If your company is already using WAS Network Deploy, your license probably already includes Liberty.

Basics for Getting Started  

Luckily, IBM has created extensive tutorials and articles on various key concepts, including getting started with Liberty in Eclipse. So I'm not going to re-add everything here, although in a future article, I will be showing you some of its tricks.

So, to get started quickly, read on to create a server. If you're interested in more, go over to WASDev and browse through all the articles.

Create a Server

Once you have a runtime installed (or a Maven project available to do it), you can create a WAS Liberty server as follows.

Eclipse

From eclipse (assuming you have WDT - Websphere Developer Tools - installed via eclipse marketplace) go to the Servers tab, right-click and New -> Server -> Websphere Application Server Liberty and fill out the wizard. It will ask you to point to an existing installation or you can download it via WDT at this stage.

Command Line

From the command line, go to the Liberty Runtime installation location (e.g. /WAS-Liberty), then cd wlp/bin && server create myServer” to make it happen. You can then start the server with “ server start testServer” to start it I the background, or “server run defaultServer” to see how it starts up in the cmd/bash/whatever you’re using.

You can read more on available commands here.

Summary

WAS Liberty is a lot simpler to use than WAS traditional. If you can't use it for production yet, please consider using it in development, due to its fast spin-up time. Just note: as Liberty can include features not supported by WAS Classic/Traditional, make sure your dev Liberty install has the same features as your production runtime.

Keep an eye out for my follow-up article(s) on how to build a WebSocket server with WAS Liberty, build and packaging with Maven, and using the WAS Liberty built-in JMS capabilities.

Eclipse Application server application dev Command (computing) Apache Maven Production (computer science) Docker (software) Download

Opinions expressed by DZone contributors are their own.

Popular on DZone

  • The Importance of Delegation in Management Teams
  • The Data Leakage Nightmare in AI
  • Top 12 Technical Skills Every Software Tester Must Have
  • Secrets Management

Comments

Partner Resources

X

ABOUT US

  • About DZone
  • Send feedback
  • Careers
  • Sitemap

ADVERTISE

  • Advertise with DZone

CONTRIBUTE ON DZONE

  • Article Submission Guidelines
  • Become a Contributor
  • Visit the Writers' Zone

LEGAL

  • Terms of Service
  • Privacy Policy

CONTACT US

  • 600 Park Offices Drive
  • Suite 300
  • Durham, NC 27709
  • support@dzone.com
  • +1 (919) 678-0300

Let's be friends: