List of usage examples for org.apache.hadoop.mapreduce Partitioner subclass-usage
From source file org.apache.kylin.engine.mr.steps.CalculateStatsFromBaseCuboidPartitioner.java
/** */ public class CalculateStatsFromBaseCuboidPartitioner extends Partitioner<Text, Text> implements Configurable { private static final Logger logger = LoggerFactory.getLogger(CalculateStatsFromBaseCuboidPartitioner.class); private Configuration conf;
From source file org.apache.kylin.engine.mr.steps.FactDistinctColumnPartitioner.java
/** */ public class FactDistinctColumnPartitioner extends Partitioner<SelfDefineSortableKey, Text> { @Override public int getPartition(SelfDefineSortableKey skey, Text value, int numReduceTasks) {
From source file org.apache.kylin.engine.mr.steps.fdc2.FactDistinctColumnPartitioner2.java
/** */ public class FactDistinctColumnPartitioner2 extends Partitioner<SelfDefineSortableKey, Text> { private Configuration conf; @Override
From source file org.apache.kylin.engine.mr.steps.UHCDictionaryPartitioner.java
public class UHCDictionaryPartitioner extends Partitioner<SelfDefineSortableKey, NullWritable> { @Override public int getPartition(SelfDefineSortableKey skey, NullWritable value, int numReduceTasks) { return BytesUtil.readUnsigned(skey.getText().getBytes(), 0, 1); } }
From source file org.apache.kylin.job.hadoop.invertedindex.InvertedIndexPartitioner.java
/** * @author yangli9 */ public class InvertedIndexPartitioner extends Partitioner<LongWritable, ImmutableBytesWritable> implements Configurable {
From source file org.apache.mahout.utils.nlp.collocations.llr.GramKeyPartitioner.java
/** * Partition GramKeys based on their Gram, ignoring the secondary sort key so that all GramKeys with the same * gram are sent to the same partition. */ public class GramKeyPartitioner extends Partitioner<GramKey, Gram> {
From source file org.apache.mahout.vectorizer.collocations.llr.GramKeyPartitioner.java
/** * Partition GramKeys based on their Gram, ignoring the secondary sort key so that all GramKeys with the same * gram are sent to the same partition. */ public final class GramKeyPartitioner extends Partitioner<GramKey, Gram> {
From source file org.apache.nutch.fetcher.PartitionUrlByHost.java
public class PartitionUrlByHost extends Partitioner<IntWritable, FetchEntry> { @Override public int getPartition(IntWritable key, FetchEntry value, int numPartitions) { String urlString = TableUtil.unreverseUrl(value.getKey());
From source file org.apache.pig.backend.hadoop.executionengine.mapReduceLayer.partitioners.SkewedPartitioner.java
/**
* This class is used by skewed join. For the partitioned table, the skewedpartitioner reads the key
* distribution data from the sampler file and returns the reducer index in a round robin fashion.
* For ex: if the key distribution file contains (k1, 5, 3) as an entry, reducers from 5 to 3 are returned
* in a round robin manner.
*/
From source file org.apache.pig.backend.hadoop.executionengine.mapReduceLayer.partitioners.WeightedRangePartitioner.java
public class WeightedRangePartitioner extends Partitioner<PigNullableWritable, Writable> implements Configurable { protected Map<PigNullableWritable, DiscreteProbabilitySampleGenerator> weightedParts = new HashMap<PigNullableWritable, DiscreteProbabilitySampleGenerator>(); protected PigNullableWritable[] quantiles; protected RawComparator<PigNullableWritable> comparator; private PigContext pigContext;