Skip to content

cloud: fixes GCS test simulating download interrupts#49840

Merged
craig[bot] merged 2 commits intocockroachdb:masterfrom
adityamaru:gcs-test-fix
Jun 8, 2020
Merged

cloud: fixes GCS test simulating download interrupts#49840
craig[bot] merged 2 commits intocockroachdb:masterfrom
adityamaru:gcs-test-fix

Conversation

@adityamaru
Copy link
Copy Markdown
Contributor

No description provided.

…rrupts

TestAntagonisticRead simulates download interrupts for the google
cloud storage reader by "randomly" injecting low level errors.

There was a small bug whereby we were allowing more errors to be injected
than the total number of retries in the GCS ReadFile method. This would
cause the test to fail.

Release Note: None
The constant `maxNoProgressReads` governs how many Read
attempts we can go without receiving any bytes.

Previously, our conditions were allowing one more than
the constant value because of the retry counter being
zero-indexed. This should not have any impact on the
logic.

Release Note: None
@adityamaru adityamaru requested a review from miretskiy June 3, 2020 17:42
@cockroach-teamcity
Copy link
Copy Markdown
Member

This change is Reviewable

@adityamaru
Copy link
Copy Markdown
Contributor Author

The test is still disabled, but managed to run it a 1000 times without failures.

@miretskiy miretskiy self-requested a review June 3, 2020 18:03
Copy link
Copy Markdown
Contributor

@miretskiy miretskiy left a comment

Choose a reason for hiding this comment

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

I don't usually make off by 2 errors; but when I do, I do it in tests :lgtm:

Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained (waiting on @miretskiy)

@adityamaru
Copy link
Copy Markdown
Contributor Author

TFTR!

bors r+

@craig
Copy link
Copy Markdown
Contributor

craig bot commented Jun 8, 2020

Build succeeded

@craig craig bot merged commit 5689836 into cockroachdb:master Jun 8, 2020
@adityamaru adityamaru deleted the gcs-test-fix branch June 8, 2020 14:04
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.

3 participants