XP Applications

Contents

Schemas, code, and functionality is added to XP via applications.

Introduction

Enonic apps are standalone software packages that can be installed and started on Enonic XP.

Applications are powered by the XP runtime. This also means XP is capable of running multiple applications in a single instance.

Once an application has started, it has access to all platform services, such as the NoSQL storage.

A single application may offer many different capabilities, from CMS schemas, to low level features like exposing services to other apps.

Fundamentally, most of XP’s core software components are built like applications.

Enonic Market

Enonic market is the go-to place for official apps from Enonic, as well as 3rd party applications. The marketplace also offers starter kits and software libraries that help you create new apps better and faster.

Installation

There are four ways to get your applications running on Enonic XP:

Via Admin Interface

Applications can be manually installed through the admin tool "Applications", included with Enonic XP. Once installed, the applications will be available for all nodes in an XP cluster.

Via Management API

Applications can be installed through the Management API. The applications will be available for all nodes in an XP cluster. This approach is commonly used in a CI/CD setup.

Via File system

File system deployment is most commonly used during development, but it can also be applied for specialized deployment scenarios. Applications deployed on file will only be available on the local node, and overrides applications installed via other alternatives.

Consider a microservice style highly controlled setup where you bundle your app(s) together with the XP runtime and launch it as a separate instance.

Life Cycle

In addition to installing and uninstalling, XP applications may be started and stopped. This is referred to as the life cycle of the application. During the stop and start phases, applications themselves may execute custom code.

Starting

Once installed, applications are automatically started on all nodes. During the startup, if it exists, the application’s main.js script will be executed.

Stopping

Before uninstalling, applications are automatically stopped on all nodes. During the stopping, if it exists, the disposer of the application’s main.js script will be executed.

Use cases

There are endless use cases for the XP platform, but the most common scenarios are listed below:

Sites

You may build applications that go from serving content from an API (Headless CMS) via traditional web sites to Hybrid CMS - offering the best of both worlds.

The CMS offering essentially consist of three parts:

  • Content Studio - Editorial admin interface, available as an app on Enonic Market

  • Content API - Built on top of the NoSQL Storage

  • Site Engine - Built on top of the HTTP engine

Learn more about the Content Management System and the site engine.

ID providers

XP apps may also be ID providers. Once installed and configured, an ID provider can join the request pipeline of other sites and applications, dynamically providing authentication and authorization as needed.

There are multiple standard ID providers available on Enonic Market.

Learn more about the identity and access management

Tasks

The XP runtime also supports executing scripts running in the background. Unlike sites and web-applications, tasks are not exposed as an end-point. Tasks can be started and monitored via the the task API Tasks are made by adding one or more JavaScript controllers to your project.

Read more about tasks and the task engine

Web apps

The JavaScript framework offers an easy way to build and to serve web applications.

Admin tools

XP apps can also contribute to Enonic XP’s admin console. The platform comes with a standardized approach to extend the admin console with custom interfaces, called admin tools. Admin tools are created by adding one or more JavaScript controllers to your project.

Read more about Admin tools


Contents

Contents