Fixing more bugs in new workload
This commit is contained in:
parent
005421dfc8
commit
c2d334d843
|
@ -182,6 +182,10 @@ struct BlobGranuleCorrectnessWorkload : TestWorkload {
|
|||
}
|
||||
|
||||
ACTOR Future<Void> setUpBlobRange(Database cx, KeyRange range) {
|
||||
if (BGW_DEBUG) {
|
||||
fmt::print(
|
||||
"Setting up blob granule range for [{0} - {1})\n", range.begin.printable(), range.end.printable());
|
||||
}
|
||||
state Reference<ReadYourWritesTransaction> tr = makeReference<ReadYourWritesTransaction>(cx);
|
||||
loop {
|
||||
try {
|
||||
|
@ -215,6 +219,12 @@ struct BlobGranuleCorrectnessWorkload : TestWorkload {
|
|||
return Void();
|
||||
}
|
||||
|
||||
state int directoryIdx = 0;
|
||||
for (; directoryIdx < self->directories.size(); directoryIdx++) {
|
||||
// Set up the blob range first
|
||||
wait(self->setUpBlobRange(cx, self->directories[directoryIdx]->directoryRange));
|
||||
}
|
||||
|
||||
if (BGW_DEBUG) {
|
||||
printf("Initializing Blob Granule Correctness s3 stuff\n");
|
||||
}
|
||||
|
@ -289,11 +299,6 @@ struct BlobGranuleCorrectnessWorkload : TestWorkload {
|
|||
Database cx,
|
||||
Reference<ThreadData> threadData,
|
||||
bool doSetup) {
|
||||
if (doSetup) {
|
||||
// Set up the blob range first
|
||||
wait(self->setUpBlobRange(cx, threadData->directoryRange));
|
||||
}
|
||||
|
||||
// read entire keyspace at the start until granules for the entire thing are available
|
||||
loop {
|
||||
state Transaction tr(cx);
|
||||
|
@ -772,7 +777,7 @@ struct BlobGranuleCorrectnessWorkload : TestWorkload {
|
|||
|
||||
state bool result = true;
|
||||
state int finalRowsValidated;
|
||||
if (threadData->writeVersions.size()) {
|
||||
if (threadData->writeVersions.empty()) {
|
||||
// never had a successful write during the test, likely due to many chaos events. Just wait for granules to
|
||||
// become available and call that a pass, since writer is stopped and will never guarantee anything is
|
||||
// written
|
||||
|
|
Loading…
Reference in New Issue