Accelerating Drupal 8 with PHPFastCGI or PHP-PM

Submitted by dryer on Sat, 11/07/2015 - 18:09
Drupal on speed

Drupal 8 is set to be released on November 19th 2015. It brings improvements to many aspects of the popular CMS, but the most significant ones remain hidden from user.

One of the core components that Drupal 8 adopted from the Symfony Project is the HttpKernel. This handled all incoming and outgoing HTTP traffic. In addition to the convenience and clarity, it also handles requests independently from each other.

In applications like eZ Platform, built with HMVC frameworks this is used for subrequests that are tab through the same pipe as the main request. Unlike in Drupal 7 and most older PHP applications using superglobals ($_GET, $_POST, $_SERVER) this always isolation of requests.

Traditionally PHP apps have been killed off after each run, this means there is always the overhead of bootstrapping the whole application. The request isolation opens new vistas like PSR-7 firewalls and now a completely novel way of running PHP. There are projects that leave your app running and responding to multiple subsequent requests after another. Obviously making a single reliance on global post values in any module can wreck the feature.

Skipping these repetitive tasks your application performance can improve significantly, and might even render the need of a lighter distribution layer to the REST API useless.

The projects are at an early stage, but both support other applications by writing a straightforward adapter to handle traffic from various applications.

Learn more about the prospect of using PHPFastCGI and PHP-PM to run modern PHP applications like Drupal 8: