## org.apache.cassandra.hadoop
Class ConfigHelper

    java.lang.Object
      org.apache.cassandra.hadoop.ConfigHelper

    public class ConfigHelper

extends java.lang.Object

Constructor Summary
`ConfigHelper()`

Method Summary
`static java.lang.String` `getColumnFamily(org.apache.hadoop.conf.Configuration conf)`
`static java.lang.String` `getInitialAddress(org.apache.hadoop.conf.Configuration conf)`
`static int` `getInputSplitSize(org.apache.hadoop.conf.Configuration conf)`
`static java.lang.String` `getKeyspace(org.apache.hadoop.conf.Configuration conf)`
`static int` `getRangeBatchSize(org.apache.hadoop.conf.Configuration conf)` The number of rows to request with each get range slices request.
`static SlicePredicate` `getSlicePredicate(org.apache.hadoop.conf.Configuration conf)`
`static int` `getThriftPort(org.apache.hadoop.conf.Configuration conf)`
`static void` `setColumnFamily(org.apache.hadoop.conf.Configuration conf, java.lang.String keyspace, java.lang.String columnFamily)` Set the keyspace and column family for this job.
`static void` `setInputSplitSize(org.apache.hadoop.conf.Configuration conf, int splitsize)` Set the size of the input split.
`static void` `setRangeBatchSize(org.apache.hadoop.conf.Configuration conf, int batchsize)` The number of rows to request with each get range slices request.
`static void` `setSlicePredicate(org.apache.hadoop.conf.Configuration conf, SlicePredicate predicate)` Set the predicate that determines what columns will be selected from each row.
`static void` `setThriftContact(org.apache.hadoop.conf.Configuration conf, java.lang.String address, int port)` The address and port of a Cassandra node that Hadoop can contact over Thrift to learn more about the Cassandra cluster.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### ConfigHelper

    public ConfigHelper()

Method Detail

### setColumnFamily

    public static void setColumnFamily(org.apache.hadoop.conf.Configuration conf,
                                       java.lang.String keyspace,
                                       java.lang.String columnFamily)

  Set the keyspace and column family for this job. Comparator and Partitioner types will be read from storage-conf.xml.

  Parameters:
    `conf` - Job configuration you are about to run
    `keyspace` -
    `columnFamily` -

### setThriftContact

    public static void setThriftContact(org.apache.hadoop.conf.Configuration conf,
                                        java.lang.String address,
                                        int port)

  The address and port of a Cassandra node that Hadoop can contact over Thrift to learn more about the Cassandra cluster. Optional when storage-conf.xml is provided.

  Parameters:
    `conf` -
    `address` -
    `port` -

### setRangeBatchSize

    public static void setRangeBatchSize(org.apache.hadoop.conf.Configuration conf,
                                         int batchsize)

  The number of rows to request with each get range slices request. Too big and you can either get timeouts when it takes Cassandra too long to fetch all the data. Too small and the performance will be eaten up by the overhead of each request.

  Parameters:
    `conf` - Job configuration you are about to run
    `batchsize` - Number of rows to request each time

### getRangeBatchSize

    public static int getRangeBatchSize(org.apache.hadoop.conf.Configuration conf)

  The number of rows to request with each get range slices request. Too big and you can either get timeouts when it takes Cassandra too long to fetch all the data. Too small and the performance will be eaten up by the overhead of each request.

  Parameters:
    `conf` - Job configuration you are about to run
  Returns:
    Number of rows to request each time

### setInputSplitSize

    public static void setInputSplitSize(org.apache.hadoop.conf.Configuration conf,
                                         int splitsize)

  Set the size of the input split. This affects the number of maps created, if the number is too small the overhead of each map will take up the bulk of the job time.

  Parameters:
    `conf` - Job configuration you are about to run
    `splitsize` - Size of the input split

### getInputSplitSize

    public static int getInputSplitSize(org.apache.hadoop.conf.Configuration conf)

### setSlicePredicate

    public static void setSlicePredicate(org.apache.hadoop.conf.Configuration conf,
                                         SlicePredicate predicate)

  Set the predicate that determines what columns will be selected from each row.

  Parameters:
    `conf` - Job configuration you are about to run
    `predicate` -

### getSlicePredicate

    public static SlicePredicate getSlicePredicate(org.apache.hadoop.conf.Configuration conf)

### getKeyspace

    public static java.lang.String getKeyspace(org.apache.hadoop.conf.Configuration conf)

### getColumnFamily

    public static java.lang.String getColumnFamily(org.apache.hadoop.conf.Configuration conf)

### getThriftPort

    public static int getThriftPort(org.apache.hadoop.conf.Configuration conf)

### getInitialAddress

    public static java.lang.String getInitialAddress(org.apache.hadoop.conf.Configuration conf)

Copyright © 2010 The Apache Software Foundation