Welcome! Log In Create A New Profile

Advanced

$request_time in ngx_http_log_module

Dorin RuV
August 31, 2021 02:50AM
Hi everybody,

I'm currently working on adjusting the logging format to our nginx proxies.
In order to comply to some logging endpoint standards I'm trying to find
the right place where I could convert the $request_time value from "seconds
with a millisecond resolution" to nanoseconds.
Can it be done in nginx itself (without lua)?
The following works but it's dirty:

map $request_time $request_time_no_decimal { ~(.*)\.(.*) $1$2; }

Best,
Dorin
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

$request_time in ngx_http_log_module

Dorin RuV August 31, 2021 02:50AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 85
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready