cascading.test
Class HadoopPlatform

java.lang.Object
  extended by cascading.test.TestPlatform
      extended by cascading.test.HadoopPlatform

public class HadoopPlatform
extends cascading.test.TestPlatform


Field Summary
static org.apache.hadoop.hdfs.MiniDFSCluster dfs
           
static FileSystem fileSys
           
static JobConf jobConf
           
static MiniMRCluster mr
           
 int numMapTasks
           
 int numReduceTasks
           
static Map<Object,Object> properties
           
 
Fields inherited from class cascading.test.TestPlatform
CLUSTER_TESTING_PROPERTY, TEST_PLATFORM_CLASSNAME
 
Constructor Summary
HadoopPlatform()
           
 
Method Summary
 void copyFromLocal(String inputFile)
           
 void copyToLocal(String outputFile)
           
 Tap getDelimitedFile(Fields fields, boolean skipHeader, boolean writeHeader, String delimiter, String quote, Class[] types, String filename, SinkMode mode)
           
 Tap getDelimitedFile(Fields fields, boolean hasHeader, String delimiter, String quote, Class[] types, String filename, SinkMode mode)
           
 FlowConnector getFlowConnector(Map<Object,Object> properties)
           
 FlowProcess getFlowProcess()
           
 JobConf getJobConf()
           
 Map<Object,Object> getProperties()
           
 Tap getTap(Scheme scheme, String filename, SinkMode mode)
           
 Tap getTemplateTap(Tap sink, String pathTemplate, Fields fields, int openThreshold)
           
 Tap getTemplateTap(Tap sink, String pathTemplate, int openThreshold)
           
 Tap getTextFile(Fields sourceFields, Fields sinkFields, String filename, SinkMode mode)
           
 boolean remoteExists(String outputFile)
           
 void setNumMapTasks(int numMapTasks)
           
 void setNumReduceTasks(int numReduceTasks)
           
 void setUp()
           
 void tearDown()
           
 
Methods inherited from class cascading.test.TestPlatform
getDelimitedFile, getDelimitedFile, getDelimitedFile, getDelimitedFile, getDelimitedFile, getFlowConnector, getName, getTextFile, getTextFile, getTextFile, getTextFile, isUseCluster, setUseCluster
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

dfs

public static transient org.apache.hadoop.hdfs.MiniDFSCluster dfs

fileSys

public static transient FileSystem fileSys

mr

public static transient MiniMRCluster mr

jobConf

public static transient JobConf jobConf

properties

public static transient Map<Object,Object> properties

numMapTasks

public int numMapTasks

numReduceTasks

public int numReduceTasks
Constructor Detail

HadoopPlatform

public HadoopPlatform()
Method Detail

setNumMapTasks

public void setNumMapTasks(int numMapTasks)

setNumReduceTasks

public void setNumReduceTasks(int numReduceTasks)

setUp

public void setUp()
           throws IOException
Specified by:
setUp in class cascading.test.TestPlatform
Throws:
IOException

getProperties

public Map<Object,Object> getProperties()
Specified by:
getProperties in class cascading.test.TestPlatform

tearDown

public void tearDown()
Specified by:
tearDown in class cascading.test.TestPlatform

getJobConf

public JobConf getJobConf()

getFlowConnector

public FlowConnector getFlowConnector(Map<Object,Object> properties)
Specified by:
getFlowConnector in class cascading.test.TestPlatform

getFlowProcess

public FlowProcess getFlowProcess()
Specified by:
getFlowProcess in class cascading.test.TestPlatform

copyFromLocal

public void copyFromLocal(String inputFile)
                   throws IOException
Specified by:
copyFromLocal in class cascading.test.TestPlatform
Throws:
IOException

copyToLocal

public void copyToLocal(String outputFile)
                 throws IOException
Specified by:
copyToLocal in class cascading.test.TestPlatform
Throws:
IOException

remoteExists

public boolean remoteExists(String outputFile)
                     throws IOException
Specified by:
remoteExists in class cascading.test.TestPlatform
Throws:
IOException

getTap

public Tap getTap(Scheme scheme,
                  String filename,
                  SinkMode mode)
Specified by:
getTap in class cascading.test.TestPlatform

getTextFile

public Tap getTextFile(Fields sourceFields,
                       Fields sinkFields,
                       String filename,
                       SinkMode mode)
Specified by:
getTextFile in class cascading.test.TestPlatform

getDelimitedFile

public Tap getDelimitedFile(Fields fields,
                            boolean hasHeader,
                            String delimiter,
                            String quote,
                            Class[] types,
                            String filename,
                            SinkMode mode)
Specified by:
getDelimitedFile in class cascading.test.TestPlatform

getDelimitedFile

public Tap getDelimitedFile(Fields fields,
                            boolean skipHeader,
                            boolean writeHeader,
                            String delimiter,
                            String quote,
                            Class[] types,
                            String filename,
                            SinkMode mode)
Specified by:
getDelimitedFile in class cascading.test.TestPlatform

getTemplateTap

public Tap getTemplateTap(Tap sink,
                          String pathTemplate,
                          int openThreshold)
Specified by:
getTemplateTap in class cascading.test.TestPlatform

getTemplateTap

public Tap getTemplateTap(Tap sink,
                          String pathTemplate,
                          Fields fields,
                          int openThreshold)
Specified by:
getTemplateTap in class cascading.test.TestPlatform


Copyright © 2007-2012 Concurrent, Inc. All Rights Reserved.