{"record":{"id":"39a3355f6c626173","repo":"apache/cassandra","slug":"max-concurrent-automatic-sstable-upgrades-is","errorCode":null,"errorMessage":"max_concurrent_automatic_sstable_upgrades ({}) is larger than concurrent_compactors ({})","messagePattern":"max_concurrent_automatic_sstable_upgrades \\((.+?)\\) is larger than concurrent_compactors \\((.+?)\\)","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"src/java/org/apache/cassandra/config/DatabaseDescriptor.java","lineNumber":5238,"sourceCode":"    public static int maxConcurrentAutoUpgradeTasks()\n    {\n        return conf.max_concurrent_automatic_sstable_upgrades;\n    }\n\n    public static void setMaxConcurrentAutoUpgradeTasks(int value)\n    {\n        if (conf.max_concurrent_automatic_sstable_upgrades != value)\n            logger.debug(\"Changing max_concurrent_automatic_sstable_upgrades to {}\", value);\n        validateMaxConcurrentAutoUpgradeTasksConf(value);\n        conf.max_concurrent_automatic_sstable_upgrades = value;\n    }\n\n    private static void validateMaxConcurrentAutoUpgradeTasksConf(int value)\n    {\n        if (value < 0)\n            throw new ConfigurationException(\"max_concurrent_automatic_sstable_upgrades can't be negative\");\n        if (value > getConcurrentCompactors())\n            logger.warn(\"max_concurrent_automatic_sstable_upgrades ({}) is larger than concurrent_compactors ({})\", value, getConcurrentCompactors());\n    }\n\n    public static AuditLogOptions getAuditLoggingOptions()\n    {\n        return conf.audit_logging_options;\n    }\n\n    public static void setAuditLoggingOptions(AuditLogOptions auditLoggingOptions)\n    {\n        conf.audit_logging_options = new AuditLogOptions.Builder(auditLoggingOptions).build();\n    }\n\n    public static Config.CorruptedTombstoneStrategy getCorruptedTombstoneStrategy()\n    {\n        return conf.corrupted_tombstone_strategy;\n    }\n\n    public static void setCorruptedTombstoneStrategy(Config.CorruptedTombstoneStrategy strategy)","sourceCodeStart":5220,"sourceCodeEnd":5256,"githubUrl":"https://github.com/apache/cassandra/blob/88fd0f6a0eaed8943f05ac9e8f947882b8ddc8f1/src/java/org/apache/cassandra/config/DatabaseDescriptor.java#L5220-L5256","documentation":"max_concurrent_automatic_sstable_upgrades limits how many SSTables are concurrently auto-upgraded (e.g. after changing a compaction or compression setting). If it is set higher than concurrent_compactors, there are not enough compactor threads to ever reach that concurrency, so DatabaseDescriptor logs this warning via validateMaxConcurrentAutoUpgradeTasksConf.","triggerScenarios":"Calling nodetool setmaxconcurrentautoupgradetasks N or setconcurrent_compactors after it, such that N > getConcurrentCompactors(); the validation runs on config updates with a negative value throwing ConfigurationException instead.","commonSituations":"Operators raising the auto-upgrade limit to speed post-config SSTable upgrades without checking the compactor count; lowering concurrent_compactors later leaves the stale larger upgrade limit in place.","solutions":["Set max_concurrent_automatic_sstable_upgrades to a value <= concurrent_compactors (e.g. nodetool setmaxconcurrentautoupgradetasks <concurrent_compactors>)","Or raise concurrent_compactors to match or exceed the auto-upgrade limit","Verify with nodetool getconcurrentcompactors and nodetool getmaxconcurrentautoupgradetasks"],"exampleFix":"// before\nnodetool setmaxconcurrentautoupgradetasks 16   # with 8 compactors\n// after\nnodetool setmaxconcurrentautoupgradetasks 8","handlingStrategy":"validation","validationCode":"int compactors = DatabaseDescriptor.getConcurrentCompactors();\nif (cfg.maxConcurrentAutoUpgradeTasks > compactors) System.out.println(\"Lowering auto-upgrade tasks to \" + compactors);","typeGuard":null,"tryCatchPattern":"try { DatabaseDescriptor.validateMaxConcurrentAutoUpgradeTasksConf(v); } catch (ConfigurationException e) { /* negative value */ }","preventionTips":["Reconcile the two settings after changing concurrent_compactors","Use nodetool getmaxconcurrentautoupgradetasks vs getconcurrentcompactors in health checks","Default max_concurrent_automatic_sstable_upgrades to -1 (unbounded/auto) unless tuning"],"tags":["cassandra","compaction","configuration"],"backgroundTag":"invalid-config-value","analyzedSha":"88fd0f6a0eaed8943f05ac9e8f947882b8ddc8f1","analyzedAt":"2026-09-10T07:29:22.284Z","contentChangedAt":"2026-09-10T07:29:22.284Z","schemaVersion":2},"datasetVersion":"2026-09-17T15:17:12.973Z"}