Release Notes

Contents

Release Notes

XP7 Update 4

This version of Enonic XP is rather different from most others. There is no large feature set of noticeable changes, but rather a very important architectural change:

We have added Hazelcast to do events, tasks and sessions in the cluster. ElasticSearch is still there, but by using Hazelcast for these features, the cluster is more stable, and we now support Distributed Sessions.

Please read the upgrade notes in relation to backward compatibility.

Other improvements

In addition to the cluster freatures, AlwaysPreTouch has been enabled to avoid extra GC pauses on large installations.

XP7 Update 3

Please read the upgrade notes in relation to backward compatibility.

Content projects

XP now supports creating and working with content projects. Each project will create a separate repository, where content is isolated from the other projects. The repositories are named com.enonic.cms.<projectname>. Projects also introduce a simplified model in relation to permissions management and other default settings:

  • Set a default language for the project

  • Set default access mode (public, private or custom)

  • Give access to project via pre-defined roles (Owner, Editor, Author and Contributor)

  • Default content permissions are set via the pre-defined roles and access model

  • Projects can also be programmatically managed via the new project API.

To take advantage of projects, you must also upgrade to Content Studio v3.

For full backward compatibility, the default content repository (Default project) remains unchanged.

Compressed dump and load

Dumps can now be streamed directly to a compressed archive to use less disk space, and speed up the process. Loads can similarly load data directly from a compressed archive. We now recommend always using compression when performing dump and load.

For backward compatibility, using compression requres a setting a flag when using Enonic CLI.

Login without sessions

The updated auth API now supports request scoped logins, without having to manually modify the request context.

This is in particulary useful for handling modern stateful clients (i.e. using Java Web Tokens), meaning that a server session is no longer created when logging in. Getting rid of sessions provide more scalability and reliability from a server side perspective.

Details are available in the auth API documentation.

Selected improvements

The following improvements are also part of this release:

  • Color highlighting in console logs

  • Content API - Get content by version ID

  • Page template resolution is now faster - especially relevant for sites with many page templates

  • The default threshold to compress http content changed from 16 to 23 bytes

  • New Jetty http.threadpool configuration options are now available

  • Improved logging now include details that were previously missing

  • Improved peformance and stability for web sockets

  • Improved handling of StackOverflowError

XP7 Update 2

v7.2 is fully backward compatible with previous v7.x versions.

Audit Log

Any application can now store audit logs in a new common repository: "system.auditlog".

A core JS library Audit Library has been added to help you store and retrieve these audit logs

Content API - Audit Log

All successful state-changing operations, through the Content API, will create an audit log entry. In other words, all create/edit/publish/…​ in Content Studio or by using the content library will create an audit log entry This feature can be disable by modifying the configuration file com.enonic.xp.content.cfg.

Node library - Get node by version

You can now retrieve an old version of a node by using the RepoConnection::get method.

Custom part icons

Part component now supports a custom icon which will be used instead of the default one in Content Studio - in the Page Component tree and dropdowns with part descriptors. Just place an icon (in either PNG or SVG format) with the same name as the descriptor schema into the same folder. For example, if part/folder is called mypart then part descriptor is called mypart.xml and the icon file should be called either mypart.svg or mypart.png.

This feature requires Content Studio v2.3.

Header filter

It is now possible to specify default headers set for every HTTP response via header filter. Default headers can be configured in com.enonic.xp.web.header.cfg configuration file via headerConfig property.

Cross site scripting prevention headers
headerConfig = set X-Frame-Options: SAMEORIGIN,set X-XSS-Protection: 1; mode=block,set X-Content-Type-Options: nosniff

XP7 Update 1

v7.1 is fully backward compatible with v7.0 and was released in parallel with Content Studio v2.1.

This update introduces new features and improvements as well as 28 bugfixes. The complete list of changes is available on Github.

Query highlighting

The storage and CMS API now provide out-of-the-box highlighting functionality.

By submitting a highlighter definition together with your query, you will in return get text fragments where relevant search strings are highlighted. This is especially useful when presenting search results to end users.

Sample query with hightlighter
{
  query: "fulltext('description', 'house garden big')",
  highlight: {
    properties: {
      "description": {
        fragmentSize: 15,
        numberOfFragments: 2
      }
    }
  }
}
Sample result from above query
{
    ...
  "highlight": {
    "c4bb11f1-c6e2-4849-a665-28f612213984": {
      "description": [
        " <em>house</em> with <em>big</em>",
        " maintained <em>garden</em>."
      ]
    }
  }
}

Content Workflow

The Content API now introduces support for basic workflow capabilities. When creating or modifying content, workflow status may be specified. Currently the following statuses are available: IN_PROGRESS, READY,

The API will now prevent publishing of content unless it is in the workflow state READY.

For backward compatibility, if workflow state is not specified, it is equivalent to READY. Also, modifying content will keep the item’s existing workflow state.

Screenshot showing workflow state in Content Studio

Check out the content api for usage details

Customizable display name label

For an improved editorial experience, developers may now override the default <Display Name> text on a per content type basis. This helps make the content form more intuitive.

By adding the following line to your content type definition:

<display-name-label>Some cool text here</display-name-label>

Editors will see the following in content studio.

Screenshot showing what this looks like in Content Studio

Visit the Content Types documentation for more detail

Publishing message

The content API’s publish function now supports adding a message. This message is added to the "commit" entry that was added to the function with the release of XP7.

The publish message is builds on the commit functionality of the Node API.

Content studio enables you to see the publishing message from the version history widget.

Screenshot showing where to write the publish message from Content Studio

Selected improvements

Some of the improvements included in this release are:

  • New exists() function for both node and content API provides faster existence checks over using get()

  • Assets with .es extension are now served with the javascript MIME type

  • File names are now sanitised during upload to prevent use of illegal characters

XP7

Breaking changes XP 7 contains breaking changes. Follow the upgrade instructions carefully to secure a successful upgrade.

Enonic XP 7 takes a major leap in simplifying application development and making the platform leaner and more flexible.

The biggest highlights of XP 7 is not the core platform, but all the changes around it:

  • New documentation - The documentation you are reading was created from scratch for XP 7

  • Developer portal - All XP related developer resources and docs in one place

  • Enonic CLI - For managing XP development project, also replaces the toolbox shell script

  • Native distributions. The Java Virtual Machine is now bundled with XP

  • Content Studio - Is now available as an app to download from Enonic Market.

Developer portal

Screenshot of the new developer portal

In order for developers to better and more easily navigate the XP ecosystem, we created a dedicated portal. The portal contains

  • XP docs: The XP core platform documentation (which you are reading now)

  • Reference docs: For all XP related apps, starters, libraries and more that are built by Enonic.

  • Hands on guides: Practical how-to guides an tutorials, including the getting started page

Built with XP

The portal is naturally an XP app itself. The geeky fact is that all docs and most guides are written in Asciidoctor together with the actual product code.

When we commit, changes to the docs are automatically checked out, compiled and imported to XP as content. This optimize how developers produce content, while taking advantage of everything XP offers at the same time.

Screenshot of dev portal edited in Content Studio

We plan to release the core elements of the doc portal on the market in the future.

Enonic CLI

The brand new Enonic Command Line Interface - "Enonic CLI" was also released at the same time as XP 7. It is versioned independently for more frequent updates. The CLI not only replaces the old toolbox script, it also introduces new and flexible ways of installing XP and managing projects and development environments.

Installing CLI, Enonic XP, building and deploying your first app can now be done with a few simple commands, as described in the getting started section of the developer portal

The CLI is available for Mac, Linux and Windows. For more information, check out the full documentation.

Native distributions

The biggest conceptual change to XP is that Java (the JVM) is no longer required in order to run XP. XP 7 ships with Java 11 embedded. As such, we now release native distributions of XP for the three major platforms, Mac, Windows and Linux. Expect future versions of XP to make more use of native capabilities and non-Java based functionality. As always, you will never have to worry about portability when writing XP apps.

There are several reasons for this move:

  • Developers no longer need to install or juggle with different versions of the JVM

  • Installation of XP is faster and sleeker than ever

  • We can take advantage of native/non-Java functionality when required

With this change, XP is now available in SDK and Server version. The SDK includes the full Java Development Kit, whereas the server edition uses a slimmed down version of the JVM, and may be further optimized for production use.

Content Studio is an app

Content Studio, the CMS editorial interface has been moved out of the XP core. It is now available as a separate application on Enonic Market

Content Studio can now be released more frequently than the XP core. Expect new versions of Content Studio to be released along with new features in the XP core.

For Content Studio release notes, check out the new documentation.

CMS

Even if Content Studio can be installed as a separate application, The XP core still ships with the content API and site engine that applications depend on.

Image styles

XP 7 introduces a new feature in the rich text editor called "Image styles". Image styles consist of both client side styling (css), and image service rendering specifications.

The rich text editor was previously limited to pre-defined and hard-coded styles, such as cinema (21:9) or square(1:1). Now, application developers may define custom styles that control both server side rendering aspect ratio, and specify classes to annotate the specific image.

Here we see an image using a style called old-photo, which adds the sephia effect to the image.

Projects prepared

Customers with many sites have requested better support for isolation of sites, and specific access rights to each. Our solution to create sites in different "projects", each project will be using its own repo. XP 7 (and Content Studio) does not yet fully implement this features, but prepares the foundation for supporting it.

You will notice this through the following change:

  • The default CMS repo is renamed from "cms-repo" to "com.enonic.cms.default".

  • New projects will be using the extension as project name, i.e. project "myproject" will use repo "com.enonic.cms.myproject"

  • The site engine URLs now contain project name - i.e. /site/<project>/<branch>/<content-path>

Editor references

References to images or other content in the rich text editor are now stored explicitly in the underlying node API. The publishing wizard will now identify and include these dependencies like all other references - no more missed items during publishing.

Stemmed content

Content flagged with a language is now automatically stemmed during indexing (trimming words to their root form for better hits). This is done using the standard Elasticsearch stemmer. This is achieved by adding a stemmed version of the _allText property, combined with a new query function.

Better page indexing

Pages, and their components are now indexed differently. Rather than just looking for text within a page, developers may now search for any configuration property, or metadata within a page.

As an example, one may now search the use of a specific part within a site.

XP Storage

The XP storage has been refactored for improved performance and disk usage.

Blobstore improvements

XP persists all data in so-called blobstore segments, one segment for each type of data to persist. XP 7 introduces new segments for indexconfig and permissions, enabling re-use of these across nodes, and node versions.

This reduces the use of disk space significantly.

Additionally, each repository now has it’s own root entry in the blobstore. This makes it possible to directly manage blobs associated with a single repository.

Version commits

XP automatically creates new versions for each modification of a node. Where XP 6 would persist all versions forever, XP 7 by default treats all versions as transient. This means that all versions that are not currently in a branch, may be garbage collected at any time in the future.

To prevent versions from being removed, one may also commit.

For the Content API specifically, publishing an item will automatically create a commit, effectively placing a stamp on the specific versions being published. Commits have id, committer, and optionally a commit message as meta data.

XP 7 does not yet implement the garbage collector that removes uncommitted versions, this will be part of an upcoming release.

Contents