Live data from Hacker News

Show HN: FrankenPHP, an app server for PHP written in Go

frankenphp.dev

1–10 of 93 posts

Re: Show HN: FrankenPHP, an app server for PHP written in Go

#5

So after looking at the slidedeck on the authors blog, I'm rather confused. How does FrankenPHP keep the code in memory if each request is in a separate memory space?

They're probably using PHP's built in opcache or something they rolled themselves

  OPcache improves PHP performance by storing precompiled script bytecode in shared memory
https://www.php.net/manual/en/intro.opcache.php

Re: Show HN: FrankenPHP, an app server for PHP written in Go

#6
I've been watching how Go and Rust tooling has been finding its way into the JavaScript ecosystem. I've been out of the PHP realm for about 10 years but I did find RoadRunner for PHP at one point. That's also an app server written in Go I believe. I wonder how this compares.

Re: Show HN: FrankenPHP, an app server for PHP written in Go

#7

So after looking at the slidedeck on the authors blog, I'm rather confused. How does FrankenPHP keep the code in memory if each request is in a separate memory space?

See Preloading which landed in PHP 7.4 https://stitcher.io/blog/preloading-in-php-74

Re: Show HN: FrankenPHP, an app server for PHP written in Go

#8

So after looking at the slidedeck on the authors blog, I'm rather confused. How does FrankenPHP keep the code in memory if each request is in a separate memory space?

They're probably using PHP's built in opcache or something they rolled themselves OPcache improves PHP performance by storing precompiled script bytecode in shared memory https://www.php.net/manual/en/intro.opcache.php

opcache is definitely on https://github.com/dunglas/frankenphp/blob/f97f56d45a403342b...
Post reply on HN