{"record":{"id":"2e8044fd36b2b2ee","repo":"t8y2/dbx","slug":"unsupported-iotdb-connection-scheme-s","errorCode":null,"errorMessage":"unsupported IoTDB connection scheme: %s","messagePattern":"unsupported IoTDB connection scheme: (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"agents/drivers/iotdb/driver.go","lineNumber":120,"sourceCode":"\tif config.Port <= 0 {\n\t\tconfig.Port = defaultIoTDBPort\n\t}\n\tif config.Username == \"\" {\n\t\tconfig.Username = \"root\"\n\t}\n\tif config.Password == \"\" {\n\t\tconfig.Password = \"root\"\n\t}\n\n\tquery := url.Values{}\n\tif raw := strings.TrimSpace(params.ConnectionString); raw != \"\" {\n\t\tnormalized := strings.TrimPrefix(raw, \"jdbc:\")\n\t\tparsed, err := url.Parse(normalized)\n\t\tif err != nil {\n\t\t\treturn connectionConfig{}, fmt.Errorf(\"parse IoTDB connection string: %w\", err)\n\t\t}\n\t\tif parsed.Scheme != \"\" && !strings.EqualFold(parsed.Scheme, \"iotdb\") {\n\t\t\treturn connectionConfig{}, fmt.Errorf(\"unsupported IoTDB connection scheme: %s\", parsed.Scheme)\n\t\t}\n\t\tif parsed.Hostname() != \"\" {\n\t\t\tconfig.Host = parsed.Hostname()\n\t\t}\n\t\tif parsed.Port() != \"\" {\n\t\t\tport, err := strconv.Atoi(parsed.Port())\n\t\t\tif err != nil || port <= 0 {\n\t\t\t\treturn connectionConfig{}, fmt.Errorf(\"invalid IoTDB port: %s\", parsed.Port())\n\t\t\t}\n\t\t\tconfig.Port = port\n\t\t}\n\t\tif parsed.User != nil {\n\t\t\tif username := parsed.User.Username(); username != \"\" {\n\t\t\t\tconfig.Username = username\n\t\t\t}\n\t\t\tif password, ok := parsed.User.Password(); ok {\n\t\t\t\tconfig.Password = password\n\t\t\t}","sourceCodeStart":102,"sourceCodeEnd":138,"githubUrl":"https://github.com/t8y2/dbx/blob/c0390bff16418b651f4728520d99adf8ce48829a/agents/drivers/iotdb/driver.go#L102-L138","documentation":"After parsing, parseConnectionConfig rejects any non-empty scheme that isn't 'iotdb' (case-insensitive), returning 'unsupported IoTDB connection scheme: %s'. jdbc: prefixes are stripped first, but other schemes like mysql: or postgres: are errors.","triggerScenarios":"Passing a connection string with a scheme other than iotdb/empty, e.g. 'jdbc:mysql://host:3306' or 'http://host:6667', into the IoTDB driver config.","commonSituations":"Copy-pasting a JDBC URL from another database project; leaving a generic http:// prefix; IDE autocompleting a wrong scheme template.","solutions":["Use an 'iotdb://' scheme (or no scheme) in the connection string","Strip a foreign 'jdbc:<scheme>:' prefix yourself if migrating from another driver","Double-check you are instantiating the IoTDB driver, not another database's"],"exampleFix":"// before\nconnStr = \"jdbc:mysql://host:3306/db\"\n// after\nconnStr = \"jdbc:iotdb://host:6667\"","handlingStrategy":"validation","validationCode":"func ensureIoTDBScheme(raw string) error {\n  s := strings.TrimPrefix(strings.TrimSpace(raw), \"jdbc:\")\n  if u, err := url.Parse(s); err == nil && u.Scheme != \"\" && !strings.EqualFold(u.Scheme, \"iotdb\") {\n    return fmt.Errorf(\"scheme %q is not iotdb\", u.Scheme)\n  }\n  return nil\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Standardize on iotdb:// scheme in all config templates","Never paste JDBC URLs from other databases without fixing the scheme"],"tags":["iotdb","config","connection-string","validation"],"backgroundTag":"unsupported-connection-scheme","analyzedSha":"c0390bff16418b651f4728520d99adf8ce48829a","analyzedAt":"2026-09-05T23:05:10.900Z","contentChangedAt":"2026-09-05T23:05:10.900Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}