StarRocks / starrocks-connector-for-apache-flink

Apache License 2.0
189 stars 152 forks source link

[Bug] The starrocks connector unknown datatype handle method maybe need to change #369

Open XiaoYou201 opened 1 month ago

XiaoYou201 commented 1 month ago

The starrocks connector handle UNKNOWN data type as same as json. It is unreasonable. So, it need to be modified.

https://github.com/StarRocks/starrocks-connector-for-apache-flink/blob/cc8689d6ab75f68416491a1b841bdea1eaf85f4f/src/main/java/com/starrocks/connector/flink/row/sink/StarRocksTableRowTransformer.java#L126-L135

In my opinion, if data type is unknown, we should return origin data.

For example, while starrocks table not has a column named c1, but the user insert data has c1 and c1 value is ""(blank string) through flink, it will encounter IndexOfRangeException.