Access log status code filter not working for response code 0
- Dominant language
- C++
- Stars
- 28.9k
- Forks
- 5.6k
- Avg merge
- 1d 20h
- Merged PRs (30d)
- 428
Description
*Description*:
Unable to use status code filters to log requests with a 0 response code.
*Repro steps*:
We are running Istio 1.6.13 which uses Envoy 1.15.4. We want to only output access logs for HTTP requests with responses >= 400 or == 0.
This is the filter being applied:
```
filter:
or_filter:
filters:
- status_code_filter:
comparison:
op: GE
value:
default_value: "400"
runtime_key: "400"
- status_code_filter:
comparison:
op: EQ
value:
default_value: "0"
runtime_key: "0"
```
All 4xx/5xx requests are being logged, and 1xx/2xx/3xx requests are not logged, as expected. However, any requests with response code 0 are also not being logged.
Has this been resolved in a newer version of Envoy/Istio?
If not:
1. Is this the intended behaviour because the status code filter only gets applied to valid HTTP response codes?
2. Is there a different filter that can be applied to make sure all 0 responses get logged?
Contributor guide
Assessment
This issue has not been assessed yet.