Skip to content

sockets: flipping graceful client socket creation failure#32602

Merged
RyanTheOptimist merged 2 commits intoenvoyproxy:mainfrom
alyssawilk:socket
Mar 1, 2024
Merged

sockets: flipping graceful client socket creation failure#32602
RyanTheOptimist merged 2 commits intoenvoyproxy:mainfrom
alyssawilk:socket

Conversation

@alyssawilk
Copy link
Copy Markdown
Contributor

@alyssawilk alyssawilk commented Feb 27, 2024

Allowing graceful client socket creation failure by default in Envoy

Risk Level: medium
Testing: yes
Docs Changes: n/a
Release Notes: inline
[Optional Runtime guard:] yes.

Signed-off-by: Alyssa Wilk <alyssar@chromium.org>
@repokitteh-read-only
Copy link
Copy Markdown

As a reminder, PRs marked as draft will not be automatically assigned reviewers,
or be handled by maintainer-oncall triage.

Please mark your PR as ready when you want it to be reviewed!

🐱

Caused by: #32602 was opened by alyssawilk.

see: more, trace.

@repokitteh-read-only
Copy link
Copy Markdown

CC @envoyproxy/runtime-guard-changes: FYI only for changes made to (source/common/runtime/runtime_features.cc).

🐱

Caused by: #32602 was opened by alyssawilk.

see: more, trace.

@alyssawilk
Copy link
Copy Markdown
Contributor Author

/retest

@alyssawilk alyssawilk marked this pull request as ready for review February 28, 2024 21:17
@alyssawilk
Copy link
Copy Markdown
Contributor Author

so my concern with the last PR was that I was missing some corner case where we weren't release asserting on the listener side, but it turns out we really were - in the case of not binding to socket we really never create the socket so no need to release assert as socket creation can't fail.

Copy link
Copy Markdown
Contributor

@RyanTheOptimist RyanTheOptimist left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, modulo a typo in the release notes (and a question to confirm I understand what's happening)

- area: sockets
change: |
Failure to create an upstream socket should now result in clean connection failure rather than failing a release assert. This behavior
can be temporarily reverted by setting runtime feature ``envoy.restart_features_.llow_client_socket_creation_failure`` to false.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: "features_.llow" => "features.allow", I think?

UdsListenSocket::UdsListenSocket(const Address::InstanceConstSharedPtr& address)
: ListenSocketImpl(ioHandleForAddr(Socket::Type::Stream, address, {}), address) {
RELEASE_ASSERT(io_handle_->isOpen(), "");
RELEASE_ASSERT(io_handle_ && io_handle_->isOpen(), "");
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From the release notes, the impression I have is that this release assert change would be guarded y the runtime feature. But that's not the case here. Presumably that's ok, because this is just downstream of the actual important code which guarded by the feature. is that right?

@RyanTheOptimist
Copy link
Copy Markdown
Contributor

/wait

Signed-off-by: Alyssa Wilk <alyssar@chromium.org>
@RyanTheOptimist RyanTheOptimist merged commit 44d580c into envoyproxy:main Mar 1, 2024
mattjo added a commit to mattjo/envoy that referenced this pull request Mar 5, 2024
* main: (151 commits)
  http3: fixing an upstream threading issue and bumping http3 upstream code back to alpha (envoyproxy#32640)
  rlqs: reset quota usage (envoyproxy#32569)
  proxy status: add more mapping to proxystatus (envoyproxy#32606)
  rlqs: add logging around token bucket (envoyproxy#32612)
  Logging: ENVOY_BUG include filter name. (envoyproxy#32663)
  mobile: Reenable the FilterIntegrationTest.AltSvcCachedH2Slow test (envoyproxy#32675)
  c++20 by default (envoyproxy#32585)
  Docs: Add diagram for histogram stat sink. (envoyproxy#32665)
  Fix null node for list of struct in payload_to_metadaata filter (envoyproxy#32309)
  metrics_service: populate histogram summary sample sum (envoyproxy#32666)
  build(deps): bump postgres from `0e564da` to `f58300a` in /examples/shared/postgres (envoyproxy#32632)
  build(deps): bump the examples-ext-authz group in /examples/ext_authz with 1 update (envoyproxy#32654)
  build(deps): bump distroless/base-nossl-debian12 from `28dc895` to `0e777c6` in /ci (envoyproxy#32652)
  Update QUICHE from 02047e04d to 3373df94b (envoyproxy#32650)
  ci/logging: Add failure detection (envoyproxy#32662)
  Change udpa renaming workaround to not compile the same archive twice (envoyproxy#32647)
  sockets: flipping graceful client socket creation failure (envoyproxy#32602)
  TcpAsyncClient: enhance reconnect robustness (envoyproxy#32578)
  owners: adding Fredy as an Enovy Mobile maintainer (envoyproxy#32638)
  ci: Add scheduled garbage collection (and fix retest) (envoyproxy#32639)
  ...
@alyssawilk alyssawilk deleted the socket branch May 31, 2024 16:03
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.

2 participants