{"record":{"id":"9543c2ff02695dc5","repo":"apache/cassandra","slug":"concurrent-materialized-view-builders-should-be-st","errorCode":null,"errorMessage":"concurrent_materialized_view_builders should be strictly greater than 0, but was ${conf.concurrent_materialized_view_builders}","messagePattern":"concurrent_materialized_view_builders should be strictly greater than 0, but was (.+?)","errorType":"validation","errorClass":"ConfigurationException","httpStatus":null,"severity":"error","filePath":"src/java/org/apache/cassandra/config/DatabaseDescriptor.java","lineNumber":973,"sourceCode":"        if (conf.memtable_cleanup_threshold < 0.01f)\n            throw new ConfigurationException(\"memtable_cleanup_threshold must be >= 0.01, but was \" + conf.memtable_cleanup_threshold, false);\n        if (conf.memtable_cleanup_threshold > 0.99f)\n            throw new ConfigurationException(\"memtable_cleanup_threshold must be <= 0.99, but was \" + conf.memtable_cleanup_threshold, false);\n        if (conf.memtable_cleanup_threshold < 0.1f)\n            logger.warn(\"memtable_cleanup_threshold is set very low [{}], which may cause performance degradation\", conf.memtable_cleanup_threshold);\n\n        if (conf.concurrent_compactors == null)\n            conf.concurrent_compactors = Math.min(8, Math.max(2, Math.min(FBUtilities.getAvailableProcessors(), conf.data_file_directories.length)));\n\n        if (conf.concurrent_compactors <= 0)\n            throw new ConfigurationException(\"concurrent_compactors should be strictly greater than 0, but was \" + conf.concurrent_compactors, false);\n\n        applyConcurrentValidations(conf);\n        applyRepairCommandPoolSize(conf);\n        applyThresholdsValidations(conf);\n\n        if (conf.concurrent_materialized_view_builders <= 0)\n            throw new ConfigurationException(\"concurrent_materialized_view_builders should be strictly greater than 0, but was \" + conf.concurrent_materialized_view_builders, false);\n\n        if (conf.num_tokens != null && conf.num_tokens > MAX_NUM_TOKENS)\n            throw new ConfigurationException(String.format(\"A maximum number of %d tokens per node is supported\", MAX_NUM_TOKENS), false);\n\n        try\n        {\n            // if prepared_statements_cache_size option was set to \"auto\" then size of the cache should be \"max(1/256 of Heap (in MiB), 10MiB)\"\n            preparedStatementsCacheSizeInMiB = (conf.prepared_statements_cache_size == null)\n                                               ? Math.max(10, (int) (Runtime.getRuntime().maxMemory() / 1024 / 1024 / 256))\n                                               : conf.prepared_statements_cache_size.toMebibytes();\n\n            if (preparedStatementsCacheSizeInMiB == 0)\n                throw new NumberFormatException(); // to escape duplicating error message\n\n            // we need this assignment for the Settings virtual table - CASSANDRA-17734\n            conf.prepared_statements_cache_size = new DataStorageSpec.LongMebibytesBound(preparedStatementsCacheSizeInMiB);\n        }\n        catch (NumberFormatException e)","sourceCodeStart":955,"sourceCodeEnd":991,"githubUrl":"https://github.com/apache/cassandra/blob/88fd0f6a0eaed8943f05ac9e8f947882b8ddc8f1/src/java/org/apache/cassandra/config/DatabaseDescriptor.java#L955-L991","documentation":"concurrent_materialized_view_builders sets how many materialized view build tasks may run concurrently; applySimpleConfig requires it to be strictly positive at startup and throws ConfigurationException otherwise.","triggerScenarios":"Node startup with concurrent_materialized_view_builders: 0 or a negative value in cassandra.yaml.","commonSituations":"Operator attempting to stop view building by zeroing the setting; template default rendering 0; accidental comment splitting the value from a digit.","solutions":["Set concurrent_materialized_view_builders to a positive integer (default 1) in cassandra.yaml","Remove the key to accept the default","To pause view building use nodetool viewbuildstatus / disable materialized views rather than an invalid 0","Restart the node"],"exampleFix":"// before (cassandra.yaml)\nconcurrent_materialized_view_builders: 0\n// after\nconcurrent_materialized_view_builders: 1","handlingStrategy":"validation","validationCode":"if (conf.concurrentMaterializedViewBuilders != null && conf.concurrentMaterializedViewBuilders <= 0)\n    throw new IllegalArgumentException(\"concurrent_materialized_view_builders must be > 0\");","typeGuard":null,"tryCatchPattern":"try { DatabaseDescriptor.daemonInitialization(); }\ncatch (ConfigurationException e) { LOG.fatal(e.getMessage()); System.exit(1); }","preventionTips":["Keep the default (1) unless deliberately tuned","Use proper mechanisms (dropping views) instead of 0 to stop view building","Lint templated cassandra.yaml output for empty/zero numerics"],"tags":["cassandra","configuration","materialized-views"],"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"}