Topic: PHP-FPM 7.2+ with ZTS (Zend Thread Safety) and Parallel extension

Hello.

I want to install PHP 7.2 or 7.3 with PHP-FPM ZTS for use with the "parallel" extension.

I did a lot of searching on this site and in your repository, but I still could not find a way to install PHP-FPM ZTS. The only thing I found is the CLI version - zts-php.

Please tell me if there is such a package in this repository? And is it worth it to install such a configuration?

Judging by krakjoe's answer on GitHub https://github.com/krakjoe/parallel/issues/35 and my tests, the parallel extension works fine with the nginx web server via PHP-FPM.
But for this I had to compile PHP from the source code. And I would like to be able to install from the package.

My configuration is:
- CentOS 7.6.1810
- PHP 7.2 / 7.3
- nginx 1.12.2

Re: PHP-FPM 7.2+ with ZTS (Zend Thread Safety) and Parallel extension

Indeed, only the "zts-php" command is built with ZTS mode

FPM is a "process" manager, and don't need thread safety, by design.
Server load is shared between the processes.

IMHO, such extensions as pthreads or parallel mostly make sense in CLI mode, for huge work run in backend (not suitable for web env)

Laptop:  Fedora 38 + rpmfusion + remi (SCL only)
x86_64 builder: Fedora 39 + rpmfusion + remi-test
aarch64 builder: RHEL 9 with EPEL
Hosting Server: CentOS 8 Stream with EPEL, rpmfusion, remi

Re: PHP-FPM 7.2+ with ZTS (Zend Thread Safety) and Parallel extension

Thanks for the answer.

I understand that

FPM is a "process" manager, and don't need thread safety, by design.

but the "parallel" extension creates and uses threads and requires thread safety.

Our project is built on a microservice architecture and works in such a way that it accepts relatively few requests, but inside the application makes many requests to many APIs of other services.

All these internal requests are executed sequentially, which results in a relatively long server response.

We want to parallelize these internal requests using the "parallel" extension.

That is why we need the PHP-FPM ZTS. But we want to use a ready-made package for this without creating our own PHP compilation.

Should we expect the appearance of PHP-FPM ZTS in your repository in the near future?