Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

roachtest: add debugging to help deflake backup/mixed-version #73377

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion pkg/cmd/roachtest/backup.go
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,8 @@ func registerBackupMixedVersion(r *testRegistry) {
// in the backup code. Here, we force the range containing this data through the gc queue which
// will GC the old revision as it is not the latest and well past the gc.ttl.
workaroundForAncientData := func(ctx context.Context, t *test, u *versionUpgradeTest) {
db := c.Conn(ctx, 1)
waitForFullReplication(t, db)
t.Status("sending enqueue_range request for queue=gc and range=5")
req := &serverpb.EnqueueRangeRequest{
Queue: "gc",
Expand All @@ -224,16 +226,17 @@ func registerBackupMixedVersion(r *testRegistry) {
var resp serverpb.EnqueueRangeResponse
err := httputil.PostJSON(*http.DefaultClient, url, req, &resp)
require.NoError(t, err)
t.l.Printf("EnqueueRangeResponse: %v", resp)
}

u := newVersionUpgradeTest(c,
uploadAndStartFromCheckpointFixture(roachNodes, predV),
waitForUpgradeStep(roachNodes),
preventAutoUpgradeStep(1),
workaroundForAncientData,
loadBackupDataStep,
// Upgrade some of the nodes.
binaryUpgradeStep(c.Nodes(1, 2), mainVersion),
workaroundForAncientData,
// Backup from new node should succeed
successfulBackupStep(1),
// Backup from new node with revision history should succeed
Expand Down