/** * sources may be very implementation specific * * @param source some source of data - might be a hadoop directory or a Spark RDD - this will be * cast internally * @param otherData */ @Override public void mapReduceSource(@Nonnull final Object source, final Object... otherData) { if (source instanceof JavaRDD) { performSourceMapReduce((JavaRDD) source); return; } if (source instanceof Path) { performMapReduce((Path) source); return; } if (source instanceof java.lang.Iterable) { performSourceMapReduce(SparkUtilities.fromIterable((Iterable) source)); return; } throw new IllegalArgumentException("cannot handle source of class " + source.getClass()); }