remove allowDisablingTenants flag and add new downgrade test
This commit is contained in:
parent
930801b483
commit
702fcd1274
|
@ -315,9 +315,6 @@ class TestConfig : public BasicTestConfig {
|
|||
if (attrib == "allowDefaultTenant") {
|
||||
allowDefaultTenant = strcmp(value.c_str(), "true") == 0;
|
||||
}
|
||||
if (attrib == "allowDisablingTenants") {
|
||||
allowDisablingTenants = strcmp(value.c_str(), "true") == 0;
|
||||
}
|
||||
if (attrib == "allowCreatingTenants") {
|
||||
allowCreatingTenants = strcmp(value.c_str(), "true") == 0;
|
||||
}
|
||||
|
@ -382,7 +379,6 @@ public:
|
|||
bool randomlyRenameZoneId = false;
|
||||
|
||||
bool allowDefaultTenant = true;
|
||||
bool allowDisablingTenants = true;
|
||||
bool allowCreatingTenants = true;
|
||||
bool injectTargetedSSRestart = false;
|
||||
bool injectSSDelay = false;
|
||||
|
@ -453,7 +449,6 @@ public:
|
|||
.add("extraMachineCountDC", &extraMachineCountDC)
|
||||
.add("blobGranulesEnabled", &blobGranulesEnabled)
|
||||
.add("allowDefaultTenant", &allowDefaultTenant)
|
||||
.add("allowDisablingTenants", &allowDisablingTenants)
|
||||
.add("allowCreatingTenants", &allowCreatingTenants)
|
||||
.add("randomlyRenameZoneId", &randomlyRenameZoneId)
|
||||
.add("injectTargetedSSRestart", &injectTargetedSSRestart)
|
||||
|
@ -2481,7 +2476,6 @@ ACTOR void setupAndRun(std::string dataFolder,
|
|||
allowList.addTrustedSubnet("0.0.0.0/2"sv);
|
||||
allowList.addTrustedSubnet("abcd::/16"sv);
|
||||
state bool allowDefaultTenant = testConfig.allowDefaultTenant;
|
||||
state bool allowDisablingTenants = testConfig.allowDisablingTenants;
|
||||
state bool allowCreatingTenants = testConfig.allowCreatingTenants;
|
||||
|
||||
if (!SERVER_KNOBS->SHARD_ENCODE_LOCATION_METADATA) {
|
||||
|
@ -2550,21 +2544,18 @@ ACTOR void setupAndRun(std::string dataFolder,
|
|||
if (testConfig.tenantModes.size()) {
|
||||
auto randomPick = deterministicRandom()->randomChoice(testConfig.tenantModes);
|
||||
tenantMode = TenantMode::fromValue(StringRef(std::to_string(randomPick)));
|
||||
if (tenantMode == TenantMode::REQUIRED) {
|
||||
allowDefaultTenant = true;
|
||||
if (allowDefaultTenant) {
|
||||
defaultTenant = "SimulatedDefaultTenant"_sr;
|
||||
}
|
||||
} else {
|
||||
if (allowDefaultTenant && deterministicRandom()->random01() < 0.5) {
|
||||
defaultTenant = "SimulatedDefaultTenant"_sr;
|
||||
if (deterministicRandom()->random01() < 0.9) {
|
||||
tenantMode = TenantMode::REQUIRED;
|
||||
} else {
|
||||
tenantMode = TenantMode::OPTIONAL_TENANT;
|
||||
}
|
||||
} else if (!allowDisablingTenants || deterministicRandom()->random01() < 0.5) {
|
||||
} else if (allowDefaultTenant && deterministicRandom()->random01() < 0.5) {
|
||||
defaultTenant = "SimulatedDefaultTenant"_sr;
|
||||
if (deterministicRandom()->random01() < 0.9) {
|
||||
tenantMode = TenantMode::REQUIRED;
|
||||
} else {
|
||||
tenantMode = TenantMode::OPTIONAL_TENANT;
|
||||
}
|
||||
} else if (deterministicRandom()->random01() < 0.5) {
|
||||
tenantMode = TenantMode::OPTIONAL_TENANT;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2620,7 +2611,7 @@ ACTOR void setupAndRun(std::string dataFolder,
|
|||
}
|
||||
TraceEvent("SimulatedClusterTenantMode")
|
||||
.detail("UsingTenant", defaultTenant)
|
||||
.detail("TenantRequired", tenantMode.toString())
|
||||
.detail("TenantMode", tenantMode.toString())
|
||||
.detail("TotalTenants", tenantsToCreate.size());
|
||||
std::string clusterFileDir = joinPath(dataFolder, deterministicRandom()->randomUniqueID().toString());
|
||||
platform::createDirectory(clusterFileDir);
|
||||
|
|
|
@ -306,6 +306,9 @@ if(WITH_PYTHON)
|
|||
add_fdb_test(
|
||||
TEST_FILES restarting/from_7.2.0/DrUpgradeRestart-1.txt
|
||||
restarting/from_7.2.0/DrUpgradeRestart-2.txt)
|
||||
add_fdb_test(
|
||||
TEST_FILES restarting/to_7.2.0/CycleTestRestart-1.toml
|
||||
restarting/to_7.2.0/CycleTestRestart-2.toml)
|
||||
|
||||
|
||||
add_fdb_test(TEST_FILES slow/ApiCorrectness.toml)
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
[configuration]
|
||||
allowDefaultTenant = false
|
||||
allowDisablingTenants = false
|
||||
allowDefaultTenant = true
|
||||
tenantModes = [2]
|
||||
|
||||
[[knobs]]
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
[configuration]
|
||||
StderrSeverity = 30
|
||||
allowDisablingTenants = false
|
||||
allowDefaultTenant = false
|
||||
tenantModes = [1]
|
||||
|
||||
[[test]]
|
||||
testTitle = 'FuzzApiCorrectness'
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
[configuration]
|
||||
StderrSeverity = 30
|
||||
allowDisablingTenants = false
|
||||
allowDefaultTenant = false
|
||||
tenantModes = [1]
|
||||
|
||||
[[test]]
|
||||
testTitle = 'FuzzApiCorrectness'
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
[configuration]
|
||||
allowDisablingTenants = false
|
||||
tenantModes = [1]
|
||||
|
||||
[[test]]
|
||||
testTitle = 'SpecialKeySpaceCorrectnessTest'
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
[configuration]
|
||||
allowDefaultTenant = false
|
||||
allowDisablingTenants = false
|
||||
tenantModes = [1]
|
||||
|
||||
[[test]]
|
||||
testTitle = 'TenantCreation'
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
[configuration]
|
||||
allowDefaultTenant = false
|
||||
allowDisablingTenants = false
|
||||
tenantModes = [1]
|
||||
|
||||
[[knobs]]
|
||||
allow_tokenless_tenant_access = true
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
[configuration]
|
||||
allowDefaultTenant = false
|
||||
allowDisablingTenants = false
|
||||
tenantModes = [1]
|
||||
|
||||
[[test]]
|
||||
testTitle = 'TenantEntryCacheTest'
|
||||
|
|
|
@ -0,0 +1,49 @@
|
|||
[configuration]
|
||||
storageEngineExcludeTypes = [3]
|
||||
maxTLogVersion = 6
|
||||
disableTss = true
|
||||
disableHostname = true
|
||||
disableEncryption = true
|
||||
|
||||
[[knobs]]
|
||||
# This can be removed once the lower bound of this downgrade test is a version that understands the new protocol
|
||||
shard_encode_location_metadata = false
|
||||
|
||||
[[test]]
|
||||
testTitle = 'Clogged'
|
||||
clearAfterTest = false
|
||||
|
||||
[[test.workload]]
|
||||
testName = 'Cycle'
|
||||
transactionsPerSecond = 500.0
|
||||
nodeCount = 2500
|
||||
testDuration = 10.0
|
||||
expectedRate = 0
|
||||
|
||||
[[test.workload]]
|
||||
testName = 'RandomClogging'
|
||||
testDuration = 10.0
|
||||
|
||||
[[test.workload]]
|
||||
testName = 'Rollback'
|
||||
meanDelay = 10.0
|
||||
testDuration = 10.0
|
||||
|
||||
[[test.workload]]
|
||||
testName = 'Attrition'
|
||||
machinesToKill = 10
|
||||
machinesToLeave = 3
|
||||
reboot = true
|
||||
testDuration = 10.0
|
||||
|
||||
[[test.workload]]
|
||||
testName = 'Attrition'
|
||||
machinesToKill = 10
|
||||
machinesToLeave = 3
|
||||
reboot = true
|
||||
testDuration = 10.0
|
||||
|
||||
[[test.workload]]
|
||||
testName = 'SaveAndKill'
|
||||
restartInfoLocation = 'simfdb/restartInfo.ini'
|
||||
testDuration = 10.0
|
|
@ -0,0 +1,36 @@
|
|||
[configuration]
|
||||
maxTLogVersion = 6
|
||||
disableTss = true
|
||||
|
||||
[[test]]
|
||||
testTitle = 'Clogged'
|
||||
runSetup = false
|
||||
|
||||
[[test.workload]]
|
||||
testName = 'Cycle'
|
||||
transactionsPerSecond = 2500.0
|
||||
nodeCount = 2500
|
||||
testDuration = 10.0
|
||||
expectedRate = 0
|
||||
|
||||
[[test.workload]]
|
||||
testName = 'RandomClogging'
|
||||
testDuration = 10.0
|
||||
|
||||
[[test.workload]]
|
||||
testName = 'Rollback'
|
||||
meanDelay = 10.0
|
||||
testDuration = 10.0
|
||||
|
||||
[[test.workload]]
|
||||
testName = 'Attrition'
|
||||
machinesToKill = 10
|
||||
machinesToLeave = 3
|
||||
reboot = true
|
||||
testDuration = 10.0
|
||||
|
||||
[[test.workload]]
|
||||
testName = 'Attrition'
|
||||
machinesToKill = 10
|
||||
machinesToLeave = 3
|
||||
reboot = true
|
|
@ -1,7 +1,7 @@
|
|||
[configuration]
|
||||
blobGranulesEnabled = true
|
||||
allowDefaultTenant = false
|
||||
allowDisablingTenants = false
|
||||
tenantModes = [1]
|
||||
injectTargetedSSRestart = true
|
||||
injectSSDelay = true
|
||||
# FIXME: re-enable rocks at some point
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
[configuration]
|
||||
blobGranulesEnabled = true
|
||||
allowDefaultTenant = false
|
||||
allowDisablingTenants = false
|
||||
tenantModes = [1]
|
||||
# FIXME: re-enable rocks at some point
|
||||
storageEngineExcludeTypes = [4, 5]
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
[configuration]
|
||||
allowDefaultTenant = false
|
||||
allowDisablingTenants = false
|
||||
tenantModes = [1]
|
||||
allowCreatingTenants = false
|
||||
extraDatabaseMode = 'Multiple'
|
||||
extraDatabaseCount = 5
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
[configuration]
|
||||
allowDefaultTenant = false
|
||||
allowDisablingTenants = false
|
||||
tenantModes = [1]
|
||||
|
||||
[[test]]
|
||||
testTitle = 'TenantManagementTest'
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
[configuration]
|
||||
allowDefaultTenant = false
|
||||
allowDisablingTenants = false
|
||||
tenantModes = [1]
|
||||
allowCreatingTenants = false
|
||||
extraDatabaseMode = 'Single'
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
[configuration]
|
||||
allowDefaultTenant = false
|
||||
allowDisablingTenants = false
|
||||
tenantModes = [1]
|
||||
allowCreatingTenants = false
|
||||
extraDatabaseMode = 'Single'
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
[configuration]
|
||||
allowDefaultTenant = false
|
||||
allowDisablingTenants = false
|
||||
tenantModes = [1]
|
||||
allowCreatingTenants = false
|
||||
extraDatabaseMode = 'Single'
|
||||
|
||||
|
|
Loading…
Reference in New Issue