Use connection's filter state object when available for filter state#310
Use connection's filter state object when available for filter state#310jplevyak merged 5 commits intoenvoyproxy:masterfrom
Conversation
kyessenov
left a comment
There was a problem hiding this comment.
We should not displace request filter state. These are different filter states -- one applies to many requests. I think we need to expose both for now using a different accessor, e.g. connection_filter_state.
We will need upstream filter state later, too.
@kyessenov : thanks for the feedback. Yes, I saw stats plugin stopped working because of this logic. Added accessor for connection_filter_state. |
f9387b8 to
6282eca
Compare
|
@kyessenov , @PiotrSikora ,@jplevyak: This is ready for review.. |
| case PropertyToken::FILTER_STATE: | ||
| value = CelValue::CreateMap( | ||
| Protobuf::Arena::Create<WasmStateWrapper>(&arena, info->filterState())); | ||
| if (getConnection()) { |
There was a problem hiding this comment.
Store the connection in a local and check if it is nullptr then reuse that local to get the filter state.
…quest's filter state object Signed-off-by: gargnupur <gargnupur@google.com> Fixed based on feedback Signed-off-by: gargnupur <gargnupur@google.com> Fixed formatting Signed-off-by: gargnupur <gargnupur@google.com>
Signed-off-by: gargnupur <gargnupur@google.com>
Signed-off-by: gargnupur <gargnupur@google.com>
Signed-off-by: gargnupur <gargnupur@google.com>
Use connection's filter state object when available as compared to request's filter state object
Description: Use connection's filter state object when available as compared to request's filter state object
Risk Level: Medium
Testing: Test in Istio/Proxy
Docs Changes:
Release Notes:
[Optional Fixes #Issue]
[Optional Deprecated:]