spacewander commented on a change in pull request #4467:
URL: https://github.com/apache/apisix/pull/4467#discussion_r656181284
##########
File path: conf/config-default.yaml
##########
@@ -169,9 +169,30 @@ nginx_config: # config for render the
template to generate n
http:
enable_access_log: true # enable access log or not, default true
- access_log: "logs/access.log"
- access_log_format: "$remote_addr - $remote_user [$time_local] $http_host
\"$request\" $status $body_bytes_sent $request_time \"$http_referer\"
\"$http_user_agent\" $upstream_addr $upstream_status $upstream_response_time
\"$upstream_scheme://$upstream_host$upstream_uri\""
- access_log_format_escape: default # allows setting json or default
characters escaping in variables
+ # access_log_format: "$remote_addr - $remote_user [$time_local] $http_host
\"$request\" $status $body_bytes_sent $request_time \"$http_referer\"
\"$http_user_agent\" $upstream_addr $upstream_status $upstream_response_time
\"$upstream_scheme://$upstream_host$upstream_uri\""
+ # access_log: "logs/access.log"
+ # access_log_format_escape: default # allows setting json or default
characters escaping in variables
+ access_log:
Review comment:
We can't accept a break change, the new change should be compatible with
the old style, like:
https://github.com/apache/apisix/blob/2707fda3eb7b23d995ac23ecf4a17000dd765855/apisix/cli/ops.lua#L410
##########
File path: conf/config-default.yaml
##########
@@ -169,9 +169,30 @@ nginx_config: # config for render the
template to generate n
http:
enable_access_log: true # enable access log or not, default true
- access_log: "logs/access.log"
- access_log_format: "$remote_addr - $remote_user [$time_local] $http_host
\"$request\" $status $body_bytes_sent $request_time \"$http_referer\"
\"$http_user_agent\" $upstream_addr $upstream_status $upstream_response_time
\"$upstream_scheme://$upstream_host$upstream_uri\""
- access_log_format_escape: default # allows setting json or default
characters escaping in variables
+ # access_log_format: "$remote_addr - $remote_user [$time_local] $http_host
\"$request\" $status $body_bytes_sent $request_time \"$http_referer\"
\"$http_user_agent\" $upstream_addr $upstream_status $upstream_response_time
\"$upstream_scheme://$upstream_host$upstream_uri\""
+ # access_log: "logs/access.log"
+ # access_log_format_escape: default # allows setting json or default
characters escaping in variables
+ access_log:
+ -
+ log_type: "local" # local disk log storage
+ log_format: "$remote_addr - $remote_user [$time_local] $http_host
\"$request\" $status $body_bytes_sent $request_time \"$http_referer\"
\"$http_user_agent\" $upstream_addr $upstream_status $upstream_response_time
\"$upstream_scheme://$upstream_host$upstream_uri\""
+ log_format_name: "main_local"
+ log_format_escape: "default" # allows setting json or default
characters escaping in variables
+ log_path: "logs/access.log" # disk storage path
+ log_buffer: 16384
+ log_flush: 3
+ -
+ log_type: "syslog" # send log to remote syslog
Review comment:
Need to comment out the syslog version by default.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]