{"record":{"id":"ce0300a37b3f71f7","repo":"apache/cassandra","slug":"internode-max-message-size-must-no-exceed-internod","errorCode":null,"errorMessage":"internode_max_message_size must no exceed internode_application_receive_queue_reserve_endpoint_capacity","messagePattern":"internode_max_message_size must no exceed internode_application_receive_queue_reserve_endpoint_capacity","errorType":"validation","errorClass":"ConfigurationException","httpStatus":null,"severity":"error","filePath":"src/java/org/apache/cassandra/config/DatabaseDescriptor.java","lineNumber":1207,"sourceCode":"            throw new ConfigurationException(\"compressed_read_ahead_buffer_size must be at least 256KiB (set to 0 to disable), but was \" + conf.compressed_read_ahead_buffer_size, false);\n\n        if (conf.server_encryption_options != null)\n        {\n            conf.server_encryption_options.applyConfig();\n\n            if (conf.server_encryption_options.legacy_ssl_storage_port_enabled &&\n                conf.server_encryption_options.tlsEncryptionPolicy() == EncryptionOptions.TlsEncryptionPolicy.UNENCRYPTED)\n            {\n                throw new ConfigurationException(\"legacy_ssl_storage_port_enabled is true (enabled) with internode encryption disabled (none). Enable encryption or disable the legacy ssl storage port.\");\n            }\n        }\n\n        if (conf.internode_max_message_size != null)\n        {\n            long maxMessageSize = conf.internode_max_message_size.toBytes();\n\n            if (maxMessageSize > conf.internode_application_receive_queue_reserve_endpoint_capacity.toBytes())\n                throw new ConfigurationException(\"internode_max_message_size must no exceed internode_application_receive_queue_reserve_endpoint_capacity\", false);\n\n            if (maxMessageSize > conf.internode_application_receive_queue_reserve_global_capacity.toBytes())\n                throw new ConfigurationException(\"internode_max_message_size must no exceed internode_application_receive_queue_reserve_global_capacity\", false);\n\n            if (maxMessageSize > conf.internode_application_send_queue_reserve_endpoint_capacity.toBytes())\n                throw new ConfigurationException(\"internode_max_message_size must no exceed internode_application_send_queue_reserve_endpoint_capacity\", false);\n\n            if (maxMessageSize > conf.internode_application_send_queue_reserve_global_capacity.toBytes())\n                throw new ConfigurationException(\"internode_max_message_size must no exceed internode_application_send_queue_reserve_global_capacity\", false);\n        }\n        else\n        {\n            long maxMessageSizeInBytes =\n            Math.min(conf.internode_application_receive_queue_reserve_endpoint_capacity.toBytes(),\n                     conf.internode_application_send_queue_reserve_endpoint_capacity.toBytes());\n\n            conf.internode_max_message_size = new DataStorageSpec.IntBytesBound(maxMessageSizeInBytes);\n        }","sourceCodeStart":1189,"sourceCodeEnd":1225,"githubUrl":"https://github.com/apache/cassandra/blob/88fd0f6a0eaed8943f05ac9e8f947882b8ddc8f1/src/java/org/apache/cassandra/config/DatabaseDescriptor.java#L1189-L1225","documentation":"internode_max_message_size caps the size of messages sent between nodes; it cannot exceed the per-endpoint reserved capacity of the internode application receive queue, or a maximum-size message could never fit in the reserved receive buffer. DatabaseDescriptor throws this ConfigurationException (note the typo 'no exceed' in the message) when maxMessageSize > internode_application_receive_queue_reserve_endpoint_capacity.","triggerScenarios":"cassandra.yaml sets internode_max_message_size_in_bytes to a value greater than internode_application_receive_queue_reserve_endpoint_capacity_in_bytes while internode_max_message_size is non-null, during applySimpleConfig.","commonSituations":"Raising internode message size for large mutations/batches without scaling the receive queue reserves; lowering queue reserve memory settings without re-checking message size; defaults drift across versions.","solutions":["Lower internode_max_message_size_in_bytes to <= the receive-queue per-endpoint reserve capacity","Or raise internode_application_receive_queue_reserve_endpoint_capacity_in_bytes to at least internode_max_message_size","Remove overrides so defaults (which are mutually consistent) apply"],"exampleFix":"# before (cassandra.yaml)\ninternode_max_message_size_in_bytes: 104857600\ninternode_application_receive_queue_reserve_endpoint_capacity_in_bytes: 8388608\n# after\ninternode_max_message_size_in_bytes: 104857600\ninternode_application_receive_queue_reserve_endpoint_capacity_in_bytes: 134217728","handlingStrategy":"validation","validationCode":"if (conf.internode_max_message_size != null &&\n    conf.internode_max_message_size.toBytes() > conf.internode_application_receive_queue_reserve_endpoint_capacity.toBytes())\n    throw new IllegalArgumentException(\"internode_max_message_size must not exceed receive-queue endpoint reserve\");","typeGuard":null,"tryCatchPattern":"try { DatabaseDescriptor.applyConfig(conf); } catch (ConfigurationException e) { if (e.getMessage().contains(\"receive_queue_reserve_endpoint_capacity\")) { /* rebalance limits */ } }","preventionTips":["Change internode_max_message_size and all four queue-reserve settings together","Keep each queue reserve >= internode_max_message_size","Test config changes with a config-load dry run before rolling to the cluster"],"tags":["cassandra","configuration","internode"],"backgroundTag":"conflicting-config-options","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"}