Node JS

Overview

Cloud Platform is the leading cloud platform service for developing, delivering, and managing Drupal, Node.js, and decoupled Drupal applications. Node.js is an open source server-side environment (runtime) for JavaScript network applications. Cloud Platform Enterprise subscribers can leverage both the Acquia platform and Node.js to create unique digital experiences that better leverage the best in JavaScript talent.

With Node.js in Cloud Platform, you have a powerful set of tools to enhance your decoupled Drupal applications. You can also create standalone Node.js applications to share data with Drupal.

What do Node.js applications in Cloud Platform provide?

  • Server-side rendering of front-end templates written in AngularJS, React, and Ember, or other front-end frameworks

  • Create powerful, flexible proxy layers between clients and Drupal, for enhanced security and performance

  • Enhance your decoupled Drupal applications with improved speed, SEO, and proxying capabilities

  • Websockets support for high-performing, low-overhead, two-way data transfer to clients

  • Run stand-alone Node.js apps for real-time communications like chat infrastructure, for analyzing statistics or analytics, or anything else

  • Access to thousands of Node.js modules, through NPM

  • Access to a content delivery network with Cloud Platform CDN.

Note

  • You cannot create Cloud IDEs for Node.js applications in the Cloud Platform user interface.

  • You cannot use the Acquia Search feature in Node.js applications.

Decoupled Drupal support

Using a Node.js application can bring beneficial enhancements to a decoupled Drupal architecture.

Cloud Platform Node.js applications can use Node.js as a standalone product, or can use Drupal as a content management system / business layer—making Drupal your database, content creation, and update center, and connecting Node.js with the presentation frameworks. This approach leverages Node.js frameworks with decoupled Drupal architecture. It exposes Drupal’s content and business-logic back-end through APIs, and uses a front-end framework to build the user interface and presentation layer. Decoupled Drupal applications combine modern user interface responsiveness and power with Drupal’s unique content and logic features.

Decoupled applications can have significant drawbacks, including the following:

  • Slow initial page load: A page skeleton must load and then activate the front-end components to fetch content and render it, causing a perceived slow first-page load time.

  • SEO unfriendly: If page content is fetched and assembled in the browser, it is not available to search engines and other bots. Rich link previews for social media also may not work.

  • Security concerns: Your Drupal API is exposed to the public internet, which means you may want to allow connections only from whitelisted addresses.

Node.js can help you address these issues by using server-side rendering to deliver an initial page straight to the browser. By altering the rendering, you decrease perceived load time and increase readability by search engines. Wrapping your Drupal APIs in Node.js means they are exposed only to Node.js, and not the world.

Caching options for Node.js on Cloud Platform

The Node.js hosting architecture on Cloud Platform contains a pair of load balancers and one or more web infrastructure. If your application requires caching, consider the following options:

  • Rely on the caching layer on the Drupal side of the infrastructure.

  • Implement Cloud Platform CDN in front of the Node.js stack.

Node.js environment resources

For the specific resources available for your use in Cloud Platform Node.js application environments, and the current limitations of these environment types, see Resources and limitations for Node.js environments.

Getting started with Node.js applications

You can add a Node.js application to a Cloud Platform Enterprise subscription for an additional cost. Contact your account manager to learn about adding Node.js to your subscription. For more information about Node.js applications and environments in Cloud Platform, see Getting started with Node.js applications and environments.