{"record":{"id":"94bd8fa9bc3a4ce6","repo":"risingwavelabs/risingwave","slug":"http-sink-url-option-cannot-coexist-with-url-colum","errorCode":null,"errorMessage":"HTTP sink url option cannot coexist with url column","messagePattern":"HTTP sink url option cannot coexist with url column","errorType":"validation","errorClass":"SinkError::Config","httpStatus":null,"severity":"error","filePath":"src/connector/src/sink/http.rs","lineNumber":162,"sourceCode":"                    )));\n                }\n            }\n        }\n\n        let payload_index = fields\n            .iter()\n            .position(|field| field.name == HTTP_SINK_PAYLOAD_COLUMN)\n            .ok_or_else(|| {\n                SinkError::Config(anyhow!(\n                    \"HTTP sink with multiple columns requires a payload column\"\n                ))\n            })?;\n        let url_index = fields\n            .iter()\n            .position(|field| field.name == HTTP_SINK_URL_COLUMN);\n        let url = match (url, url_index) {\n            (Some(_), Some(_)) => {\n                return Err(SinkError::Config(anyhow!(\n                    \"HTTP sink url option cannot coexist with url column\"\n                )));\n            }\n            (Some(url), None) => {\n                let url = url\n                    .parse()\n                    .context(\"invalid URL\")\n                    .map_err(SinkError::Config)?;\n                HttpUrl::Static(url)\n            }\n            (None, Some(url_index)) => {\n                if fields[url_index].data_type != DataType::Varchar {\n                    return Err(SinkError::Config(anyhow!(\n                        \"HTTP sink url column must be varchar, got {:?}\",\n                        fields[url_index].data_type\n                    )));\n                }\n                HttpUrl::Dynamic { url_index }","sourceCodeStart":144,"sourceCodeEnd":180,"githubUrl":"https://github.com/risingwavelabs/risingwave/blob/6469eb736d691e8e9b8a419a57edd6429ca77417/src/connector/src/sink/http.rs#L144-L180","documentation":"The HTTP sink in RisingWave can take its target URL either from a static `url` option in the WITH clause or from a dedicated `url` column in the schema, but not both. During sink validation (`validate_http_sink`), if both a `url` option is set and a column named `url` (HTTP_SINK_URL_COLUMN) exists in the schema, the sink is rejected because the source of the URL would be ambiguous.","triggerScenarios":"Creating an HTTP sink with `WITH (connector='http', url='https://...')` while the sink's schema/table also contains a column named `url` — the `try_from` conversion calls `validate_http_sink`, which matches the `(Some(_), Some(_))` arm.","commonSituations":"Users rename an existing table column to `url` (e.g. to store per-row endpoints) and forget the static `url` option is still present in the sink's WITH clause; or copy a sink definition and add a dynamic url column without removing the static url option.","solutions":["Remove the `url` option from the sink's WITH clause if you intend per-row URLs from the `url` column","Rename the schema column (and use it as payload/other column) if you intend a single static URL from the `url` option","Recreate the sink with only one of the two URL sources"],"exampleFix":"// before\nCREATE SINK s FROM t WITH (connector='http', url='https://api.example.com/ingest'); -- t has column `url`\n// after\nCREATE SINK s FROM t WITH (connector='http'); -- use dynamic per-row url column\n-- or keep static url and rename t.url -> endpoint_url","handlingStrategy":"validation","validationCode":"let has_url_opt = with_options.contains_key(\"url\");\nlet has_url_col = fields.iter().any(|f| f.name == \"url\");\nif has_url_opt && has_url_col {\n    return Err(\"HTTP sink: remove either the url option or the url column\".into());\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Decide up front whether URLs are static (option) or per-row (column) and use only one","Search your schema for a column named `url` before adding a static url option"],"tags":["sink","http","config-validation","risingwave"],"backgroundTag":"mutually-exclusive-options","analyzedSha":"6469eb736d691e8e9b8a419a57edd6429ca77417","analyzedAt":"2026-09-11T21:06:21.487Z","contentChangedAt":"2026-09-11T21:06:21.487Z","schemaVersion":2},"datasetVersion":"2026-09-14T11:17:12.474Z"}