{"record":{"id":"9b8ada88978711de","repo":"apache/seatunnel","slug":"optionpath-must-be-min-when-set-9b8ada","errorCode":null,"errorMessage":"${optionPath} must be >= ${min} when set.","messagePattern":"(.+?) must be >= (.+?) when set\\.","errorType":"validation","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"seatunnel-edge-agent/seatunnel-edge-agent-starter/src/main/java/org/apache/seatunnel/edge/agent/starter/config/QueueConfig.java","lineNumber":73,"sourceCode":"        requireAtLeast(this.resurrectBatchSize, 1, \"queue.resurrect-batch-size\");\n\n        this.resurrectIntervalMs = config.get(EdgeAgentRuntimeOptions.QUEUE_RESURRECT_INTERVAL_MS);\n        requireAtLeast(this.resurrectIntervalMs, 1L, \"queue.resurrect-interval-ms\");\n\n        this.cleanupBatchSize = config.get(EdgeAgentRuntimeOptions.QUEUE_CLEANUP_BATCH_SIZE);\n        requireAtLeast(this.cleanupBatchSize, 1, \"queue.cleanup-batch-size\");\n\n        this.ackedRetentionMs = config.get(EdgeAgentRuntimeOptions.QUEUE_ACKED_RETENTION_MS);\n        requireAtLeast(this.ackedRetentionMs, 0L, \"queue.acked-retention-ms\");\n    }\n\n    public static QueueConfig from(ReadonlyConfig config) {\n        return new QueueConfig(config);\n    }\n\n    private static void requireAtLeast(int value, int min, String optionPath) {\n        if (value < min) {\n            throw new IllegalArgumentException(optionPath + \" must be >= \" + min + \" when set.\");\n        }\n    }\n\n    private static void requireAtLeast(long value, long min, String optionPath) {\n        if (value < min) {\n            throw new IllegalArgumentException(optionPath + \" must be >= \" + min + \" when set.\");\n        }\n    }\n}\n","sourceCodeStart":55,"sourceCodeEnd":83,"githubUrl":"https://github.com/apache/seatunnel/blob/cf67b549a7a6c35fa0beb12d83c62892427ea919/seatunnel-edge-agent/seatunnel-edge-agent-starter/src/main/java/org/apache/seatunnel/edge/agent/starter/config/QueueConfig.java#L55-L83","documentation":"QueueConfig.requireAtLeast (int overload) validates that an integer queue option, when explicitly set, meets a minimum threshold. It throws IllegalArgumentException naming the option path and the minimum when the value is below the floor.","triggerScenarios":"Constructing QueueConfig from a ReadonlyConfig where an int queue option (via the int requireAtLeast overload) is set to a value smaller than its declared minimum.","commonSituations":"User sets a queue capacity/size option to 0 or a negative number in the 'queue' YAML section; unit confusion (bytes vs entries) leading to too-small values.","solutions":["Raise the offending queue option to at least the stated minimum in the YAML.","Read the message's optionPath to identify exactly which option is below minimum.","Remove the option to fall back to defaults if a custom small value is not required."],"exampleFix":"# before\nqueue:\n  capacity: 0\n# after\nqueue:\n  capacity: 1024","handlingStrategy":"validation","validationCode":"Integer capacity = config.get(QUEUE_CAPACITY_OPTION);\nif (capacity != null && capacity < MIN_CAPACITY) {\n    throw new IllegalArgumentException(\"queue capacity must be >= \" + MIN_CAPACITY);\n}","typeGuard":null,"tryCatchPattern":"try { QueueConfig.from(config); } catch (IllegalArgumentException e) { log.error(\"Queue config invalid: {}\", e.getMessage()); }","preventionTips":["Check minimums documented for each queue option before setting custom values.","Omit options you do not need so defaults apply.","Double-check for 0/negative values after hand-editing YAML."],"tags":["config","validation","queue"],"backgroundTag":"value-out-of-range","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"}