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: fix panic when tests fail using an existing cluster #41086

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
4 changes: 3 additions & 1 deletion pkg/cmd/roachtest/cluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -1071,7 +1071,9 @@ func (c *cluster) setTest(t testI) {
func (c *cluster) Save(ctx context.Context, msg string, l *logger) {
l.PrintfCtx(ctx, "saving cluster %s for debugging (--debug specified)", c)
// TODO(andrei): should we extend the cluster here? For how long?
c.destroyState.alloc.Freeze()
if c.destroyState.owned { // we won't have an alloc for an unowned cluster
c.destroyState.alloc.Freeze()
}
c.r.markClusterAsSaved(c, msg)
c.destroyState.mu.Lock()
c.destroyState.mu.saved = true
Expand Down