public final class SortJoinUtils
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
SortJoinUtils.ListBasedRestorableIterator |
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CONFIG_USE_SORT_JOIN_CACHE |
Modifier and Type | Method and Description |
---|---|
static java.util.List<java.lang.Object> |
fullOuterJoin(java.util.List<Tuple> leftRelation,
java.util.List<Tuple> rightRelation,
KeyComparatorWrapper comparator)
Full Outer join the left and right relation using the tuple key
|
static java.util.Iterator<JoinedTuple> |
fullOuterJoin(RestorableIterator<Tuple<?,?>> leftIt,
RestorableIterator<Tuple<?,?>> rightIt,
KeyComparatorWrapper comparator)
Full Outer join the left and right relation using the tuple key
|
static java.util.List<java.lang.Object> |
innerJoin(java.util.List<Tuple> leftRelation,
java.util.List<Tuple> rightRelation,
KeyComparatorWrapper comparator)
Inner join the left and right relation using the tuple key
|
static java.util.Iterator<JoinedTuple> |
innerJoin(RestorableIterator<Tuple<?,?>> leftIt,
RestorableIterator<Tuple<?,?>> rightIt,
KeyComparatorWrapper comparator)
This util can be used to perform disk based inner join operations.
|
static java.util.Iterator<JoinedTuple> |
join(java.util.List<Tuple> leftRelation,
java.util.List<Tuple> rightRelation,
KeyComparatorWrapper comparator,
CommunicationContext.JoinType joinType) |
static java.util.Iterator<JoinedTuple> |
join(RestorableIterator<Tuple<?,?>> leftIt,
RestorableIterator<Tuple<?,?>> rightIt,
KeyComparatorWrapper comparator,
CommunicationContext.JoinType joinType) |
static java.util.Iterator<JoinedTuple> |
joinWithCache(RestorableIterator<Tuple<?,?>> leftIt,
RestorableIterator<Tuple<?,?>> rightIt,
KeyComparatorWrapper comparator,
CommunicationContext.JoinType joinType,
Config config)
This method avoid having to scan back and forth of the files by reading data iterators once
and backup them into a
DiskBasedList , which has a memory buffer |
static java.util.List<java.lang.Object> |
leftOuterJoin(java.util.List<Tuple> leftRelation,
java.util.List<Tuple> rightRelation,
KeyComparatorWrapper comparator)
Left Outer join the left and right relation using the tuple key
|
static java.util.Iterator<JoinedTuple> |
leftOuterJoin(RestorableIterator<Tuple<?,?>> leftIt,
RestorableIterator<Tuple<?,?>> rightIt,
KeyComparatorWrapper comparator)
Left Outer join the left and right relation using the tuple key
|
static java.util.Iterator<JoinedTuple> |
outerJoin(RestorableIterator<Tuple<?,?>> leftIt,
RestorableIterator<Tuple<?,?>> rightIt,
KeyComparatorWrapper comparator,
CommunicationContext.JoinType outerJoinType)
This util can be used to perform disk based inner join operations.
|
static java.util.List<java.lang.Object> |
rightOuterJoin(java.util.List<Tuple> leftRelation,
java.util.List<Tuple> rightRelation,
KeyComparatorWrapper comparator)
Right Outer join the left and right relation using the tuple key
|
static java.util.Iterator<JoinedTuple> |
rightOuterJoin(RestorableIterator<Tuple<?,?>> leftIt,
RestorableIterator<Tuple<?,?>> rightIt,
KeyComparatorWrapper comparator)
Right Outer join the left and right relation using the tuple key
|
public static final java.lang.String CONFIG_USE_SORT_JOIN_CACHE
public static java.util.Iterator<JoinedTuple> join(java.util.List<Tuple> leftRelation, java.util.List<Tuple> rightRelation, KeyComparatorWrapper comparator, CommunicationContext.JoinType joinType)
public static java.util.Iterator<JoinedTuple> join(RestorableIterator<Tuple<?,?>> leftIt, RestorableIterator<Tuple<?,?>> rightIt, KeyComparatorWrapper comparator, CommunicationContext.JoinType joinType)
public static java.util.List<java.lang.Object> innerJoin(java.util.List<Tuple> leftRelation, java.util.List<Tuple> rightRelation, KeyComparatorWrapper comparator)
leftRelation
- left relationrightRelation
- right relationcomparator
- comparatorpublic static java.util.Iterator<JoinedTuple> joinWithCache(RestorableIterator<Tuple<?,?>> leftIt, RestorableIterator<Tuple<?,?>> rightIt, KeyComparatorWrapper comparator, CommunicationContext.JoinType joinType, Config config)
DiskBasedList
, which has a memory bufferpublic static java.util.Iterator<JoinedTuple> innerJoin(RestorableIterator<Tuple<?,?>> leftIt, RestorableIterator<Tuple<?,?>> rightIt, KeyComparatorWrapper comparator)
public static java.util.Iterator<JoinedTuple> outerJoin(RestorableIterator<Tuple<?,?>> leftIt, RestorableIterator<Tuple<?,?>> rightIt, KeyComparatorWrapper comparator, CommunicationContext.JoinType outerJoinType)
public static java.util.Iterator<JoinedTuple> fullOuterJoin(RestorableIterator<Tuple<?,?>> leftIt, RestorableIterator<Tuple<?,?>> rightIt, KeyComparatorWrapper comparator)
public static java.util.Iterator<JoinedTuple> leftOuterJoin(RestorableIterator<Tuple<?,?>> leftIt, RestorableIterator<Tuple<?,?>> rightIt, KeyComparatorWrapper comparator)
public static java.util.Iterator<JoinedTuple> rightOuterJoin(RestorableIterator<Tuple<?,?>> leftIt, RestorableIterator<Tuple<?,?>> rightIt, KeyComparatorWrapper comparator)
public static java.util.List<java.lang.Object> fullOuterJoin(java.util.List<Tuple> leftRelation, java.util.List<Tuple> rightRelation, KeyComparatorWrapper comparator)
public static java.util.List<java.lang.Object> leftOuterJoin(java.util.List<Tuple> leftRelation, java.util.List<Tuple> rightRelation, KeyComparatorWrapper comparator)
public static java.util.List<java.lang.Object> rightOuterJoin(java.util.List<Tuple> leftRelation, java.util.List<Tuple> rightRelation, KeyComparatorWrapper comparator)