Introduction

Escenic's new presentation layer is called the Decoupled Presentation Layer (DPRES for short). It is a collection of web services that together serve content to client applications such as browsers and native mobile/tablet apps. It is called a decoupled presentation layer for a number of related reasons:

  • DPRES is not embedded in the Content Engine. It is a free-standing entity that is only loosely connected to the Content Engine via calls to the engine's REST API.

  • DPRES is internally decoupled, being composed of several free-standing web services (or microservices). Although they will most often be installed together on a single machine, they could, if required, be run on different machines in different locations, or in the cloud.

  • DPRES decouples customers' technology choices from the Content Engine. Unlike Escenic's old presentation layer, which requires the use of Java Server Pages (JSP), it supplies page content as language-neutral JSON data, freeing you to use whatever language and technology you prefer for your front-end component. We supply a ready-made front-end component called the Waiter that is written in PHP, but use of this component is entirely optional. You can replace it with software written in any language you like. And in the case of mobile/tablet apps, you can dispense with a Waiter altogether, and serve JSON content directly to the app.

DPRES is composed of three web services:

Waiter

A front-end service that receives client requests and responds with HTML pages.

Cook

A back-end service that retrieves and assembles content for the Waiter.

Cleaver

A back-end service that retrieves, crops and resizes images for the Cook.

Both Cook and Cleaver require access to an Escenic Content Engine from which to retrieve content.

Breaking the presentation layer into separate services in this way encourages separation of concerns: front-end developers/designers can work exclusively with the Waiter service, and do not need to know anything about Cook or Cleaver. Similarly, back-end developers can concentrate on ensuring that the Cook delivers the required content to the Waiter, and need not concern themselves with how the Waiter presents it.