Skip to content

Handle scale factors less than 1 in worker creation#72

Merged
HanzhouTang merged 1 commit into
dsqlfrom
fix-tpcc-test
Feb 3, 2026
Merged

Handle scale factors less than 1 in worker creation#72
HanzhouTang merged 1 commit into
dsqlfrom
fix-tpcc-test

Conversation

@HanzhouTang
Copy link
Copy Markdown
Collaborator

Ensure totalWarehouses defaults to 1 when scale factor truncates to 0. This fixes TestTPCCWorker failures where DB_SCALE_FACTOR=0.01 caused "The end index must be >= 1" assertion errors.

Description of changes:

Fix TPC-C worker creation to handle scale factors less than 1 by ensuring at least 1 warehouse is used, preventing assertion failures in unit tests where scaleFactor=0.01 truncates to 0.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Ensure totalWarehouses defaults to 1 when scale factor truncates to 0.
This fixes TestTPCCWorker failures where DB_SCALE_FACTOR=0.01 caused
"The end index must be >= 1" assertion errors.
@HanzhouTang HanzhouTang enabled auto-merge February 3, 2026 00:59
@HanzhouTang HanzhouTang merged commit 1ba325a into dsql Feb 3, 2026
9 checks passed
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