[php-src] Issue #8174: PHP-FPM : Option to suppress "/ping" from logs -- patch file given

From: Date: Sun, 06 Mar 2022 15:36:17 +0000
Subject: [php-src] Issue #8174: PHP-FPM : Option to suppress "/ping" from logs -- patch file given
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-240233@lists.php.net to get a copy of this message
Issue: https://github.com/php/php-src/issues/8174 Author: Julien75013 ### Description SysAdmin and DevOps don't need to have logs when healthcheck are set up for checking the availability. To understand why this is relevant, see how today's softwares performs in many high-load environments. Apache permit full conditionnal logs : > https://httpd.apache.org/docs/trunk/en/logs.html#conditional Haproxy permit some conditionnal logs : > Haproxy - Options dontlog-normal / dontlognull : > > https://cbonte.github.io/haproxy-dconv/2.4/configuration.html#4.2-option%20dontlog-normal > > https://cbonte.github.io/haproxy-dconv/2.4/configuration.html#4.2-option%20dontlognull > Haproxy - Disabling logging of successful connections : > > https://cbonte.github.io/haproxy-dconv/2.4/configuration.html#chapter-8.3.3 The actual saving of data space could be several megas, for each host. For thousands of servers, it can be a significant saving. ``` $> tail -n 5 /var/log/php8/pings/access.log - - 27/Nov/2021:02:12:57 +0100 "GET /ping" 200 - 0.238 2048 0.00% - - 27/Nov/2021:02:12:58 +0100 "GET /ping" 200 - 0.309 2048 0.00% - - 27/Nov/2021:02:13:01 +0100 "GET /ping" 200 - 0.258 2048 0.00% - - 27/Nov/2021:02:13:04 +0100 "GET /ping" 200 - 0.190 2048 0.00% - - 27/Nov/2021:02:13:04 +0100 "GET /ping" 200 - 0.166 2048 0.00% $> gunzip -c /var/log/php8/pings/access.log.*.gz | wc -l 2838920 $> du -h /var/log/php8/pings/ 32M /var/log/php8/pings/ ``` So, we need an option to disable logs when the "/ping" path is reached. ``` ; This directive is used to apply (or prevent) the "GET /ping" to be logged. ; Directive "ping.path" have to be set, before this setting to be effective. ; Default Value: yes ;ping.dontlog = yes ``` Main thread from bugs.php.net : https://bugs.php.net/bug.php?id=80428 Patch file was issued in 2020 but has never been seen : [php-fpm-ping_dontlog.txt](https://github.com/php/php-src/files/8192863/php-fpm-ping_dontlog.txt)

« previous php.bugs (#240233) next »