-
Notifications
You must be signed in to change notification settings - Fork 422
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
api: access log disabled should be optional #5564
Conversation
Signed-off-by: zirain <zirain2009@gmail.com>
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #5564 +/- ##
==========================================
+ Coverage 65.19% 65.21% +0.01%
==========================================
Files 213 213
Lines 34111 33954 -157
==========================================
- Hits 22238 22142 -96
+ Misses 10545 10485 -60
+ Partials 1328 1327 -1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
@@ -266,7 +266,7 @@ func (t *Translator) processAccessLog(envoyproxy *egv1a1.EnvoyProxy, resources * | |||
if envoyproxy == nil || | |||
envoyproxy.Spec.Telemetry == nil || | |||
envoyproxy.Spec.Telemetry.AccessLog == nil || | |||
(!envoyproxy.Spec.Telemetry.AccessLog.Disable && len(envoyproxy.Spec.Telemetry.AccessLog.Settings) == 0) { | |||
(!ptr.Deref(envoyproxy.Spec.Telemetry.AccessLog.Disable, false) && len(envoyproxy.Spec.Telemetry.AccessLog.Settings) == 0) { |
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.
Can we add/modify a gateway api test, where this is omitted from input testdata with no change in out?
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.
sorry, I didn't get your point.
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.
@zirain We don't seem to have a test for this, can we have a test with accessLog: {}
. Modifying an existing test with enabled access logs should work.
gateway/internal/gatewayapi/testdata/disable-accesslog.in.yaml
Lines 9 to 10 in 54efa34
accessLog: | |
disable: true |
/retest |
fixes: #5553