{"record":{"id":"4d3982ed638eb21a","repo":"apache/seatunnel","slug":"unsupported-error-handler-queue-overflow-policy","errorCode":null,"errorMessage":"Unsupported error handler queue_overflow_policy: %s","messagePattern":"Unsupported error handler queue_overflow_policy: (.+?)","errorType":"validation","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"seatunnel-engine/seatunnel-engine-server/src/main/java/org/apache/seatunnel/engine/server/task/error/QueueOverflowPolicy.java","lineNumber":37,"sourceCode":"\npublic enum QueueOverflowPolicy {\n    FAIL,\n    DROP,\n    BLOCK;\n\n    public static QueueOverflowPolicy fromString(String value) {\n        if (value == null) {\n            return FAIL;\n        }\n        switch (value.trim().toUpperCase()) {\n            case \"DROP\":\n                return DROP;\n            case \"BLOCK\":\n                return BLOCK;\n            case \"FAIL\":\n                return FAIL;\n            default:\n                throw new IllegalArgumentException(\n                        \"Unsupported error handler queue_overflow_policy: \" + value);\n        }\n    }\n}\n","sourceCodeStart":19,"sourceCodeEnd":42,"githubUrl":"https://github.com/apache/seatunnel/blob/cf67b549a7a6c35fa0beb12d83c62892427ea919/seatunnel-engine/seatunnel-engine-server/src/main/java/org/apache/seatunnel/engine/server/task/error/QueueOverflowPolicy.java#L19-L42","documentation":"QueueOverflowPolicy.fromString converts the queue_overflow_policy option into its enum, accepting only DROP, BLOCK, and FAIL. Any other value throws IllegalArgumentException 'Unsupported error handler queue_overflow_policy'. This controls what happens when the error-handling queue is full.","triggerScenarios":"Configuring 'queue_overflow_policy = discard', 'SKIP', or any value other than DROP, BLOCK, FAIL in the error-handler block.","commonSituations":"Users borrow policy names from other systems (e.g. 'backpressure', 'latest', 'oldest' from Kafka consumer offset reset) or misspell the constant.","solutions":["Use one of the supported values exactly: DROP, BLOCK, or FAIL.","Match uppercase spelling of the enum constant.","Choose FAIL if you want the task to fail on queue overflow rather than drop or block."],"exampleFix":"// before\nerror-handler.queue_overflow_policy = \"SKIP\"\n// after\nerror-handler.queue_overflow_policy = \"BLOCK\"","handlingStrategy":"validation","validationCode":"Set<String> allowed = Set.of(\"DROP\", \"BLOCK\", \"FAIL\");\nString policy = cfg.get(\"queue_overflow_policy\");\nif (policy != null && !allowed.contains(policy)) {\n    throw new IllegalArgumentException(\"Unsupported queue_overflow_policy: \" + policy);\n}","typeGuard":"boolean isValidQueueOverflowPolicy(String s) {\n    return \"DROP\".equals(s) || \"BLOCK\".equals(s) || \"FAIL\".equals(s);\n}","tryCatchPattern":"try {\n    QueueOverflowPolicy p = QueueOverflowPolicy.fromString(value);\n} catch (IllegalArgumentException e) {\n    log.error(\"Bad policy '{}'; use DROP, BLOCK, or FAIL\", value);\n}","preventionTips":["Use exact uppercase enum names DROP/BLOCK/FAIL","Don't reuse policy vocabularies from other systems","Validate enum options at config load time"],"tags":["config","enum","error-handler"],"backgroundTag":"invalid-enum-value","analyzedSha":"cf67b549a7a6c35fa0beb12d83c62892427ea919","analyzedAt":"2026-09-10T21:44:55.265Z","contentChangedAt":"2026-09-10T21:44:55.265Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}