diff --git a/utils/sync/src/main/java/com/lanyuanxiaoyao/service/sync/functions/type/TypeConverterV2.java b/utils/sync/src/main/java/com/lanyuanxiaoyao/service/sync/functions/type/TypeConverterV2.java index c8e26c6..8ece80b 100644 --- a/utils/sync/src/main/java/com/lanyuanxiaoyao/service/sync/functions/type/TypeConverterV2.java +++ b/utils/sync/src/main/java/com/lanyuanxiaoyao/service/sync/functions/type/TypeConverterV2.java @@ -20,7 +20,11 @@ import org.apache.hudi.org.apache.avro.Schema; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import static org.apache.hudi.org.apache.avro.Schema.*; +import static org.apache.hudi.org.apache.avro.Schema.Field; +import static org.apache.hudi.org.apache.avro.Schema.Type; +import static org.apache.hudi.org.apache.avro.Schema.create; +import static org.apache.hudi.org.apache.avro.Schema.createFixed; +import static org.apache.hudi.org.apache.avro.Schema.createUnion; /** * 类型转换第二版本 @@ -184,6 +188,6 @@ public class TypeConverterV2 implements TypeConverter { } private boolean isNullValue(Object value) { - return StrUtil.isBlankIfStr(value) || ObjectUtil.equals("null", value); + return StrUtil.isBlankIfStr(value) || (value instanceof String ? "null".equalsIgnoreCase((String) value) : value == null); } }