public class Extract extends State
The extract ID only needs to be unique for Extracts belonging to the same
namespace/table. One or more WorkUnits can share the same extract ID.
WorkUnits that do share an extract ID will be considered parts of a single
Extract for the purpose of applying publishing policies.
| Modifier and Type | Class and Description |
|---|---|
static class |
Extract.TableType |
| Constructor and Description |
|---|
Extract(Extract.TableType type,
String namespace,
String table)
Constructor.
|
Extract(Extract extract)
Deep copy constructor.
|
Extract(SourceState state,
Extract.TableType type,
String namespace,
String table)
Deprecated.
Extract does not use any property in
SourceState.
Use Extract(TableType, String, String) |
| Modifier and Type | Method and Description |
|---|---|
void |
addDeltaField(String... deltaFieldName)
Deprecated.
It is recommended to add delta fields in
WorkUnit instead of Extract. |
void |
addPrimaryKey(String... primaryKeyFieldName)
Deprecated.
@deprecated It is recommended to add primary keys in
WorkUnit instead of Extract. |
boolean |
equals(Object object) |
List<String> |
getDeltaFields()
Deprecated.
It is recommended to obtain delta fields from
WorkUnit instead of Extract. |
String |
getExtractId()
Get a (non-globally) unique ID for this
Extract. |
boolean |
getIsFull()
Deprecated.
It is recommend to get this information from
WorkUnit instead of Extract. |
String |
getNamespace()
Get the dot-separated namespace of the table.
|
String |
getOutputFilePath()
Deprecated.
As
this.getIsFull is deprecated. |
State |
getPreviousTableState()
Get the previous table
State. |
List<String> |
getPrimaryKeys()
Deprecated.
It is recommended to obtain primary keys from
WorkUnit instead of Extract. |
String |
getTable()
Get the name of the table.
|
Extract.TableType |
getType()
Get the
Extract.TableType of the table. |
int |
hashCode() |
boolean |
hasType()
If this
Extract has extract table type defined. |
void |
setDeltaFields(String... deltaFieldName)
Deprecated.
It is recommended to set delta fields in
WorkUnit instead of Extract. |
void |
setExtractId(String extractId)
Set a (non-globally) unique ID for this
Extract. |
void |
setFullTrue(long extractFullRunTime)
Deprecated.
It is recommend to set this information in
WorkUnit instead of Extract. |
void |
setPrimaryKeys(String... primaryKeyFieldName)
Deprecated.
It is recommended to set primary keys in
WorkUnit instead of Extract. |
addAll, addAll, addAllIfNotExist, addAllIfNotExist, appendToListProp, appendToSetProp, contains, getId, getProp, getProp, getPropAsBoolean, getPropAsBoolean, getPropAsCaseInsensitiveSet, getPropAsCaseInsensitiveSet, getPropAsDouble, getPropAsDouble, getPropAsInt, getPropAsInt, getPropAsJsonArray, getPropAsList, getPropAsList, getPropAsLong, getPropAsLong, getPropAsSet, getPropAsSet, getPropAsShort, getPropAsShort, getPropAsShortWithRadix, getPropAsShortWithRadix, getProperties, getProperty, getProperty, getPropertyNames, overrideWith, overrideWith, readFields, removeProp, removePropsWithPrefix, setId, setProp, setProps, toString, write@Deprecated public Extract(SourceState state, Extract.TableType type, String namespace, String table)
SourceState.
Use Extract(TableType, String, String)state - a SourceState carrying properties needed to construct an Extractnamespace - dot separated namespace pathtype - Extract.TableTypetable - table namepublic Extract(Extract.TableType type, String namespace, String table)
type - Extract.TableTypenamespace - dot separated namespace pathtable - table name@Deprecated public String getOutputFilePath()
this.getIsFull is deprecated.Extract.Extractpublic boolean hasType()
Extract has extract table type defined.true if it has, false otherwise.public Extract.TableType getType()
Extract.TableType of the table.Extract.TableType of the tablepublic String getNamespace()
public String getTable()
public String getExtractId()
Extract.Extractpublic void setExtractId(String extractId)
Extract.extractId - unique ID for this Extract@Deprecated public boolean getIsFull()
WorkUnit instead of Extract.Extract represents the full contents of the source table.true if this Extract represents the full contents
of the source table and false otherwise@Deprecated public void setFullTrue(long extractFullRunTime)
WorkUnit instead of Extract.extractFullRunTime - full extract time@Deprecated public void setPrimaryKeys(String... primaryKeyFieldName)
WorkUnit instead of Extract.The order of primary keys does not matter.
primaryKeyFieldName - primary key names@Deprecated public void addPrimaryKey(String... primaryKeyFieldName)
WorkUnit instead of Extract.primaryKeyFieldName - primary key names@Deprecated public List<String> getPrimaryKeys()
WorkUnit instead of Extract.@Deprecated public void setDeltaFields(String... deltaFieldName)
WorkUnit instead of Extract.The order of delta fields does not matter.
deltaFieldName - delta field names@Deprecated public void addDeltaField(String... deltaFieldName)
WorkUnit instead of Extract.deltaFieldName - delta field names@Deprecated public List<String> getDeltaFields()
WorkUnit instead of Extract.