{"record":{"id":"9f8a83474372b2a6","repo":"apache/seatunnel","slug":"unsupported-data-type-9f8a83","errorCode":"UNSUPPORTED_DATA_TYPE","errorMessage":"Unsupported type: ${type}","messagePattern":"Unsupported type: (.+?)","errorType":"error_code","errorClass":"SeaTunnelJsonFormatException","httpStatus":null,"severity":"error","filePath":"seatunnel-formats/seatunnel-format-json/src/main/java/org/apache/seatunnel/format/json/JsonToRowConverters.java","lineNumber":217,"sourceCode":"                    public Object convert(JsonNode jsonNode, String fieldName) {\n                        return convertToBigDecimal(jsonNode);\n                    }\n                };\n            case FLOAT_VECTOR:\n                return new JsonToObjectConverter() {\n                    @Override\n                    public Object convert(JsonNode jsonNode, String fieldName) {\n                        return convertToFloatVector(jsonNode, fieldName);\n                    }\n                };\n            case ARRAY:\n                return createArrayConverter((ArrayType<?, ?>) type);\n            case MAP:\n                return createMapConverter((MapType<?, ?>) type);\n            case ROW:\n                return createRowConverter((SeaTunnelRowType) type);\n            default:\n                throw new SeaTunnelJsonFormatException(\n                        CommonErrorCodeDeprecated.UNSUPPORTED_DATA_TYPE,\n                        \"Unsupported type: \" + type);\n        }\n    }\n\n    private boolean convertToBoolean(JsonNode jsonNode) {\n        if (jsonNode.isBoolean()) {\n            // avoid redundant toString and parseBoolean, for better performance\n            return jsonNode.asBoolean();\n        } else {\n            return Boolean.parseBoolean(jsonNode.asText().trim());\n        }\n    }\n\n    private int convertToInt(JsonNode jsonNode) {\n        if (jsonNode.canConvertToInt()) {\n            // avoid redundant toString and parseInt, for better performance\n            return jsonNode.asInt();","sourceCodeStart":199,"sourceCodeEnd":235,"githubUrl":"https://github.com/apache/seatunnel/blob/cf67b549a7a6c35fa0beb12d83c62892427ea919/seatunnel-formats/seatunnel-format-json/src/main/java/org/apache/seatunnel/format/json/JsonToRowConverters.java#L199-L235","documentation":"JsonToRowConverters.createNotNullConverter maps each SeaTunnel data type to a JSON-to-row converter; there is no converter registered for the type being converted, so the switch hits its default branch and throws SeaTunnelJsonFormatException with UNSUPPORTED_DATA_TYPE. This means the row type contains a data type (SqlType) the JSON format cannot deserialize.","triggerScenarios":"A source/sink declares a SeaTunnelRowType whose field type's SqlType falls outside STRING/BOOLEAN/TINYINT..DOUBLE/DATE/TIME/TIMESTAMP/ARRAY/MAP/ROW/FLOAT_VECTOR — e.g. a custom or newly added SqlType, or a BYTES/NULL type — and the JSON deserializer builds converters for it.","commonSituations":"New data types added to the API but not yet supported by the JSON format (version skew between seatunnel-api and seatunnel-format-json); connectors passing exotic catalog column types into a JSON format schema.","solutions":["Check which field type is unsupported (the message prints it) and change the schema to a JSON-supported type (e.g. STRING, ARRAY<FLOAT>, MAP, ROW).","Upgrade seatunnel-format-json / SeaTunnel to a version whose JsonToRowConverters supports the type.","If the type is genuinely unsupported, file/patch a converter in JsonToRowConverters.createNotNullConverter."],"exampleFix":"// before\nSeaTunnelRowType type = new SeaTunnelRowType(new String[]{\"v\"}, new SeaTunnelDataType[]{BytesType.INSTANCE}); // unsupported\n// after\nSeaTunnelRowType type = new SeaTunnelRowType(new String[]{\"v\"}, new ArrayType<>(FloatType.INSTANCE)); // FLOAT_VECTOR array","handlingStrategy":"validation","validationCode":"for (SeaTunnelDataType<?> t : rowType.getFieldTypes()) {\n    switch (t.getSqlType()) {\n        case STRING: case BOOLEAN: case TINYINT: case SMALLINT: case INT: case BIGINT:\n        case FLOAT: case DOUBLE: case DATE: case TIME: case TIMESTAMP:\n        case ARRAY: case MAP: case ROW: case FLOAT_VECTOR:\n            break;\n        default:\n            throw new IllegalArgumentException(\"JSON format cannot handle type: \" + t.getSqlType());\n    }\n}","typeGuard":"static boolean isJsonSupported(SeaTunnelDataType<?> t) {\n    switch (t.getSqlType()) {\n        case ARRAY: case MAP: case ROW: case FLOAT_VECTOR:\n        case STRING: case BOOLEAN: case TINYINT: case SMALLINT: case INT:\n        case BIGINT: case FLOAT: case DOUBLE: case DATE: case TIME: case TIMESTAMP:\n            return true;\n        default:\n            return false;\n    }\n}","tryCatchPattern":"try {\n    converter = new JsonToRowConverters().createConverter(rowType);\n} catch (SeaTunnelJsonFormatException e) {\n    throw new IllegalArgumentException(\"Unsupported field type for JSON format: \" + e.getMessage(), e);\n}","preventionTips":["Keep SeaTunnel API and format module versions in lock-step (same release) to avoid unsupported new types.","Validate the declared schema types against JSON-format support before job submission.","Avoid exotic column types (BYTES, custom types) in JSON-format sources."],"tags":["json","unsupported-type","deserialization","schema"],"backgroundTag":"unsupported-dtype","analyzedSha":"cf67b549a7a6c35fa0beb12d83c62892427ea919","analyzedAt":"2026-09-10T21:44:55.265Z","contentChangedAt":"2026-09-10T21:44:55.265Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}