{"record":{"id":"feecca0b7cef2cba","repo":"databendlabs/databend","slug":"protocol-protocol-is-not-supported-yet","errorCode":null,"errorMessage":"protocol {protocol} is not supported yet.","messagePattern":"protocol (.+?) is not supported yet\\.","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/query/sql/src/planner/binder/location.rs","lineNumber":532,"sourceCode":"}\n\nfn parse_uri_location_parts(l: &UriLocation) -> Result<ParsedUriLocation> {\n    // Path ends with `/` means it's a directory, otherwise it's a file.\n    // If the path is a directory, we will use this path as root.\n    // If the path is a file, we will use `/` as root (which is the default value)\n    let (root, path) = if l.path.ends_with('/') {\n        (l.path.clone(), \"/\".to_string())\n    } else {\n        (\"/\".to_string(), l.path.clone())\n    };\n    let root = normalize_root(&root);\n    let path = normalize_path(&path);\n\n    let protocol = l.protocol.parse::<Scheme>()?;\n    if let Scheme::Custom(_) = protocol {\n        return Err(Error::new(\n            ErrorKind::InvalidInput,\n            anyhow!(\"protocol {protocol} is not supported yet.\"),\n        ));\n    }\n\n    Ok(ParsedUriLocation {\n        root,\n        path,\n        protocol,\n    })\n}\n\npub async fn parse_uri_location(l: &mut UriLocation) -> Result<(StorageParams, String)> {\n    let parts = parse_uri_location_parts(l)?;\n\n    if l.connection.get(\"connection_name\").is_some() {\n        return Err(Error::new(\n            ErrorKind::InvalidInput,\n            anyhow!(\"can not use connection_name when create connection\"),\n        ));","sourceCodeStart":514,"sourceCodeEnd":550,"githubUrl":"https://github.com/databendlabs/databend/blob/288d84d76e20a2f8f7173bda9691eb6ece301aa9/src/query/sql/src/planner/binder/location.rs#L514-L550","documentation":"The URI protocol is parsed into OpenDAL's Scheme enum, and Scheme::Custom (any scheme OpenDAL does not recognize as a built-in service) is rejected when resolving a UriLocation's parts. This error means the URL scheme in your stage/connection is not a supported storage protocol.","triggerScenarios":"CREATE STAGE / CREATE CONNECTION with an unknown or unsupported scheme, e.g. URL='foo://bucket/path', or a typo like 's33://bucket/'.","commonSituations":"Typos in the scheme; trying protocols Databend does not support (e.g. custom/internal schemes); copy-pasting a URI from another system.","solutions":["Use a supported scheme: s3, gcs, oss, cos, obs, azblob, fs, http(s), ipfs, webhdfs, huggingface, etc.","Fix typos in the URL scheme","Check Databend docs for the list of supported storage protocols for your version"],"exampleFix":"-- before\nCREATE STAGE s URL='foo://bucket/path/';\n-- after\nCREATE STAGE s URL='s3://bucket/path/';","handlingStrategy":"validation","validationCode":"let scheme = url::Url::parse(storage_url)?.scheme();\nconst SUPPORTED: &[&str] = &[\"s3\",\"gcs\",\"oss\",\"cos\",\"obs\",\"azblob\",\"fs\",\"http\",\"https\",\"ipfs\",\"webhdfs\",\"huggingface\"];\nif !SUPPORTED.contains(&scheme) {\n    return Err(format!(\"unsupported storage protocol: {scheme}\"));\n}","typeGuard":null,"tryCatchPattern":"match err.kind() { ErrorKind::InvalidInput if msg.contains(\"is not supported yet\") => /* fix scheme and retry */, _ => return Err(err) }","preventionTips":["Whitelist supported schemes in URI-building code","Check Databend docs for supported protocols per version","Avoid custom/internal schemes in stage/connection URLs"],"tags":["storage","url","scheme","unsupported"],"backgroundTag":"invalid-enum-value","analyzedSha":"288d84d76e20a2f8f7173bda9691eb6ece301aa9","analyzedAt":"2026-09-11T11:29:36.208Z","contentChangedAt":"2026-09-11T11:29:36.208Z","schemaVersion":2},"datasetVersion":"2026-09-16T04:17:20.429Z"}