Test detach while attach is still in progress

This commit is contained in:
Heikki Linnakangas
2022-11-24 00:01:11 +02:00
committed by Christian Schwarz
parent 978f1879b9
commit 0d533ce840
2 changed files with 87 additions and 2 deletions

View File

@@ -640,6 +640,10 @@ impl Tenant {
crashsafe::fsync(marker_file.parent().expect("marker file has parent dir"))
.context("fsync tenant directory after unlinking attach marker file")?;
fail::fail_point!("attach-before-activate", |_| {
anyhow::bail!("failpoint attach-beore-activate");
});
// FIXME: Check if the state has changed to Stopping while we were downloading stuff
// We're ready for business.
// Change to active state under the hood spawns background loops