PHP's stateless execution model is still based on the mechanics of CGI: request in, response out. This simplicity also means overhead on each request from frameworks starting up; applications also cannot interact with the request body during transmission, e.g. for streaming the body or handling upgrades to Websockets.

That's why all other web languages now offer production ready web servers implemented purely in each language: Jetty, Puma, Gunicorn and friends use a modern process model and standardized middleware protocols.

PHP 7 finally brought some necessary engine changes like catchable fatal errors, so there now is no longer a need for Apache or Nginx: event based HTTP components from projects like ReactPHP or Icicle, brought together by a server like Aerys or PHP-PM, start a framework once, and handle requests in a loop.

The result is a massive gain in performance especially with frameworks like Symfony, and the potential for new features that previously were not possible with an external web server in front of an application.

Let's explore the current state of affairs, the solutions other programming languages found, and the bright new future that's ahead for PHP, which, as always, will require sacrifices to be made.

Comments

Comments are closed.

Very interesting!

Now imagine the estimated 5 million PHP developers crying because most of them probably struggle with legacy code bases.

Great to see a bright future ahead of us!

What a great talk!
Really enjoyed it.

The only (slight) remark I could have is: Could you add code highlighting to the examples?

Rated 4

Matt Prelude at 13:03 on 16 Feb 2017

I've seen a lot of the technologies presented in this talk, in isolation, but it was really interesting to see someone tie them together, compare them, and offer an educated estimation as to how we can use them.

Rated 5

Nick Barham at 14:42 on 16 Feb 2017

Fantastic talk, lots of great information provided in a very approachable way. Was much better than my expectations based on the title alone ;P

David Zuelke (Speaker) at 15:26 on 16 Feb 2017

Yup Frederick, fixed in the uploaded slides - my TextMate2 "copy as RTF" bundle was broken.

Rated 5

Mattias Wirf at 22:26 on 16 Feb 2017

Great inspiration to study this further, and test this when I get home :)

After a slow start talking about history, this was good introduction as to how other languages do things, and just why it can be a real win for PHP. Some more details about the latter and taking some risks with the live-demo gods to show just what the results can be on a real (usefully sized) example project would make this a great talk in future.

Really interesting topic, could've dived deeper into already existing tools and implementation, rather than sticking to analysis and comparison to other languages though

Very nice presentation with an adequate information to think differently for the future. Thanks!

Fantastic talk about a very interesting topic. Well paced and engaging.

Rated 5

Davo Smith at 19:59 on 17 Feb 2017

Great overview of where webserver technology has come from and where it could be going. Looking forward to reading the slides again to pick up the bits I didn't take in the first time though.

Rated 5

Andy W at 20:30 on 19 Feb 2017

One of the standout talks of the event for me, really inspiring look to where we as PHP Dev's could be heading, and definitely ideas to play with right away. Very engaging and well paced presentation.

The intro was a bit long winded, but it was a good talk.
I had heard about some of the servers presented about, but it was good to see how much can performance be improved in some cases and what the rationale is about on the whole.

I sort of missed whether anyone uses these in production anywhere and what issues had been encountered with these when building/running apps specifically with these servers in mind and how they were resolved. It would be a nice addition to the slides.