小编Tup*_*upy的帖子

如何使用 HAProxy 设置请求开始时间?

我想测量完整请求堆栈的时间。中间件的 New Relic 捕获时间(例如 java、python、ruby)和请求时间(参见https://newrelic.com/docs/features/tracking-front-end-time)。为此,我需要X-Request-Start在请求通过 HAProxy 负载平衡时配置标头。haproxy.cfg 应如下所示:

backend www
  balance roundrobin
  mode http
reqadd      "X-Request-Start"  UNKNOWN_TIME_FUNCTION()
server servername 192.168.0.1:80 weight 1 check
Run Code Online (Sandbox Code Playgroud)

有一个 haproxy 本机函数来替换UNKNOWN_TIME_FUNCTION()?

performance haproxy

5
推荐指数
1
解决办法
843
查看次数

标签 统计

haproxy ×1

performance ×1