access log: add DYNAMIC_METADATA_UNQUOTED formatter#12991
access log: add DYNAMIC_METADATA_UNQUOTED formatter#12991rgs1 wants to merge 4 commits intoenvoyproxy:masterfrom
Conversation
This is useful when you are using the header-to-metadata filter to clean up headers and then you want to send that to the access log as plain, non quoted, text. Signed-off-by: Raul Gutierrez Segales <rgs@pinterest.com>
|
Per @fishcakez , |
Signed-off-by: Raul Gutierrez Segales <rgs@pinterest.com>
FWIW, I prefer |
zuercher
left a comment
There was a problem hiding this comment.
I have to say I'm leery of this change. Feels like we're in this perpetual state of adding more and more little tweeks for this format or that.
I know. I am also not super excited about having to add this, but I am not sure what other options we have. There's no way to add internal formatters and the cleanest way for us to scrub/clean headers that needed to be logged is:
but the latter isn't happy with old school logging (e.g.: plain).... |
Signed-off-by: Raul Gutierrez Segales <rgs@pinterest.com>
|
I think it should be possible to allow extensions to provide their own formatters. But maybe that's one extension type too many. |
|
@zuercher so shall we let this one land or do we want to explore the extensions path? |
|
FWIW we already have an extension point for access log filters. Having one for formatters seems like it might be worth it also. |
|
The only problem I have with landing it that it's forever. I think I'd prefer some change to the parsing of |
Alas, I don't think it would be pretty because:
which means we can't -- cleanly -- add more parameters within the parentheses. After the final to get what we want.... which is a bit yucky. Hmm. Thoughts? [0] https://github.com/envoyproxy/envoy/blob/master/include/envoy/network/filter.h#L276 |
Sounds like this would be the way forward then, given my above comment about extending |
|
I think moving to extensions would be the best thing. For the suffix to control output, you could have a further :-separated list of things. So |
|
Closing this in favor of #13411. |
These are useful for extensions and I need parseCommand() for the extension that will replace: envoyproxy#12991 internally. Signed-off-by: Raul Gutierrez Segales <rgs@pinterest.com>
This is useful when you are using the header-to-metadata filter to clean
up headers and then you want to send that to the access log as plain, non
quoted, text.
Signed-off-by: Raul Gutierrez Segales rgs@pinterest.com