Skip to content

Conversation

@TingDaoK
Copy link
Contributor

Issue #, if available:

  • We are adding the event back to the queue after we finish the task to delivery the current available events.
  • When we add them back, it's possible that the window was open up for another delivery now.
  • However, we only check for if new delivery needed or not when we open the window. And when the task is still running there is no outstanding deliveries, so we are NOT rescheduling the task and lead to a possible deadlock.
  • So, we should check again when we add events back to the queue, but also check if there is available window as well to avoid infinite loop.
  • It's okay to schedule another task while it's still running.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@TingDaoK TingDaoK marked this pull request as ready for review November 25, 2025 00:11
@codecov-commenter
Copy link

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 89.19%. Comparing base (a109fa6) to head (2bfe376).

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             main     #601   +/-   ##
=======================================
  Coverage   89.18%   89.19%           
=======================================
  Files          23       23           
  Lines        7576     7579    +3     
=======================================
+ Hits         6757     6760    +3     
  Misses        819      819           
Files with missing lines Coverage Δ
source/s3_meta_request.c 91.36% <100.00%> (+0.02%) ⬆️
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

if (aws_array_list_length(&incomplete_deliver_events_array) > 0) {
/* Only if we don't have any window to deliver the bytes, we will have incomplete parts. */
AWS_FATAL_ASSERT(bytes_allowed_to_deliver == 0);
/* Push the iocompileted events back to the queue */
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
/* Push the iocompileted events back to the queue */
/* Push the incomplete events back to the queue */

@TingDaoK TingDaoK enabled auto-merge (squash) November 25, 2025 01:04
@TingDaoK TingDaoK merged commit 4782ecb into main Nov 25, 2025
38 checks passed
@TingDaoK TingDaoK deleted the fix-readwindow branch November 25, 2025 01:17
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.

3 participants