envoy日志格式如下:
[%START_TIME%] “%REQ(:METHOD)% %REQ(X-ENVOY-ORIGINAL-PATH?:PATH)% %PROTOCOL%”
%RESPONSE_CODE% %RESPONSE_FLAGS% %BYTES_RECEIVED% %BYTES_SENT% %DURATION%
%RESP(X-ENVOY-UPSTREAM-SERVICE-TIME)% “%REQ(X-FORWARDED-FOR)%” “%REQ(USER-AGENT)%”
“%REQ(X-REQUEST-ID)%” “%REQ(:AUTHORITY)%” “%UPSTREAM_HOST%”\n
说明如下:
时间戳:[%START_TIME%]
请求行:“%REQ(:METHOD)% %REQ(X-ENVOY-ORIGINAL-PATH?:PATH)% %PROTOCOL%”
响应状态码:%RESPONSE_CODE%
响应标识符:%RESPONSE_FLAGS%
接收字节数:%BYTES_RECEIVED%
发送字节数:%BYTES_SENT%
请求处理时间:%DURATION%
后端服务响应时间:%RESP(X-ENVOY-UPSTREAM-SERVICE-TIME)%
客户端 IP 地址和端口号:" “%REQ(X-FORWARDED-FOR)%”
用户代理信息:“%REQ(USER-AGENT)%”
请求 ID:“%REQ(X-REQUEST-ID)%”
主机名或者域名:“%REQ(:AUTHORITY)%”
upstream 主机和端口:“%UPSTREAM_HOST%”