@@ -20,13 +20,12 @@ package org.apache.hudi.common.model;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Type of the Hoodie Table.
|
* Type of the Hoodie Table.
|
||||||
* <p>
|
*
|
||||||
* Currently, 2 types are supported.
|
* Currently, 2 types are supported.
|
||||||
* <p>
|
* <ul>
|
||||||
* COPY_ON_WRITE - Performs upserts by versioning entire files, with later versions containing newer value of a record.
|
* <li> COPY_ON_WRITE - Performs upserts by versioning entire files, with later versions containing newer value of a record.
|
||||||
* <p>
|
* <li> MERGE_ON_READ - Speeds up upserts, by delaying merge until enough work piles up.
|
||||||
* MERGE_ON_READ - Speeds up upserts, by delaying merge until enough work piles up.
|
* </ul>
|
||||||
* <p>
|
|
||||||
*/
|
*/
|
||||||
public enum HoodieTableType {
|
public enum HoodieTableType {
|
||||||
COPY_ON_WRITE, MERGE_ON_READ
|
COPY_ON_WRITE, MERGE_ON_READ
|
||||||
|
|||||||
@@ -29,10 +29,12 @@ import java.util.List;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* subclass of OverwriteWithLatestAvroPayload used for delta streamer.
|
* subclass of OverwriteWithLatestAvroPayload used for delta streamer.
|
||||||
* <p>
|
*
|
||||||
* 1. preCombine - Picks the latest delta record for a key, based on an ordering field.
|
* <ol>
|
||||||
* 2. combineAndGetUpdateValue/getInsertValue - overwrite storage for specified fields
|
* <li>preCombine - Picks the latest delta record for a key, based on an ordering field;
|
||||||
|
* <li>combineAndGetUpdateValue/getInsertValue - overwrite storage for specified fields
|
||||||
* that doesn't equal defaultValue.
|
* that doesn't equal defaultValue.
|
||||||
|
* </ol>
|
||||||
*/
|
*/
|
||||||
public class OverwriteNonDefaultsWithLatestAvroPayload extends OverwriteWithLatestAvroPayload {
|
public class OverwriteNonDefaultsWithLatestAvroPayload extends OverwriteWithLatestAvroPayload {
|
||||||
|
|
||||||
|
|||||||
@@ -29,16 +29,15 @@ import java.io.IOException;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Default payload used for delta streamer.
|
* Default payload used for delta streamer.
|
||||||
* <p>
|
*
|
||||||
* 1. preCombine - Picks the latest delta record for a key, based on an ordering field 2.
|
* <ol>
|
||||||
* combineAndGetUpdateValue/getInsertValue - Simply overwrites storage with latest delta record
|
* <li> preCombine - Picks the latest delta record for a key, based on an ordering field;
|
||||||
|
* <li> combineAndGetUpdateValue/getInsertValue - Simply overwrites storage with latest delta record
|
||||||
|
* </ol>
|
||||||
*/
|
*/
|
||||||
public class OverwriteWithLatestAvroPayload extends BaseAvroPayload
|
public class OverwriteWithLatestAvroPayload extends BaseAvroPayload
|
||||||
implements HoodieRecordPayload<OverwriteWithLatestAvroPayload> {
|
implements HoodieRecordPayload<OverwriteWithLatestAvroPayload> {
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
public OverwriteWithLatestAvroPayload(GenericRecord record, Comparable orderingVal) {
|
public OverwriteWithLatestAvroPayload(GenericRecord record, Comparable orderingVal) {
|
||||||
super(record, orderingVal);
|
super(record, orderingVal);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user