author Zvone Gazvoda, Mar 18, 2018 Kumuluzee swagger

We’re happy to announce the initial version of the KumuluzEE Swagger extenion v1.0.0 for the KumuluzEE framework.

KumuluzEE Swagger (OpenAPI 2.0) extension provides support for documenting APIs using Swagger/OpenAPI v2 compliant annotations. Extension automatically hooks-up servlet that exposes API specification on endpoint /api-specs//swagger.[json|yaml]. Extension also provides SwaggerUI which is added to your project to visualize API documentation and allow API consumers to interact with API endpoints.

author Zvone Gazvoda, Mar 17, 2018 Kumuluzee cors

KumuluzEE CORS version 1.0.3 is now released. The new version now works together with other extensions.

author Urban Malc, Mar 13, 2018 Kumuluzee Testing Arquillian

Integration testing with the KumuluzEE framework has just become a lot easier with the KumuluzEE Arquillian Container Adapter.

The newly developed adapter brings support for the popular Arquillian framework. KumuluzEE Arquillian Container Adapter starts the KumuluzEE server before running the tests, which enables the tests to interact with the environment closely resembling the one in production.

author Tilen Faganel, Mar 11, 2018 Kumuluzee

We’re exited to announce the first Beta of KumuluzEE version 3.0.0. It’s the first of a series of prerelease versions that will feature full support for Java EE 8 as a baseline for KumuluzEE components, replacing Java EE 7. We’re also bringing better support for Java 9 and above, with continuously increased streamlined modules support throughout the betas.

This release focuses on updating all Java EE components available in KumuluzEE to their Java EE 8 versions as well as further integration between them. Updated components are:

  • JSF 2.3
  • JPA 2.2
  • JAX-RS 2.1
  • CDI 2.0
  • Bean Validation 2.0
  • JSON-P 1.1

All implementations of the listed components have been updated to the latest Java EE component versions, so you’re free to use any of them. In addition to the ones listed, this updated also brings the following new components that are new to KumuluzEE:

  • JSON-B 1.0
  • Java Mail 1.6
author Zvone Gazvoda, Feb 17, 2018 Kumuluzee

Our team was presenting KumuluzEE at Javantura v5 in Zagreb: Java EE Microservices on Kubernetes With KumuluzEE.

Thank you to everyone who joined our session!

author Tilen Faganel, Feb 9, 2018 Kumuluzee

We are announcing the availability of KumuluzEE version 2.5.2. This version brings important features and fixes to various bugs.

author Urban Malc, Jan 25, 2018 Kumuluzee Discovery

We’re announcing the availability of the KumuluzEE Discovery 1.1.0 extension, an update to the microservice discovery framework that uses etcd or Consul as the backend.

author Urban Malc, Jan 24, 2018 Kumuluzee Metrics

KumuluzEE Metrics, an implementation of the Eclipse MicroProfile Metrics API, has been updated to support the Eclipse MicroProfile Metrics 1.1.

New version adds a flag reusable to the Metadata object, which primarily means, that a metric can be injected multiple times in multiple places. Acquisition of global tags was changed from environment variable MP_METRICS_TAGS to MicroProfile Config property with the same name. This means, that global tags can additionally be supplied via the MicroProfile Config extension.

author Jan Meznarič, Jan 24, 2018 Kumuluzee Config

KumuluzEE MicroProfile Config, an implementation of the Eclipse MicroProfile Config API, has been updated to support the Eclipse MicroProfile Config 1.2.

New version adds the support for the array converter that converts configuration values into arrays of types with available converters or into types Array, List or Set. Common sense converter, used where there is no corresponding type of converters provided for a given class, and a Class converter are also supported.

author Urban Malc, Jan 19, 2018 Kumuluzee Config

We’re announcing the availability of KumuluzEE Config 1.1.0, an update to the configuration management extension, which extends basic configuration framework with etcd and Consul configuration sources.

author Zvone Gazvoda, Jan 14, 2018 Kumuluzee Swagger

KumuluzEE Swagger (OpenAPI 2.0) extension provides support for documenting APIs using Swagger/OpenAPI v2 compliant annotations. Extension automatically hooks-up servlet that exposes API specification on endpoint /api-specs/<jax-rs application-base-path>/swagger.[json|yaml]. Extension also provides SwaggerUI which is added to your project to visualize API documentation and allow API consumers to interact with API endpoints.

More details about Swagger Specification.

Usage

You can enable the KumuluzEE Swagger support by adding the following dependency:

<dependency>
    <groupId>com.kumuluz.ee.swagger</groupId>
    <artifactId>kumuluzee-swagger</artifactId>
    <version>${kumuluzee-swagger.version}</version>
</dependency>
author Zvone Gazvoda, Jan 14, 2018 Kumuluzee Openapi

KumuluzEE OpenAPI extension allows you to document microservice APIs using OpenAPI v3 compliant annotations. Extension will automatically hook-up servlet that will serve your API specifications on endpoint /api-specs/<jax-rs application-base-path>/openapi.[json|yaml]. Furthermore, extensions allows you to integrate Swagger-UI into your microservice that will visualize APIs documentation and allow you to interact with your APIs resources.

More details: OpenAPI v3 Specification.

Usage

You can enable KumuluzEE OpenAPI support by adding the following dependency:

<dependency>
    <groupId>com.kumuluz.ee.openapi</groupId>
    <artifactId>kumuluzee-openapi</artifactId>
    <version>${kumuluzee-openapi.version}</version>
</dependency>
author Zvone Gazvoda, Jan 10, 2018 Kumuluzee Kubernetes

Learn how to deploy and run KumuluzEE microservices on Kubernetes by reading the following DZone article: Java EE Microservices on Kubernetes With KumuluzEE.

author Marko Škrjanec, Dec 19, 2017 Kumuluzee Health

We’re happy to announce the initial version of the KumuluzEE Health extension v1.0.0 for the KumuluzEE framework.

author Žan Ožbot, Dec 17, 2017 Kumuluzee Reactive

KumuluzEE Reactive is an extension for developing reactive microservices for the KumuluzEE microservice framework.

KumuluzEE Reactive provides integration with Vert.x distributed event bus, integration with Vert.x service discovery, easy-to-use annotations for developing microservices that listen to or produce messages on the Vert.x distributed event bus and a service discovery bridge for importing and exporting services from Vert.x Service Discovery to KumuluzEE Discovery (for Consul and etcd).

author Žan Ožbot, Dec 17, 2017 Kumuluzee Reactive

We are announcing the release of KumuluzEE Reactive extension for developing reactive microservices and integration with reactive streams (Vert.x and similar).

author Zvone Gazvoda, Dec 14, 2017 Kumuluzee Kubernetes

Implementing cloud-native applications by following microservice architecture brings quite a few challenges. Because of the distributed nature, microservices have to be able to deal with unexpected failures caused by node crashes, deadlocks, connectivity issues etc. To build truly resilient systems, failures have to be tackled with different mechanisms such as circuit breakers, retries/timeouts and health checks, at the same time in order to cover all the aspects of the failures.

author Marko Škrjanec, Dec 13, 2017 Kumuluzee Health

KumuluzEE Health extension health check set has been expanded with an EtcdHealthCheck.

author Marko Škrjanec, Dec 6, 2017 Kumuluzee Health

KumuluzEE Health extension health check set has been expanded with a HttpHealthCheck.

author Zvone Gazvoda, Dec 3, 2017 Kumuluzee Kubernetes

Today Kubernetes is one of the most commonly used runtime platforms for the containerized applications. Providing automatic binpacking, horizontal scaling, automated rollouts and rollbacks, self-healing, service discovery, load balancing and other services out of the box, Kubernetes is a platform that suits microservices down to the ground.

However, equally as important as the utilities provided by the runtime environment is the ability of microservice framework to exploit provided utilities. In this three-part blog, we will demonstrate how KumuluzEE microservice framework is able to make use of Kubernetes for optimal execution of the microservices.

author Jan Meznarič, Nov 9, 2017 Kumuluzee Architecture

KumuluzEE is fully compliant with the Eclipse MicroProfile 1.2 specification. It provides the implementations of the following MicroProfile APIs:

  • Config 1.1
  • Health Check 1.0
  • Metrics 1.0
  • Fault Tolerance 1.0
  • JWT Authentication 1.0

You can use our online pom generator to quicly generate pom files with selected profiles or individual Maven dependencies.

author Eva Zupancic, Oct 29, 2017 Kumuluzee

When selecting a framework for Java EE microservices, you should consider the start-up time, size and memory footprint of a microservice.

The article Java EE microservices: why start-up time and size matter shows an interesting comparison of MicroProfile Java EE frameworks, including WebSphere Liberty, WildFly Swarm, Payara, TomEE and KumuluzEE.

KumuluzEE has achieved the fastest start-up time of 3 seconds and the smallest JAR size (11 MB):

Microservice architecture

Also, it has the smallest memory footprint:

Microservice architecture

More: Java EE microservices: why start-up time and size matter

author Zvone Gazvoda, Oct 27, 2017 Kumuluzee Openapi

KumuluzEE OpenAPI was recently updated! with separate dependency for the OpenAPI UI. Check KumuluzEE OpenAPI - Updated

KumuluzEE OpenAPI extension allows you to document microservice APIs using OpenAPI v3 compliant annotations. Extension will automatically hook-up servlet that will serve your API specifications on endpoint /api-specs/<jax-rs application-base-path>/openapi.[json|yaml]. Furthermore, extensions allows you to integrate Swagger-UI into your microservice that will visualize APIs documentation and allow you to interact with your APIs resources.

More details: OpenAPI v3 Specification.

Usage

You can enable KumuluzEE OpenAPI support by adding the following dependency:

<dependency>
    <groupId>com.kumuluz.ee.openapi</groupId>
    <artifactId>kumuluzee-openapi</artifactId>
    <version>${kumuluzee-openapi.version}</version>
</dependency>

OpenAPI configuration

When kumuluzee-openapi dependency is included in the project, you can start documenting your REST API using Swagger-Core Annotations.

Documenting application class

@SecurityScheme(name = "openid-connect", type = SecuritySchemeType.OPENIDCONNECT, 
                openIdConnectUrl = "http://auth-server-url/.well-known/openid-configuration")
@OpenAPIDefinition(info = @Info(title = "Rest API", version = "v1", description = "JavaSI API for managing conference.", 
                    security = @SecurityRequirement(name = "openid-connect"), servers = @Server(url ="http://localhost:8080/v1")))
@ApplicationPath("v1")
public class JavaSiApplication extends Application {...}

Documenting resource class and operations

@Path("sessions")
@Consumes(MediaType.APPLICATION_JSON)
@Produces(MediaType.APPLICATION_JSON)
public class SessionsResource {

    @Operation(description = "Returns list of sessions.", summary = "Sessions list", tags = "sessions", responses = {
            @ApiResponse(responseCode = "200",
                    description = "List of sessions",
                    content = @Content(
                            schema = @Schema(implementation
                            = Session.class)),
                    headers = {@Header(name = "X-Total-Count",
                            schema = @Schema(type = "int"))}
                    )})
    @SecurityRequirement(name = "openid-connect")
    @GET
    public Response getSessions() {...} 
    ...
}
author Zvone Gazvoda, Oct 26, 2017 Kumuluzee Openapi

KumuluzEE is adding support for OpenAPI v3! KumuluzEE OpenAPI extension provides OpenAPI v3 compliant annotations that you can use to provide OpenAPI v3 specification for your APIs.

author Zvone Gazvoda, Oct 25, 2017 Kumuluzee Swagger

KumuluzEE Swagger was recently updated! with separate dependency for the Swagger UI. Check KumuluzEE Swagger - Updated

KumuluzEE Swagger (OpenAPI 2.0) extension provides support for documenting APIs using Swagger/OpenAPI v2 compliant annotations. Extension automatically hooks-up servlet that exposes API specification on endpoint /api-specs/<jax-rs application-base-path>/swagger.[json|yaml]. Extension also provides SwaggerUI which is added to your project to visualize API documentation and allow API consumers to interact with API endpoints.

More details about Swagger Specification.

Usage

You can enable the KumuluzEE Swagger support by adding the following dependency:

<dependency>
    <groupId>com.kumuluz.ee.swagger</groupId>
    <artifactId>kumuluzee-swagger</artifactId>
    <version>${kumuluzee-swagger.version}</version>
</dependency>

Swagger configuration

When kumuluzee-swagger dependnecy is included in the project, you can start documenting your REST API using Swagger-Core Annotations.

Documenting application class

@SwaggerDefinition(info = @Info(title = "CustomersAPI", version = "v1.0.0"), host = "localhost:8080")
@ApplicationPath("v1")
public class CustomerApplication extends Application { ... }

Documenting resource class and operations

@Path("customer")
@Api
@Produces(MediaType.APPLICATION_JSON)
public class CustomerResource {

    @GET
    @ApiOperation(value = "Get customers list", tags = {"customers"}, notes = "Returns a list of customers.")
    @ApiResponses(value = {@ApiResponse(message = "List of customers", code = 200, response = Customer.class)})
    public Response getCustomers() {

        List<Customer> customers = new ArrayList<>();
        Customer c = new Customer("1", "John", "Doe");

        customers.add(c);

        return Response.status(Response.Status.OK).entity(customers).build();
    }
}
author Zvone Gazvoda, Oct 24, 2017 Kumuluzee Swagger

KumuluzEE Swagger extension is released! You can now provide Swagger/OpenAPI v2 specification for your APIs simply by including KumuluzEE Swagger dependency and annotating your REST API. KumuluzEE Swagger will expose Swagger specification for your API when your microservice is started.

author Urban Malc, Sep 29, 2017 Kumuluzee Discovery

We have published an interesting article to the Eclipse newsletter, in which we talk about the importance of service discovery in the microservice architecture. We also present some advanced scenarios of service discovery and how to handle them with the KumuluzEE Discovery extension.

author Jan Meznarič, Sep 28, 2017 Kumuluzee Architecture

We published a tutorial on developing a cloud-native Java EE microservice application, using KumuluzEE microservice framework and KumuluzEE extensions.

In this tutorial we develop a sample application for managing customers and their orders. The application consists of two microservices; one for managing customer entities and one for managing order entities. We demonstrate important cloud-native concepts and functionalities that are essential in microservice architecture, such as dynamic configuration (with config server), service discovery, fault tolerance, centralized logging, performance metrics collection, and security mechanisms.

author Zvone Gazvoda, Sep 26, 2017 Kumuluzee Cors

KumuluzEE CORS filter extension for the KumuluzEE microservice framework supports:

  • Browser script perspective: Allowing cross-domain requests, which are subject to tihter controls on the types of data that is exchanged. Cookies, for instance, are blocked unless specifically requested by the XHR author and allowed by the cross-domain web-service.
  • Web service perspective: By utilising the origin URL reported by the browser the target cross-domain web service can determine, based on its origin policy, wheather to allow or deny the request.

Usage

To enable Cross-Origin support for your microservice you need to include the following dependency:

<dependency>
    <groupId>com.kumuluz.ee.cors</groupId>
    <artifactId>kumuluzee-cors</artifactId>
    <version>${kumuluzee-cors.version}</version>
</dependency>

CORS filter configuration

CORS filter can be configured in two ways: using @CrossOrigin annotation or using servlet filter by providing cors-filter configuration section in prefered config source (i.e. config.yaml, etcd etc.).

@CrossOrigin annotation

Annotation can be put on the following classes of the JAX-RS application:

  • Application class (with @ApplicationPath annotation)
  • Resource classes (classes with annotation @Path)
  • Resource operations
author Marko Škrjanec, Sep 21, 2017 Kumuluzee Health

We are announcing the initial version of KumuluzEE Health extension. KumuluzEE Health is a health check extension for the KumuluzEE microservice framework.

author Zvone Gazvoda, Sep 19, 2017 Kumuluzee Cors

We are announcing the release of KumuluzEE CORS extension providing Cross-Origin Resource Sharing support to Java web applications.

author Benjamin Kastelic, Sep 17, 2017 Kumuluzee Security

KumuluzEE Security is a security extension for the KumuluzEE microservice framework. It provides support for OpenID authentication through standard Java EE security annotations for roles. It is specifically targeted towards securing REST services. Roles are mapped to the selected OpenID provider. KumuluzEE Security has been designed to work with different OpenID providers. Currently only Keycloak is supported. Contributions for other OpenID providers are welcome.

Usage

You can enable the KumuluzEE Security authentication with Keycloak by adding the following dependency:

<dependency>
    <groupId>com.kumuluz.ee.security</groupId>
    <artifactId>kumuluzee-security-keycloak</artifactId>
    <version>${kumuluzee-security.version}</version>
</dependency>
author Tilen Faganel, Sep 15, 2017 Kumuluzee

KumuluzEE version 2.4.1 just was released. The new minor release includes several bug fixes regarding the new kumuluzee-maven-plugin for uber JAR support.

author Urban Malc, Sep 15, 2017 Kumuluzee Discovery

KumuluzEE Discovery is a service discovery extension for the KumuluzEE microservice framework. It provides support for service registration, service discovery and client side load balancing.

KumuluzEE Discovery provides full support for microservices packed as Docker containers. It also provides full support for executing microservices in clusters and cloud-native platforms with full support for Kubernetes.

KumuluzEE Discovery has been designed to support modularity with pluggable service discovery frameworks. Currently, etcd and Consul are supported. In the future, other discovery frameworks will be supported too (contributions are welcome).

Usage

You can enable etcd-based service discovery by adding the following dependency:

<dependency>
    <groupId>com.kumuluz.ee.discovery</groupId>
    <artifactId>kumuluzee-discovery-etcd</artifactId>
    <version>${kumuluzee-discovery.version}</version>
</dependency>

You can enable Consul-based service discovery by adding the following dependency:

<dependency>
    <groupId>com.kumuluz.ee.discovery</groupId>
    <artifactId>kumuluzee-discovery-consul</artifactId>
    <version>${kumuluzee-discovery.version}</version>
</dependency>
author Benjamin Kastelic, Sep 12, 2017 Kumuluzee Security

We are announcing the release of KumuluzEE Security extension which provides support for OpenID authentication through standard Java EE security annotations.

More details at KumuluzEE Security.

author Luka Šarc, Sep 11, 2017 Kumuluzee Fault tolerance

KumuluzEE Fault Tolerance is a fault tolerance extension for the KumuluzEE microservice framework. It provides support for fault tolerance and latency tolerance with circuit breaker, bulkhead, timeout, retry and fallback patterns. KumuluzEE Fault Tolerance supports basic fault tolerance configuration using annotations. Additionally, configuring via KumuluzEE Config is supported. Dependency calls are wrapped and executed using Hystrix, a latency and fault tolerance library.

Usage

You can enable the KumuluzEE Fault Tolerance with Hystrix by adding the following dependency:

<dependency>
    <groupId>com.kumuluz.ee.fault.tolerance</groupId>
    <artifactId>kumuluzee-fault-tolerance-hystrix</artifactId>
    <version>${kumuluzee-fault-tolerance.version}</version>
</dependency>
author Jan Meznarič, Sep 9, 2017 Kumuluzee Rest

We’re happy to announce the initial version of the KumuluzEE REST extension v1.1.0 for the KumuluzEE framework.

author Urban Malc, Sep 9, 2017 Kumuluzee Discovery

We’re happy to announce the initial version of the KumuluzEE Discovery extension v1.0.0 for the KumuluzEE framework.

author Jan Meznarič, Sep 9, 2017 Kumuluzee Config

We’re happy to announce the initial version of the KumuluzEE Config extension v1.0.0 for the KumuluzEE framework.

author Tilen Faganel, Sep 8, 2017 Kumuluzee

We’re announcing the availability of KumuluzEE version 2.4.0.

This version marks an important milestone for the framework as it brings much needed major new features that were missing and improving the JTA integration, config framework, logging and the extensions subsystem, as well as fixed various bugs and aligned with the upstream versions of all the EE components and libraries.

author Marko Škrjanec, Sep 8, 2017 Kumuluzee Logs

We are announcing the release of KumuluzEE Logs extension version 1.3.0.

This version marks an important milestone, since the extension was restructured and Java Util Logging implementation was added to the existing Log4J2 implementation. Beside the restructuring and another implementation the logging extension can now be configured by KumuluzEE Config.

More details at KumuluzEE Logs.

author Luka Šarc, Sep 3, 2017 Kumuluzee Fault tolerance

We are announcing the release of KumuluzEE Fault Tolerance extension which provides support for fault tolerance patterns. Circuit breaker, retry, bulkhead, timeout and fallback patterns are available. We are partially supporting Microprofile Fault Tolerance and are planning to fully support the specification with the final release of API.

More details at KumuluzEE Fault Tolerance.

author Zvone Gazvoda and Matjaz B. Juric , Aug 13, 2017 Kumuluzapi Api monitoring

Monitoring of APIs is one of the essential functionalities of API Management tools. API Gateways collect and record different metrics of API invocations.

API Monitoring in KumuluzAPI

KumuluzAPI provides multiple API monitoring views with different granularity. One of the most important monitoring views provided on the level of the API. KumuluzAPI allows you to view metrics for each environment and runtime platform on which API is running. The following metrics are recorded for each API:

  • Usage - shows number of API calls on the level of API, API endpoint and client application.
  • Response type - shows the statistic of API calls based on the response type (success, fail and error). Statistics are shown for the level of API, API endpoint and client application.
  • Duration - shows the average response type on the level of API, API endpoints and client applications.
  • Availability - shows the API availability monitoring status which is performed periodically by KumuluzAPI to detect API unavailability (it also includes automatic alerts to inform API owner).

All metrics can be viewed for the following time periods: 1 hour, 24 hours, 7 days, 30 days and 90 days.

The following picture shows response type view metrics on the level of API:

API level Response type statistics

author Tilen Faganel, Aug 3, 2017 Kumuluzee

We’re announcing the availability of KumuluzEE version 2.3.0.

This version includes two (2) new major features described below, further improves on the new configuration framework introduced in version 2.1.0, improves compatibility of components with the EE specification, aligns with the upstream versions of all the EE components with the latest ones and contains several bug fixes and quality of life enhancements.

author Matija Kljun, Jul 28, 2017 Kumuluzee Event streaming

We are announcing the release of KumuluzEE Streaming extension which provides easy-to-use annotations for developing microservices that produce or consume event streams.

author Tilen Faganel and Matjaz B. Juric , May 3, 2017 Kumuluzee Architecture

This article explores the way the microservices can be used together with Java EE using KumuluzEE. It expands on the benefits and drawbacks compared to the monolithic architecture that’s popular in Java EE. It shows how to quickly and simply develop two microservices with standard Java EE using KumuluzEE. You can find the examples produced in this article on GitHub under the name microservice-simple.

This is an updated version of the original article from 2015.

Why microservices?

The industry standard approach for deploying Java EE applications is packing all components into single EAR/WAR archive and deploying the archive on an application server. Although this approach has several advantages, particularly from the ease-of-development perspective, it leads to monolithic architecture, makes applications difficult to maintain, and - particularly important - makes such applications more difficult and sometimes impossible to scale to meet today’s real world demands, especially in PaaS (cloud) environments.

Microservice architecture addresses these shortcomings by decomposing an application into a set of microservices. Each microservice has well-defined functionalities and an interface to communicate with other microservices (such as REST, WSDL, or if needed even RMI). Most often, microservices are stateless.

Instead of packing all microservices into a single archive (EAR/WAR), each microservice is developed and deployed independently of each other. This brings several advantages, such as:

  • With microservices, applications are more flexible;
  • Every microservice can be developed independently of other microservices, which simplifies lifecycle and change management, makes it easier to use different technologies or upgrade to newer versions;
  • Makes it easier to adopt new technologies for parts of an application;
  • Makes it much more efficient to scale applications in PaaS and Docker-like environments.
author Tilen Faganel, Mar 29, 2017 Kumuluzee

We’re announcing the availability of KumuluzEE version 2.2.0. This is a relatively small release which includes a few key additions to the advanced logging framework introduced in the previous release. The reason for the minor version bump is that we added a few enhancements which are described below. If you’re using it and the KumuluzEE Logs project, you need to also update it to its latest corresponding version that supports the included enhancements.

author Tilen Faganel, Mar 21, 2017 Kumuluzee

We’re finally here. Announcing the availability of KumuluzEE version 2.1.0.

This version aligns the versions of the various EE components with the latest ones and contains several bug fixes, a handy BOM project for easier dependency inclusions (so you don’t need to fiddle with component versions) and project profiles for easier inclusion of the most popular combination of components with initial support for the microprofile specification.

author Marko Škrjanec, Mar 20, 2017 Kumuluzee Logs

We are announcing the release of KumuluzEE Logs extension providing a lightweight open-source logging framework specifically designed for logging microservices.

More details at KumuluzEE Logs.

author Tilen Faganel and Matjaz B. Juric , Jun 4, 2015 Kumuluzee Architecture

This article explores the way the microservice architecture can be used together with Java EE using the new KumuluzEE framework. It expands on the benefits and drawbacks compared to the monolithic architecture that’s popular in Java EE. It shows how to quickly and simply develop two microservices with standard Java EE using KumuluzEE. You can find the examples produced in this article on GitHub under the name microservice-simple.

Why microservices?

The industry standard approach for deploying Java EE applications is packing all components into single EAR/WAR archive and deploying the archive on an application server. Although this approach has several advantages, particularly from the ease-of-development perspective, it leads to monolithic architecture, makes applications difficult to maintain, and - particularly important - makes such applications more difficult and sometimes impossible to scale to meet today’s real world demands, especially in PaaS (cloud) environments.

Microservice architecture addresses these shortcomings by decomposing an application into a set of microservices. Each microservice has well-defined functionalities and an interface to communicate with other microservices (such as REST, WSDL, or if needed even RMI). Most often, microservices are stateless.

Instead of packing all microservices into a single archive (EAR/WAR), each microservice is developed and deployed independently of each other. This brings several advantages, such as:

  • With microservices, applications are more flexible;
  • Every microservice can be developed independently of other microservices, which simplifies lifecycle and change management, makes it easier to use different technologies or upgrade to newer versions;
  • Makes it easier to adopt new technologies for parts of an application;
  • Makes it much more efficient to scale applications in PaaS and Docker-like environments.