envoyproxy/envoy

[dataplane] reset ActiveStream::streamInfo().route() when clearRouteCache()

Open

#20,157 建立於 2022年3月1日

在 GitHub 查看
 (5 留言) (0 反應) (1 負責人)C++ (5,373 fork)batch import
area/httpbughelp wanted

倉庫指標

Star
 (27,997 star)
PR 合併指標
 (平均合併 8天) (30 天內合併 378 個 PR)

描述

Title: reset ActiveStream::streamInfo().route() when clearRouteCache()

Description: There is a gap between the ActiveStreamFilterBase::clearRouteCache and ActiveStreamFilterBase::streamInfo()::route():

whenever we call clearRouteCache(), the {en,de}coder_callback_.route() ONLY!, the streamInfo().route() is NOT updated.

The "new" route() on {en,de}coder_callback_ will be reset when we refreshCachedRoute(), by either explicitly calling it, or calling {en,de}coder_callback_.route().

So after a clearCachedRoute(), the route() on streamInfo is "stale" and will be out-of-date until refreshCachedRoute() is called.

we should explicitly clear/reset streamINfo()::route_ in clearRouteCache()

貢獻者指南