Microservices and Enonic
Discover how the content platform Enonic can enhance microservices to help build your future digital experiences.
Within software system architecture, “microservices” refer to applications that are organized as a collection of separate services—as opposed to a monolithic system where all functionality and code is welded together.
By being isolated, microservices can be developed, upgraded, and scaled independently. This allows for faster and potentially safer development and change to large systems in your organization.
The advantages posed by microservices are pretty straightforward, but what can the Enonic platform add to the mix? We will see how Enonic fits into your existing microservices environment, and how it can provide your project with both a framework, runtime, and data storage.
Cloud native microservice platforms
Modern cloud platforms have evolved from basic computing and storage services, and now offer a wide range of platform services. This includes databases, state handling, load balancers, and container orchestration. The latter is at the core of the microservice architecture.
Tools like Kubernetes and Docker enable developers to easily wrap their applications in a runtime, as well as deploying and scaling it dynamically. Dependencies to resources—such as storage or other applications—are dynamically created and provisioned, based on configuration.
One of the more specialized developments in this area, called ServerLess, even lets you run code and scripts without the use of containers.
Cloud native platforms provide a high degree of flexibility in terms of scaling, programming languages, runtimes, and storage options. The downside is primarily related to locking into the various niche services offered by the providers—even if they may often make your life easier.
Enonic uses apps
Enonic provides developers with both runtime and storage, and is in many ways a microservice platform by itself. Rather than talking about microservices, Enonic uses the concept of apps. Unlike cloud based platforms that require provisioning, Enonic apps instantly get access to Enonic’s platform services like storage and search.
The Enonic runtime is capable of running multiple apps in a single instance. This flexibility enables modularization of a single “microservice”. It also enables better utilization of underlying infrastructure, as you don’t need to commit new computing resources for every new app you deploy.
Like microservices, apps enable isolation and modularity, which means that apps can be installed, run, and stopped individually. With the Enonic runtime, this can even be done without shutting down the runtime itself. When the platform is running, you can run a great number of apps, without having to spin up new containers for each and every one.
Speeding up development with Enonic
Enonic provides a Command Line Interface (CLI) for Mac, Linux and Windows which let you install the Software Development Kit (SDK) and build your first app in minutes.
Because of the nature of the Enonic platform, continuous delivery is a given. As a result, your developers can seamlessly integrate Enonic app development into existing tools and deployment pipelines.
Store and search
Enonic provides a powerful NoSQL storage with integrated search. The unique and powerful document-oriented data storage is built upon the fast and robust search engine Elasticsearch.
Enonic’s data store enables you to persist, secure, index, query, and access data of virtually any kind, in a fast and efficient manner. This feature is important when handling multiple apps and services accessing data at the same time.
Read more about the data store capabilities in our storage documentation.
Enonic and containers
So, how does Enonic fit into an existing container orchestration architecture? For a start, Enonic provides standard docker images, as well as distributions for the most popular operating systems—Linux, Mac OS, and Windows. Enonic can run in any cloud, or on premises.
In contrast to container platforms, Enonic does not handle scaling itself, and this is where the two solutions team up perfectly. By placing Enonic into a platform like Kubernetes, you get the benefit of both worlds. Now, you may automatically configure, scale and grow your Enonic cluster—while reaping the fruits of Enonic’s simplicity and powerful features, such as the CMS.
Just like any other microservice, Enonic containers can be configured to access other microservices, and visa versa. In other words, Enonic fits seamlessly into a modern architecture, microservices strategy, and the world of Kubernetes.
Enonic is not designed to replace your existing architecture or investment, but rather complement it.
Content and CMS
The CMS interface of Enonic—Content Studio—is completely optional and is built on top of the Enonic core. The CMS provides functionality to produce and deliver editorial content to your websites and services. If editorial content is as necessary for your organization as microservices, Enonic makes the process a breeze.
Enonic really starts to shine when you use all the core features combined, including localization, search, front-end framework, and more—as shown in this illustration:
When not to use Enonic
Even though Enonic is a powerful content platform, it cannot be everything for everyone all at once. As such, Enonic might not always be the optimal solution for your project. For instance, if you don’t need to store data, or your application is not related to web, Enonic is probably not the platform you need.
If containers and microservices are not your cup of tea to begin with, Enonic can of course be deployed in more traditional infrastructures.
With the right preparations and considerations, Enonic will not only fit into your existing microservice and container architecture—it will strengthen and augment it. Providing both a runtime, CMS and a storage component, Enonic gives you all the advantages of a fully-fledged digital experience powerhouse together with your microservices.
First published 18 September 2019, updated 19 December 2022.