Req #79137 [Com]: Add request parameters to slow log script report

From: Date: Thu, 08 Dec 2022 04:31:24 +0000
Subject: Req #79137 [Com]: Add request parameters to slow log script report
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-243069@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=79137&edit=1 ID: 79137 Comment by: samira dot akhlaqi314 at gmail dot com Reported by: nadavkav at gmail dot com Summary: Add request parameters to slow log script report Status: Open Type: Feature/Change Request Package: FPM related Operating System: GNU/Linux RedHat 7 PHP Version: 7.3.13 Block user comment: N Private report: N New Comment: Thanks for the information keep sharing such informative post keep suggesting such post. (https://www.livetheorangelife.net/)php.net Previous Comments: ------------------------------------------------------------------------ [2020-01-20 07:24:24] nadavkav at gmail dot com > Is that not available through your access/request log? I do not think so. And if so, how can I match those two logs? their is no unique key on both. It seems trivial to display the incoming query params on the slow log, instead of trying to match the log entries with another access log. ------------------------------------------------------------------------ [2020-01-19 21:50:49] requinix@php.net Is that not available through your access/request log? ------------------------------------------------------------------------ [2020-01-19 11:33:56] nadavkav at gmail dot com Seem somewhat related: https://bugs.php.net/bug.php?id=53434 ------------------------------------------------------------------------ [2020-01-19 11:32:43] nadavkav at gmail dot com Description: ------------ Reading the slow log report entry, I am missing important information that was passed as request parameters to the script, so I can emulate the request when I analyze the reason for that slow query. All I see now is: [19-Jan-2020 04:04:31] [pool www] pid 56016 script_filename = /var/www/moodle/index.php [0x00007fccca813b80] query() /var/www/moodle/lib/dml/mysqli_native_moodle_database.php:1257 [0x00007fccca813a20] insert_record_raw() /var/www/moodle/lib/dml/mysqli_native_moodle_database.php:1305 [0x00007fccca813920] insert_record() /var/www/moodle/lib/classes/session/manager.php:431 [0x00007fccca813880] add_session_record() /var/www/moodle/lib/classes/session/manager.php:408 [0x00007fccca8136e0] initialise_user_session() /var/www/moodle/lib/classes/session/manager.php:82 [0x00007fccca813620] start() /var/www/moodle/lib/setup.php:785 But I have no idea what parameters were passed to the query: GET https://my-web-site/index.php which could help me re-query and investigate the reason for the slow script. Please see if you can add to the slow log also the request query parameters. Expected result: ---------------- Add query parameters to the slow log report: (see: request query params = ['id' => 5, 'param' => value1] ) [19-Jan-2020 04:04:31] [pool www] pid 56016 script_filename = /var/www/moodle/index.php request query params = ['id' => 5, 'param' => value1] [0x00007fccca813b80] query() /var/www/moodle/lib/dml/mysqli_native_moodle_database.php:1257 [0x00007fccca813a20] insert_record_raw() /var/www/moodle/lib/dml/mysqli_native_moodle_database.php:1305 [0x00007fccca813920] insert_record() /var/www/moodle/lib/classes/session/manager.php:431 [0x00007fccca813880] add_session_record() /var/www/moodle/lib/classes/session/manager.php:408 [0x00007fccca8136e0] initialise_user_session() /var/www/moodle/lib/classes/session/manager.php:82 [0x00007fccca813620] start() /var/www/moodle/lib/setup.php:785 ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=79137&edit=1

« previous php.bugs (#243069) next »