{"record":{"id":"35db86eeafc1d720","repo":"apache/seatunnel","slug":"stripe-option-rate-limit-backoff-ms-must-not-be","errorCode":null,"errorMessage":"Stripe option 'rate_limit_backoff_ms' must not be negative","messagePattern":"Stripe option 'rate_limit_backoff_ms' must not be negative","errorType":"validation","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"seatunnel-connectors-v2/connector-http/connector-http-stripe/src/main/java/org/apache/seatunnel/connectors/seatunnel/stripe/source/config/StripeSourceParameter.java","lineNumber":79,"sourceCode":"        if (createdGte != null && createdGte < 0) {\n            throw new IllegalArgumentException(\"Stripe option 'created_gte' must not be negative\");\n        }\n        if (createdLt != null && createdLt < 0) {\n            throw new IllegalArgumentException(\"Stripe option 'created_lt' must not be negative\");\n        }\n        if (createdGte != null && createdLt != null && createdGte >= createdLt) {\n            throw new IllegalArgumentException(\n                    \"Stripe option 'created_gte' must be less than 'created_lt'\");\n        }\n\n        this.rateLimitMaxRetries = pluginConfig.get(StripeSourceOptions.RATE_LIMIT_MAX_RETRIES);\n        this.rateLimitBackoffMs = pluginConfig.get(StripeSourceOptions.RATE_LIMIT_BACKOFF_MS);\n        if (rateLimitMaxRetries < 0) {\n            throw new IllegalArgumentException(\n                    \"Stripe option 'rate_limit_max_retries' must not be negative\");\n        }\n        if (rateLimitBackoffMs < 0) {\n            throw new IllegalArgumentException(\n                    \"Stripe option 'rate_limit_backoff_ms' must not be negative\");\n        }\n\n        setUrl(trimTrailingSlash(apiBaseUrl.trim()) + PAYMENT_INTENTS_PATH);\n        setMethod(HttpRequestMethod.GET);\n\n        Map<String, String> requestHeaders = new LinkedHashMap<>();\n        requestHeaders.put(AUTHORIZATION, \"Bearer \" + secretKey);\n        requestHeaders.put(ACCEPT, \"application/json\");\n        pluginConfig\n                .getOptional(StripeSourceOptions.API_VERSION)\n                .filter(version -> !version.trim().isEmpty())\n                .ifPresent(version -> requestHeaders.put(STRIPE_VERSION, version.trim()));\n        setHeaders(requestHeaders);\n\n        Map<String, String> requestParams = new LinkedHashMap<>();\n        requestParams.put(\"limit\", Integer.toString(pageSize));\n        if (createdGte != null) {","sourceCodeStart":61,"sourceCodeEnd":97,"githubUrl":"https://github.com/apache/seatunnel/blob/cf67b549a7a6c35fa0beb12d83c62892427ea919/seatunnel-connectors-v2/connector-http/connector-http-stripe/src/main/java/org/apache/seatunnel/connectors/seatunnel/stripe/source/config/StripeSourceParameter.java#L61-L97","documentation":"buildWithConfig validates the rate_limit_backoff_ms option, the base delay in milliseconds between Stripe 429 retry attempts. Negative delays are nonsensical, so the connector throws this IllegalArgumentException during config validation.","triggerScenarios":"Calling buildWithConfig with pluginConfig where RATE_LIMIT_BACKOFF_MS resolves to a negative long, e.g. rate_limit_backoff_ms = -500.","commonSituations":"User tries to speed up polling with a negative value; sign typo; misreading the option as a relative adjustment rather than an absolute delay.","solutions":["Set rate_limit_backoff_ms to a non-negative value (e.g. 1000).","Remove the option to use the default backoff.","If retries feel too slow, lower the positive value rather than making it negative.","Validate related rate_limit_max_retries is also non-negative so the pair is consistent."],"exampleFix":"// before\nrate_limit_backoff_ms = -500\n// after\nrate_limit_backoff_ms = 1000","handlingStrategy":"validation","validationCode":"long backoff = pluginConfig.get(StripeSourceOptions.RATE_LIMIT_BACKOFF_MS);\nif (backoff < 0) {\n    throw new IllegalArgumentException(\"rate_limit_backoff_ms must be >= 0\");\n}","typeGuard":null,"tryCatchPattern":"try {\n    StripeSourceParameter p = StripeSourceParameter.buildWithConfig(pluginConfig);\n} catch (IllegalArgumentException e) {\n    throw new IllegalArgumentException(\"Invalid rate_limit_backoff_ms: \" + e.getMessage(), e);\n}","preventionTips":["Use positive millisecond values (e.g. 500-2000) for backoff.","Never use negatives to 'speed up' retries; reduce the positive value instead.","Pair-validate backoff with max_retries in config templates."],"tags":["config-validation","retry","range-check"],"backgroundTag":"invalid-config-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"}