Skip to content

sql/importer: cap metamorphic batch sizes in TestImportCSVStmt#170013

Merged
trunk-io[bot] merged 1 commit into
cockroachdb:masterfrom
DrewKimball:import-test-speed
May 11, 2026
Merged

sql/importer: cap metamorphic batch sizes in TestImportCSVStmt#170013
trunk-io[bot] merged 1 commit into
cockroachdb:masterfrom
DrewKimball:import-test-speed

Conversation

@DrewKimball
Copy link
Copy Markdown
Collaborator

The test has been timing out under metamorphic builds when kv-batch-size and datum-row-converter-batch-size are randomized to their minimum (1). With 18 subtests sharing one cluster, those values blow through the 15-minute package timeout.

Override both to 10 in the test setup. Adds TestingRaiseDefaultKVBatchSize to pkg/sql/row since kv-batch-size had no testing setter; the existing TestingSetDatumRowConverterBatchSize covers the other.

Local timing with both constants forced to 1 vs 10: 74.6s -> 28.2s.

Fixes: #167087
Release note: None

The test has been timing out under metamorphic builds when
`kv-batch-size` and `datum-row-converter-batch-size` are randomized
to their minimum (1). With 18 subtests sharing one cluster, those
values blow through the 15-minute package timeout.

Override both to 10 in the test setup. Adds TestingRaiseDefaultKVBatchSize
to pkg/sql/row since `kv-batch-size` had no testing setter; the
existing TestingSetDatumRowConverterBatchSize covers the other.

Local timing with both constants forced to 1 vs 10: 74.6s -> 28.2s.

Fixes: cockroachdb#167087
Release note: None
@DrewKimball DrewKimball requested review from a team as code owners May 8, 2026 22:05
@DrewKimball DrewKimball requested review from ZhouXing19 and removed request for a team May 8, 2026 22:05
@trunk-io
Copy link
Copy Markdown
Contributor

trunk-io Bot commented May 8, 2026

😎 Merged successfully - details.

@cockroach-teamcity
Copy link
Copy Markdown
Member

This change is Reviewable

@DrewKimball DrewKimball added backport-25.4.x Flags PRs that need to be backported to 25.4 backport-26.1.x Flags PRs that need to be backported to 26.1 backport-26.2.x Flags PRs that need to be backported to 26.2 labels May 8, 2026
@blathers-crl
Copy link
Copy Markdown

blathers-crl Bot commented May 8, 2026

Detected infrastructure failure (matched: self-hosted runner lost communication with the server). Automatically rerunning failed jobs. (run link)

Copy link
Copy Markdown
Collaborator

@ZhouXing19 ZhouXing19 left a comment

Choose a reason for hiding this comment

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

Nice, thanks!! LGTM.

@DrewKimball
Copy link
Copy Markdown
Collaborator Author

TFTR!

/trunk merge

@trunk-io trunk-io Bot merged commit 6c3e812 into cockroachdb:master May 11, 2026
39 of 40 checks passed
@blathers-crl
Copy link
Copy Markdown

blathers-crl Bot commented May 11, 2026

Based on the specified backports for this PR, I applied new labels to the following linked issue(s). Please adjust the labels as needed to match the branches actually affected by the issue(s), including adding any known older branches.


Issue #167087: branch-release-26.1, branch-release-26.2.


🦉 Hoot! I am a Blathers, a bot for CockroachDB. My owner is dev-inf.

@blathers-crl
Copy link
Copy Markdown

blathers-crl Bot commented May 11, 2026

Encountered an error creating backports. Some common things that can go wrong:

  1. The backport branch might have already existed.
  2. There was a merge conflict.
  3. The backport branch contained merge commits.

You might need to create your backport manually using the backport tool.


error creating backport branch refs/heads/blathers/backport-release-25.4-170013: POST https://api.github.com/repos/DrewKimball/cockroach/git/refs: 403 Resource not accessible by integration []

Backport to branch 25.4.x failed. See errors above.


error creating backport branch refs/heads/blathers/backport-release-26.1-170013: POST https://api.github.com/repos/DrewKimball/cockroach/git/refs: 403 Resource not accessible by integration []

Backport to branch 26.1.x failed. See errors above.


error creating backport branch refs/heads/blathers/backport-release-26.2-170013: POST https://api.github.com/repos/DrewKimball/cockroach/git/refs: 403 Resource not accessible by integration []

Backport to branch 26.2.x failed. See errors above.


🦉 Hoot! I am a Blathers, a bot for CockroachDB. My owner is dev-inf.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport-25.4.x Flags PRs that need to be backported to 25.4 backport-26.1.x Flags PRs that need to be backported to 26.1 backport-26.2.x Flags PRs that need to be backported to 26.2 backport-failed target-release-26.3.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

sql/importer: TestImportCSVStmt failed

3 participants