{"record":{"id":"0be3bf7461524e08","repo":"apache/seatunnel","slug":"config-validation-failed-0be3bf","errorCode":"CONFIG_VALIDATION_FAILED","errorMessage":"table_options contains a blank property key for Paimon sink.","messagePattern":"table_options contains a blank property key for Paimon sink\\.","errorType":"error_code","errorClass":"SeaTunnelRuntimeException","httpStatus":null,"severity":"error","filePath":"seatunnel-connectors-v2/connector-paimon/src/main/java/org/apache/seatunnel/connectors/seatunnel/paimon/sink/PaimonTableOptionsValidator.java","lineNumber":46,"sourceCode":"import java.util.Map;\n\n/**\n * Validates Paimon sink {@code table_options} before job submission.\n *\n * <p>Paimon accepts open CoreOptions keys; this validator only rejects blank keys or null values.\n * Unsupported option keys fail later when Paimon creates the table.\n */\npublic final class PaimonTableOptionsValidator {\n\n    private PaimonTableOptionsValidator() {}\n\n    public static void validate(ReadonlyConfig config, Map<String, String> tableOptions) {\n        if (tableOptions == null || tableOptions.isEmpty()) {\n            return;\n        }\n        for (Map.Entry<String, String> entry : tableOptions.entrySet()) {\n            if (StringUtils.isBlank(entry.getKey())) {\n                throw new SeaTunnelRuntimeException(\n                        SeaTunnelAPIErrorCode.CONFIG_VALIDATION_FAILED,\n                        \"table_options contains a blank property key for Paimon sink.\");\n            }\n            if (entry.getValue() == null) {\n                throw new SeaTunnelRuntimeException(\n                        SeaTunnelAPIErrorCode.CONFIG_VALIDATION_FAILED,\n                        String.format(\n                                \"table_options property '%s' has null value for Paimon sink.\",\n                                entry.getKey()));\n            }\n        }\n    }\n\n    public static void validate(ReadonlyConfig config) {\n        validate(\n                config,\n                config.getOptional(SinkConnectorCommonOptions.TABLE_OPTIONS)\n                        .orElse(Collections.emptyMap()));","sourceCodeStart":28,"sourceCodeEnd":64,"githubUrl":"https://github.com/apache/seatunnel/blob/cf67b549a7a6c35fa0beb12d83c62892427ea919/seatunnel-connectors-v2/connector-paimon/src/main/java/org/apache/seatunnel/connectors/seatunnel/paimon/sink/PaimonTableOptionsValidator.java#L28-L64","documentation":"PaimonTableOptionsValidator.validate checks the sink's table_options map for malformed entries. A blank (null/whitespace) property key causes a SeaTunnelRuntimeException with SeaTunnelAPIErrorCode.CONFIG_VALIDATION_FAILED and this message; a null value is likewise rejected.","triggerScenarios":"Calling validate(config, tableOptions) with a non-empty table_options map containing an entry whose key is blank — typically produced by malformed HOCON/YAML such as `\"\" : \"value\"` or a key consisting only of spaces.","commonSituations":"Hand-edited config with an empty key line; template/config generator emitting an empty key when a variable is unset; YAML indentation mistakes turning a key into an empty string.","solutions":["Remove or fix the blank-key entry in table_options in the job config","Check for template variables that expand to empty strings and become keys","Lint the HOCON/YAML config so keys are never empty"],"exampleFix":"// before\ntable_options {\n  \"\" = \"some-value\"\n}\n// after\ntable_options {\n  \"bucket\" = \"2\"\n}\n","handlingStrategy":"validation","validationCode":"if (tableOptions != null) { for (String k : tableOptions.keySet()) { if (k == null || k.isBlank()) { throw new IllegalArgumentException(\"table_options contains a blank key\"); } } }","typeGuard":null,"tryCatchPattern":"try { PaimonTableOptionsValidator.validate(config, tableOptions); } catch (SeaTunnelRuntimeException e) { if (SeaTunnelAPIErrorCode.CONFIG_VALIDATION_FAILED.equals(e.getErrorCode())) { /* sanitize table_options and retry */ } else { throw e; } }","preventionTips":["Lint HOCON/YAML so keys are never empty strings","Expand template variables before validation","Fail fast on empty keys during config parsing"],"tags":["paimon","config","validation"],"backgroundTag":"schema-validation-failed","analyzedSha":"cf67b549a7a6c35fa0beb12d83c62892427ea919","analyzedAt":"2026-09-10T21:44:55.265Z","contentChangedAt":"2026-09-10T21:44:55.265Z","schemaVersion":2},"datasetVersion":"2026-09-14T11:17:12.474Z"}