[HUDI-3018] Adding validation to dataframe scheme to ensure reserved field does not have diff data type (#4852)
This commit is contained in:
committed by
GitHub
parent
2f99e8458a
commit
d5444ff7ff
@@ -40,6 +40,7 @@ public abstract class HoodieRecord<T> implements Serializable {
|
||||
public static final String PARTITION_PATH_METADATA_FIELD = "_hoodie_partition_path";
|
||||
public static final String FILENAME_METADATA_FIELD = "_hoodie_file_name";
|
||||
public static final String OPERATION_METADATA_FIELD = "_hoodie_operation";
|
||||
public static final String HOODIE_IS_DELETED = "_hoodie_is_deleted";
|
||||
|
||||
public static final List<String> HOODIE_META_COLUMNS =
|
||||
CollectionUtils.createImmutableList(COMMIT_TIME_METADATA_FIELD, COMMIT_SEQNO_METADATA_FIELD,
|
||||
|
||||
@@ -85,7 +85,7 @@ public class OverwriteWithLatestAvroPayload extends BaseAvroPayload
|
||||
* @returns {@code true} if record represents a delete record. {@code false} otherwise.
|
||||
*/
|
||||
protected boolean isDeleteRecord(GenericRecord genericRecord) {
|
||||
final String isDeleteKey = "_hoodie_is_deleted";
|
||||
final String isDeleteKey = HoodieRecord.HOODIE_IS_DELETED;
|
||||
// Modify to be compatible with new version Avro.
|
||||
// The new version Avro throws for GenericRecord.get if the field name
|
||||
// does not exist in the schema.
|
||||
|
||||
Reference in New Issue
Block a user