Skip to content

Commit 716fc8d

Browse files
authored
Merge pull request #19 from Intellection/update_latency_headers
Update latency timing headers
2 parents facd8e7 + 977c88b commit 716fc8d

File tree

3 files changed

+10
-2
lines changed

3 files changed

+10
-2
lines changed

CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,13 @@
44

55
* Use `zappi/nginx:1.25.3` as the docker base image.
66
* Upgrade `headers-more-nginx-module` to `v0.37`.
7+
* Update latency headers:
8+
* Add `X-Proxy-Request-Time`.
9+
* Add `X-Proxy-Backend-Response-Time`.
10+
* Remove `X-Proxy-Backend-Total-Time`.
11+
* Update logging fields:
12+
* Add `http_x_proxy_backend_response_time`.
13+
* Remove `http_x_proxy_backend_total_time`.
714

815
## 1.25.2-3
916

config/http.conf

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,8 @@ http {
8181
# Latency headers
8282
add_header X-Proxy-Backend-Connect-Time $upstream_connect_time;
8383
add_header X-Proxy-Backend-Header-Time $upstream_header_time;
84-
add_header X-Proxy-Backend-Total-Time $request_time;
84+
add_header X-Proxy-Backend-Response-Time $upstream_response_time;
85+
add_header X-Proxy-Request-Time $request_time;
8586

8687
gzip on;
8788
gzip_comp_level 5;

config/log.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ log_format main_json escape=json
1515
'"http_x_forwarded_for":"$http_x_forwarded_for",'
1616
'"http_x_proxy_backend_connect_time":"$upstream_connect_time",'
1717
'"http_x_proxy_backend_header_time":"$upstream_header_time",'
18-
'"http_x_proxy_backend_total_time":"$request_time",'
18+
'"http_x_proxy_backend_response_time":"$upstream_response_time",'
1919
'"proxy_connection":"$proxy_connection",'
2020
'"proxy_x_forwarded_port":"$proxy_x_forwarded_port",'
2121
'"proxy_x_forwarded_proto":"$proxy_x_forwarded_proto",'

0 commit comments

Comments
 (0)