Skip to content

oidc: add tcp keep alive to idp - #3568

Closed
zhaohuabing wants to merge 1 commit into
envoyproxy:mainfrom
zhaohuabing:fix-oidc-connection
Closed

zhaohuabing wants to merge 1 commit into
envoyproxy:mainfrom
zhaohuabing:fix-oidc-connection

Conversation

@zhaohuabing

@zhaohuabing zhaohuabing commented Jun 8, 2024 •

Copy link
Copy Markdown
Member

This PR adds a tcpkeepalive to the IDP provider cluster of OIDC.

This is a workaround before retry is supported in Envoy upstream. envoyproxy/envoy#33572

Fix: #3178

Signed-off-by: Huabing Zhao <[email protected]>
@zhaohuabing
zhaohuabing requested a review from a team as a code owner June 8, 2024 00:54
@codecov

codecov Bot commented Jun 8, 2024

Copy link
Copy Markdown

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 68.17%. Comparing base (33fceb0) to head (fa5173c).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3568      +/-   ##
==========================================
+ Coverage   68.14%   68.17%   +0.02%     
==========================================
  Files         168      168              
  Lines       20408    20409       +1     
==========================================
+ Hits        13908    13913       +5     
+ Misses       5497     5494       -3     
+ Partials     1003     1002       -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@arkodg

arkodg commented Jun 8, 2024 •

Copy link
Copy Markdown
Contributor

id prefer to understand what is happening in the envoy side, and why its reusing the connection even after receiving an RST, so prefer if we collected cluster metrics, logs in debug/trace level before we proposed a fix

@coro

coro commented Jun 18, 2024

Copy link
Copy Markdown
Contributor

Screenshot 2024-06-18 at 17 08 53

Here is a look at the metrics when we encountered this issue multiple times over one day. It seems like there is a strong correlation between instances of OAuth flow failed errors and the envoy_cluster_upstream_cx_destroy_remote_with_active_rq metric increasing. I've attached logs in debug level in the linked issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Intermittent 'OAuth Flow Failure' potentially caused by reuse of old connections in pool

3 participants