{"record":{"id":"84897ea111f6a2c5","repo":"risingwavelabs/risingwave","slug":"config-error-0","errorCode":null,"errorMessage":"config error: {0}","messagePattern":"config error: (.+?)","errorType":"exception","errorClass":"SinkError","httpStatus":null,"severity":"error","filePath":"src/connector/src/sink/mod.rs","lineNumber":1114,"sourceCode":"        anyhow::Error,\n    ),\n    #[error(\"Remote sink error: {0}\")]\n    Remote(\n        #[source]\n        #[backtrace]\n        anyhow::Error,\n    ),\n    #[error(\"Encode error: {0}\")]\n    Encode(String),\n    #[error(\"Avro error: {0}\")]\n    Avro(#[from] apache_avro::Error),\n    #[error(\"Iceberg error: {0}\")]\n    Iceberg(\n        #[source]\n        #[backtrace]\n        anyhow::Error,\n    ),\n    #[error(\"config error: {0}\")]\n    Config(\n        #[source]\n        #[backtrace]\n        anyhow::Error,\n    ),\n    #[error(\"coordinator error: {0}\")]\n    Coordinator(\n        #[source]\n        #[backtrace]\n        anyhow::Error,\n    ),\n    #[error(\"ClickHouse error: {0}\")]\n    ClickHouse(String),\n    #[error(\"Redis error: {0}\")]\n    Redis(String),\n    #[error(\"Http error: {0}\")]\n    Http(\n        #[source]","sourceCodeStart":1096,"sourceCodeEnd":1132,"githubUrl":"https://github.com/risingwavelabs/risingwave/blob/6469eb736d691e8e9b8a419a57edd6429ca77417/src/connector/src/sink/mod.rs#L1096-L1132","documentation":"`SinkError::Config` wraps an `anyhow::Error` and is thrown when a sink's user-supplied configuration fails validation or cannot be parsed into the connector's config struct. Displayed as \"config error: {0}\" with the original cause and backtrace retained. It separates configuration problems from runtime data-path failures.","triggerScenarios":"Creating a sink: parsing `WITH` options into the connector-specific config struct (serde deserialization), validating required fields, or any explicit config check that returns `anyhow!(...)` converted into this variant.","commonSituations":"Misspelled or unknown keys in the `WITH` clause; missing required fields (e.g. no `endpoint`, `bucket`, or `connection.name`); wrong value types (string where number/bool expected); referencing a private-link/connection that does not exist; env-dependent defaults resolving to invalid values.","solutions":["Read the wrapped message — serde errors name the exact unknown/missing/mistyped field.","Cross-check every `WITH` option against the connector's documented properties and fix spelling/types.","Add any required fields (endpoint, bucket, region, auth credentials, connection name) that the message flags as missing.","If using a `CREATE CONNECTION`/private-link reference, confirm the referenced connection exists and is accessible."],"exampleFix":"-- before\nCREATE SINK s FROM mv WITH (\n  connector = 'kafka',\n  properties = 'broker:9092'\n);\n-- after\nCREATE SINK s FROM mv WITH (\n  connector = 'kafka',\n  properties.broker = 'broker:9092',\n  topic = 'my-topic'\n);","handlingStrategy":"validation","validationCode":"fn validate_sink_options(opts: &serde_json::Value, required: &[&str]) -> Result<(), String> {\n    for key in required {\n        if opts.get(key).map(|v| !v.is_null()).unwrap_or(false) {\n            continue;\n        }\n        return Err(format!(\"missing required sink option '{key}'\"));\n    }\n    Ok(())\n}","typeGuard":"fn as_config_error(err: &SinkError) -> Option<&anyhow::Error> {\n    if let SinkError::Config(e) = err { Some(e) } else { None }\n}","tryCatchPattern":"match SinkWriter::new(sink, opts).await {\n    Err(SinkError::Config(e)) => {\n        log::error!(\"bad sink config: {e:#}\");\n        // surface a user-facing 'fix your WITH options' message; do not retry\n    }\n    Err(e) => return Err(e.into()),\n    Ok(w) => { /* proceed */ }\n}","preventionTips":["Validate WITH options against the connector's documented property list before CREATE SINK.","Never retry on Config errors — they are deterministic and will repeat.","Use SQL linting/schema of WITH options in tooling to catch typos early.","Prefer CREATE CONNECTION for shared credentials to reduce per-sink config mistakes."],"tags":["config","sink","validation","risingwave"],"backgroundTag":"invalid-config-value","analyzedSha":"6469eb736d691e8e9b8a419a57edd6429ca77417","analyzedAt":"2026-09-11T21:06:21.487Z","contentChangedAt":"2026-09-11T21:06:21.487Z","schemaVersion":2},"datasetVersion":"2026-09-14T16:17:12.679Z"}