Why Use Docker with Payara Platform? Benefits for your Business

Payara

There’s a lot of noise revolving around Docker at the moment, and with the current industry focus on the cloud, there’s a good reason for that.

I hope you would already know why you might want to use Payara Platform in your business, so in this blog I’m going to focus more on why you’d specifically want to use it with Docker in a “business” context. For a start, if you’re unfamiliar with Docker, please refer back to our introductory blog: What is Docker and How is it Used with the Payara Platform for a primer.

 

 {{cta(‘cc5e0501-132c-40a9-b3c9-5c2e8a369384’)}}

 

It’s Lighter than a “Full-Fat” Virtual or Physical Machine

In a micro-services architecture, spinning up a whole virtual or physical machine to run a micro-service can be a bit overkill. As will have been mentioned in the “What is Docker?” blog, Docker containers are not full Virtual Machines, and so they can use fewer resources than VMs by being more efficient with the resources they are provided (even when idle, a full OS is typically doing quite a bit in the background). Using fewer resources can potentially help you save money by reducing the need to run multiple VMs in the cloud or on your servers.

 

It Can be Simple to Scale

Docker containers are lighter than full VMs so that you can run more of them per machine. As starting a container is similar to simply starting up a process, Docker can be easily taken advantage of to allow scalable architectures.

 

There are many solutions already using Docker, with some of the most well-known ones being OpenShift, Amazon ECS, Kubernetes, and Docker Swarm. Each of these solutions use Docker in some capacity and are touted for their scalability; with a bit of wrangling you can even get them to auto-scale to demand.

 

We should have a separate blog coming at a later date as to why you may want to use Kubernetes with Docker – keep your eyes peeled! In a single sentence though, combining Kubernetes & Docker with micro-services architectures allows for the creation of very easy to scale and update environments.

 

It’s Almost Tailor-Made for Micro-Services

Those paying attention may have noticed that the previous two points about the Docker containers being both small and scalable – bywords of the micro-services architecture. If your application is designed in the micro-services style (key point! You can’t jam a square peg into a round hole without ruining the peg or the hole), you can run each of your micro-services in separate Docker containers, allowing you to provide good separation of your micro-service containers. Running them in separate containers also lets you edit and scale your micro-services independently of one another.

 

You Can Essentially Put Your Setup into Version Control

In a certain sense, using the Payara Platform with Docker allows you to put your setup of Payara Platform (as in the Dockerfile) into version control. Using pre-boot & post-boot command files or the asadmin CLI, you can set up your Dockerfile to perform the setup of the Payara Platform instance and do any deployments upon creation of the Docker container, and this can afford easier development by multiple people, as well as allowing you to track and revert changes.

 

You can even extend this by having your Dockerfile download a particular version of the Payara Platform, affording you the ability to make upgrading the version of Payara Platform that you’re using as easy as changing a number (assuming nothing breaks of course! But then you can just revert the change; you see? It’s all connected…)

 

With the availability of Docker Hub and its integrations with GitHub & Bitbucket, it’s not a stretch to make an argument for this.

 

Wrapping Up

This was a very high-level view of why you may want to consider using Docker with Payara Micro for your next or current application – by all means, this is not an exhaustive list, just as much as it likely doesn’t apply to all situations! It should hopefully though spark your interest and give you an idea of what you could possibly achieve using Docker with Payara Micro.  If you’re already using Payara Micro with Docker, we’d love to hear what you’re doing with it in the comments below! 

 

Click here to learn more about Payara Micro for containerized Java EE (Jakarta EE) microservices deployments or get started with Payara Micro:

 

{{cta(‘4129273b-d6b4-4ef3-8fb7-412a2d0dfdfb’)}}

 

 

 

Comments (2)

Post a comment

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

Payara needs the contact information you provide to us to contact you about our products and services. You may unsubscribe from these communications at any time. For information on how to unsubscribe, as well as our privacy practices and commitment to protecting your privacy, please review our Legal & Privacy Policy.

  1. Gelson Nascimento

    Hi, Andrew.

    We are migrating services to docker swarm using payara-micro, which met our needs. We are studying the jax-ws service publication; it would be possible to use the payara-micro for this.
    best regards
    Gelson Nascimento

    1. Ondro Mihalyi

      Hi Gelson,

      JAX-WS is one of the few Java EE components that’s not supported by Payara Micro out of the box. To use SOAP, the only option is to include a library like Apache CXF into your application and do everything with that library.

      However, when using Docker, the advantages of Payara Micro are fading. Payara Server, which supports JAX-WS out of the box, is equally simple to use in Docker and might be more convenient for you instead.

Related Posts

payara qube logo 5 minutes
Payara

Payara Cloud Is Now part of Payara Qube family of Unified Platforms for Enterprise Java

Payara Cloud is becoming part of Payara Qube family of Java application deployment runtimes. This move reflects how the […]

Payara promotional graphic showing transition from Spring to Jakarta EE, including technology logos, a code icon and arrows leading from Spring to Jakarta EE. 6 minutes
Jakarta EE

From Spring Boot To Jakarta EE 11: How Payara Starter Eases The Transition

If you’ve been living in the Spring ecosystem, you’re used to fast project setup. Spring Initializr gives you a […]

Promotional graphic for a podcast episode titled “Why Open Source is the Future of Business Innovation - A conversation with Arun Gupta”. The podcast is hosted by Payara Community. The right side features a photo of the speaker, Arun Gupta, labeled as a “VP, Developer Experience at JetBrains”. The design uses dark blue and teal backgrounds with coral and fish illustrations. 2 minutes
Community

Payara Podcast – Why Open Source is the Future of Business Innovation – A Conversation with Arun Gupta

Open source is no longer a developer-only concern — it’s at the heart of how modern businesses innovate, build […]