Skip to content

[fix][test]fix flaky test TxnLogBufferedWriterTest.testMainProcess - #18290

Merged
Technoboy- merged 1 commit into
apache:masterfrom
poorbarcode:flaky/mainProcess
Nov 2, 2022
Merged

Technoboy- merged 1 commit into
apache:masterfrom
poorbarcode:flaky/mainProcess

Conversation

@poorbarcode

Copy link
Copy Markdown
Contributor

Motivation

see:

TxnLogBufferedWriter is used to write multiple data to the ledger in batches and maintains a task queue internally. When the TxnLogBufferedWriter.close is called, tasks that have not yet been executed in the queue will fail early, causing the failed task get callback before the previous tasks. This makes it flaky to validate the execution results sequentially.

Modifications

  • Only verify that the order of the correct callback is verified
  • Make sure all requests have received callbacks.

Documentation

  • doc
  • doc-required
  • doc-not-needed
  • doc-complete

Matching PR in forked repository

PR in forked repository:

@github-actions github-actions Bot added the doc-not-needed Your PR changes do not impact docs label Nov 1, 2022
@codelipenghui codelipenghui added this to the 2.12.0 milestone Nov 2, 2022
@codelipenghui

Copy link
Copy Markdown
Contributor

/pulsarbot run-failure-checks

@codecov-commenter

codecov-commenter commented Nov 2, 2022 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 51.91%. Comparing base (0866c3a) to head (2414582).
⚠️ Report is 3402 commits behind head on master.

Additional details and impacted files

Impacted file tree graph

@@              Coverage Diff              @@
##             master   #18290       +/-   ##
=============================================
+ Coverage     38.97%   51.91%   +12.94%     
+ Complexity     8311     7383      -928     
=============================================
  Files           683      400      -283     
  Lines         67325    43624    -23701     
  Branches       7217     4476     -2741     
=============================================
- Hits          26239    22649     -3590     
+ Misses        38079    18528    -19551     
+ Partials       3007     2447      -560     
Flag Coverage Δ
unittests 51.91% <ø> (+12.94%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.
see 342 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@Technoboy-
Technoboy- merged commit 1f7a8c4 into apache:master Nov 2, 2022
@poorbarcode
poorbarcode deleted the flaky/mainProcess branch November 2, 2022 04:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

doc-not-needed Your PR changes do not impact docs ready-to-test type/flaky-tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants