Repository navigation
Suppress warnings for transient stdin backpressure - #715
Open
TDnorthgarden wants to merge 2 commits into
Open
TDnorthgarden wants to merge 2 commits into
TDnorthgarden wants to merge 2 commits into
Conversation
create_test_script, update_container_args and skip_if_no_journald were defined in 06-priority-parsing.bats, but the new 07-attach.bats regression test also needs them. Move them to test_helper.bash and remove the now-duplicated definitions from 06-priority-parsing.bats. Signed-off-by: Eduard Zateev <hackerowskiy@gmail.com> Signed-off-by: Aucoto Zhang <tdnorthgarden@gmail.com>
Writes to the container stdin pipe and socket are nonblocking. When they return EAGAIN/EWOULDBLOCK, the pending bytes remain queued and are retried when the fd becomes writable, so this is expected backpressure rather than a write failure. Do not log a warning for those errno values while preserving warnings for other errors. Previously, a slow stdin consumer made conmon log "Failed to write to fd container stdin" on every EAGAIN, flooding the journal. Add an attach regression test that delays the container's stdin reader, sends a 1 MiB payload, and checks that every byte is delivered and conmon's journal contains no spurious warning. Fixes: containers#689 Signed-off-by: Eduard Zateev <hackerowskiy@gmail.com> Signed-off-by: Aucoto Zhang <tdnorthgarden@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Carries #705 — original work by @sairex53, whose Signed-off-by is preserved in both commits. Opened with @kolyshkin's go-ahead after the
original author stayed quiet since the review request of Oct 28.
What this does. Writes to the container stdin pipe and socket are nonblocking; EAGAIN/EWOULDBLOCK mean the bytes stay queued and are
retried when the fd becomes writable. That is expected backpressure, not a failure, so conmon should not warn on it. This stops the
journal flood described in #689 for slow stdin consumers.
Changes on top of #705 (per @kolyshkin's review):
definitions left behind in test/06-priority-parsing.bats
EAGAIN retry
Verification (local, rootless runc + user journal):
Fixes #689.