reduced speed when running a server with openresty
Hi, doing direct benchmarks on the machine with Mark the speed is remarkable, but if I pass my connection through an api gateway with openresty doing the benchmark the speed drops a lot and I would like to understand how to improve it.
How is the configuration in your Nginx ?
Without a proper Proxy configuration, the performance will be poor with Mark or with any other app.
it'd help to know more about how you are running this.
You can just create a simple Dockerfile base image:
FROM php:8.4-cli
RUN docker-php-ext-install sockets pcntl
RUN apt-get update && apt-get install -y libevent-dev libssl-dev -y && pecl install event
and then copy your code over, expose your port, and run the start -d command in your own Dockerfile that inherits this as the base.
Then if you're running straight Docker "in prod", you'll need to do some ulimit and kernel tuning: https://manual.workerman.net/doc/en/appendices/kernel-optimization.html
If you use docker compose or k8s or something you can add those configuration options to either your docker-compose file or your k8s resources.