Skip to content

CLDSRV-992: Build the uploadPartCopy fixtures once per suite, not per test - #6281

Draft
anurag4DSB wants to merge 1 commit into
development/9.3from
improvement/CLDSRV-992-uploadpartcopy-fixture-per-suite
Draft

CLDSRV-992: Build the uploadPartCopy fixtures once per suite, not per test#6281
anurag4DSB wants to merge 1 commit into
development/9.3from
improvement/CLDSRV-992-uploadpartcopy-fixture-per-suite

Conversation

@anurag4DSB

@anurag4DSB anurag4DSB commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

Intent: why does this change exist?

NEW FIX. Both uploadPartCopy describes in the PartNumber tests rebuild a ~200 MB MPU fixture in a beforeEach, though all four of their tests only issue a GetObject. The redundant second build is what exceeds the 40 s mocha timeout. Clears CLDSRV-992 row F4.

System impact: what's affected, including downstream?

One functional test file, setup and teardown only. No product code, no assertions touched. hotfix/9.2.36 needs the same change and has #6280.

Preserved behavior: what explicitly stays the same?

The fixture is identical and both tests read exactly what they read before. No timeout raised, no retry added, nothing skipped.

Intended change: what's different after this PR?

Setup moves to before and cleanup to after, so each describe builds its fixture once. The enclosing describe already owns the bucket in its own before/after, so the fixture safely outlives the tests.

Verification: how do we know this worked, or how would we know if it didn't?

The cost is arithmetic from the fixture itself: a serial 10x5 MB completeMPU, a 50 MB UploadPartCopy, a 50 MB UploadPart, then a further 5 MB part and second 50 MB copy. Both tests are pure GetObject calls, so the second build did no work they depended on. s3c-ft-tests-v0-null-compat stressed 10x on this branch.

… test

Both `uploadPartCopy` describes in the PartNumber tests rebuild a large MPU
fixture in a beforeEach, although all four of their tests only issue a
GetObject. Each rebuild moves roughly 200 MB: completeMPU uploads ten 5 MB
parts one at a time with async.eachSeries, createMPUAndPutTwoParts copies that
50 MB object and then puts a 50 MB body, and the overwrite variant adds a 5 MB
part and a second 50 MB UploadPartCopy. Doing that twice per describe, once for
each read-only test, is what pushes the hook past the 40 s mocha timeout on the
s3c backend.

Move the setup to `before` and the DeleteObject cleanup to `after`. The fixture
is identical for both tests in each describe, and the enclosing describe creates
the bucket in its own `before` and drops it in `after`, so the fixture safely
outlives the individual tests. Halves the data moved by these two describes and
removes the redundant rebuild, rather than raising the timeout.

Clears CLDSRV-992 row F4 (run 33630581671) and the timeout half of row F8
(run 33647777908, fixed for the 9.2 line separately).

Issue: CLDSRV-992
@bert-e

bert-e commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

Hello anurag4dsb,

My role is to assist you with the merge of this
pull request. Please type @bert-e help to get information
on this process, or consult the user documentation.

Available options
name description privileged authored
/after_pull_request Wait for the given pull request id to be merged before continuing with the current one.
/bypass_author_approval Bypass the pull request author's approval
/bypass_build_status Bypass the build and test status
/bypass_commit_size Bypass the check on the size of the changeset TBA
/bypass_incompatible_branch Bypass the check on the source branch prefix
/bypass_jira_check Bypass the Jira issue check
/bypass_peer_approval Bypass the pull request peers' approval
/bypass_leader_approval Bypass the pull request leaders' approval
/bypass_source_branch_lineage Bypass the cross-branch contamination check
/approve Instruct Bert-E that the author has approved the pull request. ✍️
/create_pull_requests Allow the creation of integration pull requests.
/create_integration_branches Allow the creation of integration branches.
/no_octopus Prevent Wall-E from doing any octopus merge and use multiple consecutive merge instead
/unanimity Change review acceptance criteria from one reviewer at least to all reviewers
/wait Instruct Bert-E not to run until further notice.
Available commands
name description privileged
/help Print Bert-E's manual in the pull request.
/status Print Bert-E's current status in the pull request.
/clear Remove all comments from Bert-E from the history TBA
/retry Re-start a fresh build TBA
/build Re-start a fresh build TBA
/force_reset Delete integration branches & pull requests, and restart merge process from the beginning.
/reset Try to remove integration branches unless there are commits on them which do not appear on the source branch.

Status report is not available.

@bert-e

bert-e commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

Incorrect fix version

The Fix Version/s in issue CLDSRV-992 contains:

  • None

Considering where you are trying to merge, I ignored possible hotfix versions and I expected to find:

  • 9.3.21

  • 9.4.4

  • 9.5.0

Please check the Fix Version/s of CLDSRV-992, or the target
branch of this pull request.

@codecov

codecov Bot commented Sep 8, 2026

Copy link
Copy Markdown

❌ 1 Tests Failed:

Tests completed Failed Passed Skipped
8542 1 8541 0
View the top 1 failed test(s) by shortest run time
should return QuotaExceeded when trying to copy a part in a bucket with quota::quota evaluation with scuba metrics should return QuotaExceeded when trying to copy a part in a bucket with quota
Stack Traces | 0.097s run time
Expected values to be strictly equal:
+ actual - expected

+ 'NoSuchUpload'
- 'QuotaExceeded'

To view more test analytics, go to the Test Analytics Dashboard
📋 Got 3 mins? Take this short survey to help us improve Test Analytics.

Comment thread .github/workflows/tests.yaml Outdated
async-migration-report:
runs-on: ubuntu-24.04
if: startsWith(github.ref, 'refs/heads/development/')
if: false # CLDSRV-992 stress: unrelated job

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Stress-testing scaffolding: this if: false disables the async-migration-report job. Along with similar if: false guards on multiple-backend, mongo-v0-ft-tests, mongo-v1-ft-tests, file-ft-tests, utapi-v2-tests, sur-tests, kmip-ft-tests, kmip-cluster-ft-tests, sse-kms-migration-tests, and the final aggregation job — 11 CI jobs are disabled. These changes must be reverted before merge, otherwise CI coverage is permanently lost.

Comment thread .github/workflows/tests.yaml Outdated
# Configure and run as Integration run S3C tests
s3c-ft-tests:
strategy:
fail-fast: false

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Stress-testing scaffolding: the original matrix had three configurations (v0, v0-null-compat, v1) but this replaces them with 10 identical v0-null-compat entries. The v0 (without null-compat) and v1 configurations are dropped entirely. This must be reverted to the original matrix before merge — merging as-is permanently removes v1 and non-null-compat v0 test coverage.

@anurag4DSB
anurag4DSB marked this pull request as ready for review September 8, 2026 11:02
@anurag4DSB
anurag4DSB force-pushed the improvement/CLDSRV-992-uploadpartcopy-fixture-per-suite branch from 00cfff2 to 6d9d021 Compare September 8, 2026 11:02
@anurag4DSB
anurag4DSB marked this pull request as draft September 8, 2026 11:15
@anurag4DSB

Copy link
Copy Markdown
Contributor Author

Moving back to draft — the rationale for this change does not hold up.

I justified it as "the fixture is too expensive for the 40 s budget", but measuring the CI logs shows the fixture is not slow: the tests around it run in 38–657 ms, and in the failing runs the same fixture builds successfully three or four times and then stalls once. That is an intermittent stall, not slow work, so building it once per suite only halves the exposure without explaining the cause — and it gives up per-test independence to do so, which is a bad trade.

Independence here is also load-bearing rather than incidental: sibling tests in the same describe do plain PutObject to objectName (get.js:813, :831, :851, :880), clobbering the MPU, which is exactly why completeMPU is re-run per test.

These jobs are also the ones that capture no cloudserver log, so the stall is currently undiagnosable. #6283 adds that capture; I will come back to this row once a recurrence can name its own cause.

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