-
Notifications
You must be signed in to change notification settings - Fork 259
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support Insights access logs and configs #3596
Changes from all commits
ad5a2ab
2cc85b4
4899fb4
381a5dd
de0ccbe
366be3e
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -35,6 +35,13 @@ type accessLog struct { | |
JSONFormat map[string]string | ||
} | ||
|
||
type insightsLog struct { | ||
Enable bool | ||
LogFile string | ||
LoggingFormat string | ||
OmitEmptyValues bool | ||
} | ||
|
||
// AccessLogExcludes represents the configurations related to excludes from access logs. | ||
type AccessLogExcludes struct { | ||
SystemHost AccessLogExcludesSystemHost | ||
|
@@ -60,8 +67,9 @@ type LogConfig struct { | |
Compress bool | ||
} | ||
|
||
Pkg []pkg | ||
AccessLogs *accessLog | ||
Pkg []pkg | ||
AccessLogs *accessLog | ||
InsightsLogs *insightsLog | ||
} | ||
|
||
func getDefaultLogConfig() *LogConfig { | ||
|
@@ -115,6 +123,12 @@ func getDefaultLogConfig() *LogConfig { | |
"extAuthDtls": "%DYNAMIC_METADATA(envoy.filters.http.ext_authz:extAuthDetails)%", | ||
}, | ||
}, | ||
InsightsLogs: &insightsLog{ | ||
Enable: false, | ||
LogFile: "/dev/stdout", | ||
LoggingFormat: "-", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Does it work if we simply provided like this? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. even this is enabled it will just print '-'. but ideally it is not usable and proper config should apply |
||
OmitEmptyValues: true, | ||
}, | ||
} | ||
adapterLogConfig.Rotation.MaxSize = 10 | ||
adapterLogConfig.Rotation.MaxAge = 2 | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If this is something we expect to be mandatory for a given api, we can add a log and monitor from logs for a while.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
discussed and decided we won't require that sort of a log.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not critical atm