{"record":{"id":"966e8b5856589d64","repo":"linera-io/linera-protocol","slug":"the-only-allowed-protocol-is-tcp","errorCode":null,"errorMessage":"The only allowed protocol is tcp","messagePattern":"The only allowed protocol is tcp","errorType":"validation","errorClass":"anyhow","httpStatus":null,"severity":"error","filePath":"linera-storage-runtime/src/storage_config.rs","lineNumber":247,"sourceCode":"                    \"For DualRocksDbScyllaDb, the formatting has to be dualrocksdbscylladb:directory:mode:tcp:hostname:port:namespace\"\n                );\n            }\n            let path = Path::new(parts[0]);\n            let path = path.to_path_buf();\n            let path_with_guard = PathWithGuard::new(path);\n            let spawn_mode_name = parts\n                .get(1)\n                .copied()\n                .expect(\"validated by the parts length check above\");\n            let spawn_mode = match spawn_mode_name {\n                \"spawn_blocking\" => Ok(RocksDbSpawnMode::SpawnBlocking),\n                \"block_in_place\" => Ok(RocksDbSpawnMode::BlockInPlace),\n                \"runtime\" => Ok(RocksDbSpawnMode::get_spawn_mode_from_runtime()),\n                _ => Err(anyhow!(\"Failed to parse {spawn_mode_name} as a spawn_mode\",)),\n            }?;\n            let protocol = parts[2];\n            if protocol != \"tcp\" {\n                bail!(\"The only allowed protocol is tcp\");\n            }\n            let address = parts[3];\n            let port_str = parts[4];\n            let port = NonZeroU16::from_str(port_str)\n                .map_err(|_| anyhow!(\"Failed to find parse port {port_str} for {s}\"))?;\n            let uri = format!(\"{address}:{port}\");\n            let inner_storage_config = InnerStorageConfig::DualRocksDbScyllaDb {\n                path_with_guard,\n                spawn_mode,\n                uri,\n            };\n            let namespace = if parts.len() == 5 {\n                DEFAULT_NAMESPACE.to_string()\n            } else {\n                parts[5].to_string()\n            };\n            return Ok(StorageConfig {\n                inner_storage_config,","sourceCodeStart":229,"sourceCodeEnd":265,"githubUrl":"https://github.com/linera-io/linera-protocol/blob/6c226ddcb332ef55118dc8d0aafbd093d5420899/linera-storage-runtime/src/storage_config.rs#L229-L265","documentation":"Raised while parsing a `dualrocksdbscylladb:` storage configuration in `StorageConfig::from_str` (linera-storage-runtime). The third segment (after directory and spawn mode) must be the literal `tcp` — the dual backend only supports plain TCP connections to ScyllaDB; any other scheme is rejected.","triggerScenarios":"Passing `dualrocksdbscylladb:/db:block_in_place:http:host:9042:ns` or any transport segment other than `tcp`.","commonSituations":"Substituting the ScyllaDB URI scheme from other tooling (http/cql/tls) into the Linera config string.","solutions":["Set the transport segment to `tcp`: `dualrocksdbscylladb:<dir>:<mode>:tcp:<host>:<port>[:<ns>]`","Confirm ScyllaDB's native CQL transport (TCP) address is what you mean — not the HTTP JMX/management port"],"exampleFix":"# before\n--storage dualrocksdbscylladb:/db:block_in_place:http:host:9042:table_ns\n\n# after\n--storage dualrocksdbscylladb:/db:block_in_place:tcp:host:9042:table_ns","handlingStrategy":"validation","validationCode":"// Rust: check the dual-config transport segment before FromStr\nif let Some(rest) = storage_str.strip_prefix(\"dualrocksdbscylladb:\") {\n    let protocol = rest.split(':').nth(2);\n    anyhow::ensure!(\n        protocol == Some(\"tcp\"),\n        \"dualrocksdbscylladb transport must be tcp, got {protocol:?}\"\n    );\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Only the ScyllaDB native TCP (CQL) transport is supported in dual configs","Do not substitute the scheme from Scylla management/HTTP tooling"],"tags":["config","parsing","scylladb","protocol"],"backgroundTag":"unsupported-protocol-scheme","analyzedSha":"6c226ddcb332ef55118dc8d0aafbd093d5420899","analyzedAt":"2026-08-22T22:49:09.787Z","schemaVersion":2},"datasetVersion":"2026-08-23T01:17:44.959Z"}