Example usage for org.apache.spark.api.java.function PairFlatMapFunction interface-usage

List of usage examples for org.apache.spark.api.java.function PairFlatMapFunction interface-usage

Introduction

In this page you can find the example usage for org.apache.spark.api.java.function PairFlatMapFunction interface-usage.

Usage

From source file co.cask.cdap.etl.spark.function.AggregatorGroupByFunction.java

/**
 * Function that uses a BatchAggregator to perform the groupBy part of the aggregator.
 * Non-serializable fields are lazily created since this is used in a Spark closure.
 *
 * @param <GROUP_KEY> type of group key
 * @param <GROUP_VAL> type of group val

From source file co.cask.cdap.etl.spark.function.BatchSinkFunction.java

/**
 * Function that uses a BatchSink to transform one object into a pair.
 * Non-serializable fields are lazily created since this is used in a Spark closure.
 */
public class BatchSinkFunction implements PairFlatMapFunction<Object, Object, Object> {
    private final PluginFunctionContext pluginFunctionContext;

From source file co.cask.cdap.etl.spark.function.JoinOnFunction.java

/**
 * Function that uses a BatchJoiner to perform the joinOn part of the join.
 * Non-serializable fields are lazily created since this is used in a Spark closure.
 *
 * @param <JOIN_KEY> the type of join key
 * @param <INPUT_RECORD> the type of input records to the join stage

From source file com.cloudera.dataflow.spark.MultiDoFnFunction.java

/**
 * DoFunctions ignore side outputs. MultiDoFunctions deal with side outputs by enriching the
 * underlying data with multiple TupleTags.
 *
 * @param <I> Input type for DoFunction.
 * @param <O> Output type for DoFunction.

From source file com.github.cbismuth.spark.utils.cluster.mapper.partition.PartitionToPairMapper.java

public final class PartitionToPairMapper<T, K, R> implements PairFlatMapFunction<Iterator<T>, K, R> {

    private static final long serialVersionUID = -3475108324090125L;

    private final int ordered;
    private final boolean parallel;

From source file com.ibm.bi.dml.runtime.controlprogram.parfor.DataPartitionerRemoteSparkMapper.java

/**
 * NOTE: for the moment we only support binary block here
 * TODO extend impl for binarycell and textcell   
 * 
 * Interface of Writable output in order to support both PairWritableBlock and PairWritableCell.
 * 

From source file com.ibm.bi.dml.runtime.controlprogram.parfor.RemoteDPParForSparkWorker.java

/**
 * 
 */
public class RemoteDPParForSparkWorker extends ParWorker
        implements PairFlatMapFunction<Iterator<Tuple2<Long, Iterable<Writable>>>, Long, String> {
    private static final long serialVersionUID = 30223759283155139L;

From source file com.ibm.bi.dml.runtime.controlprogram.parfor.RemoteParForSparkWorker.java

/**
 * 
 * 
 */
public class RemoteParForSparkWorker extends ParWorker implements PairFlatMapFunction<Task, Long, String> {

From source file com.ibm.bi.dml.runtime.instructions.spark.functions.ExtractBlockForBinaryReblock.java

public class ExtractBlockForBinaryReblock
        implements PairFlatMapFunction<Tuple2<MatrixIndexes, MatrixBlock>, MatrixIndexes, MatrixBlock> {
    private static final long serialVersionUID = -762987655085029215L;

    private long rlen;
    private long clen;

From source file com.ibm.bi.dml.runtime.instructions.spark.functions.ExtractGroup.java

public class ExtractGroup implements
        PairFlatMapFunction<Tuple2<MatrixIndexes, Tuple2<MatrixBlock, MatrixBlock>>, Long, WeightedCell> {

    private static final long serialVersionUID = -7059358143841229966L;

    @Override