apache/seatunnel · error · java.lang.IllegalArgumentException

Configuration value overflows/underflows the float type.

Error message

Configuration value %s overflows/underflows the float type.

What it means

Thrown from ConfigUtil.convertToFloat when a Double operand falls outside the float-representable range: the check allows 0.0 and values within ±Float.MIN_VALUE..Float.MAX_VALUE and rejects everything else as overflow/underflow. It fires on magnitude problems only (e.g. 1e100); non-numeric text fails elsewhere with NumberFormatException.

Solutions

  1. Use a value within the float range (roughly ±3.4e38)
  2. If higher precision or range is needed, declare the option as Double instead of Float
  3. Check for a units mistake that made the value astronomically large
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at seatunnel-api/src/main/java/org/apache/seatunnel/api/configuration/util/ConfigUtil.java:162 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of apache/seatunnel@cf67b549a7 (2026-09-10). Data as JSON: /api/errors/41646059c9d7e7fd. Report an issue: GitHub.

Appendix: source

Thrown at seatunnel-api/src/main/java/org/apache/seatunnel/api/configuration/util/ConfigUtil.java:162

            return (Long) o;
        } else if (o.getClass() == Integer.class) {
            return ((Integer) o).longValue();
        }

        return Long.parseLong(o.toString());
    }

    static Float convertToFloat(Object o) {
        if (o.getClass() == Float.class) {
            return (Float) o;
        } else if (o.getClass() == Double.class) {
            double value = ((Double) o);
            if (value == 0.0
                    || (value >= Float.MIN_VALUE && value <= Float.MAX_VALUE)
                    || (value >= -Float.MAX_VALUE && value <= -Float.MIN_VALUE)) {
                return (float) value;
            } else {
                throw new IllegalArgumentException(
                        String.format(
                                "Configuration value %s overflows/underflows the float type.",
                                value));
            }
        }

        return Float.parseFloat(o.toString());
    }

    static Double convertToDouble(Object o) {
        if (o.getClass() == Double.class) {
            return (Double) o;
        } else if (o.getClass() == Float.class) {
            return ((Float) o).doubleValue();
        }

        return Double.parseDouble(o.toString());
    }

View on GitHub (pinned to cf67b549a7)