ConfigHelper (apache-cassandra API)
Date: 2012-05-04

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## 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 Cassandra.Client` | `createConnection(java.lang.String host, java.lang.Integer port, boolean framed)`
`static Cassandra.Client` | `getClientFromAddressList(org.apache.hadoop.conf.Configuration conf)`
`static java.lang.String` | `getInitialAddress(org.apache.hadoop.conf.Configuration conf)`
`static java.lang.String` | `getInputColumnFamily(org.apache.hadoop.conf.Configuration conf)`
`static KeyRange` | `getInputKeyRange(org.apache.hadoop.conf.Configuration conf)` may be null if unset
`static java.lang.String` | `getInputKeyspace(org.apache.hadoop.conf.Configuration conf)`
`static java.lang.String` | `getInputKeyspacePassword(org.apache.hadoop.conf.Configuration conf)`
`static java.lang.String` | `getInputKeyspaceUserName(org.apache.hadoop.conf.Configuration conf)`
`static SlicePredicate` | `getInputSlicePredicate(org.apache.hadoop.conf.Configuration conf)`
`static int` | `getInputSplitSize(org.apache.hadoop.conf.Configuration conf)`
`static java.lang.String` | `getOutputColumnFamily(org.apache.hadoop.conf.Configuration conf)`
`static java.lang.String` | `getOutputKeyspace(org.apache.hadoop.conf.Configuration conf)`
`static java.lang.String` | `getOutputKeyspacePassword(org.apache.hadoop.conf.Configuration conf)`
`static java.lang.String` | `getOutputKeyspaceUserName(org.apache.hadoop.conf.Configuration conf)`
`static IPartitioner` | `getPartitioner(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 java.lang.String` | `getRawInputSlicePredicate(org.apache.hadoop.conf.Configuration conf)`
`static java.lang.String` | `getReadConsistencyLevel(org.apache.hadoop.conf.Configuration conf)`
`static int` | `getRpcPort(org.apache.hadoop.conf.Configuration conf)`
`static java.lang.String` | `getWriteConsistencyLevel(org.apache.hadoop.conf.Configuration conf)`
`static void` | `setInitialAddress(org.apache.hadoop.conf.Configuration conf, java.lang.String address)`
`static void` | `setInputColumnFamily(org.apache.hadoop.conf.Configuration conf, java.lang.String keyspace, java.lang.String columnFamily)` Set the keyspace and column family for the input of this job.
`static void` | `setInputRange(org.apache.hadoop.conf.Configuration conf, java.lang.String startToken, java.lang.String endToken)` Set the KeyRange to limit the rows.
`static void` | `setInputSlicePredicate(org.apache.hadoop.conf.Configuration conf, SlicePredicate predicate)` Set the predicate that determines what columns will be selected from each row.
`static void` | `setInputSplitSize(org.apache.hadoop.conf.Configuration conf, int splitsize)` Set the size of the input split.
`static void` | `setOutputColumnFamily(org.apache.hadoop.conf.Configuration conf, java.lang.String keyspace, java.lang.String columnFamily)` Set the keyspace and column family for the output of this job.
`static void` | `setPartitioner(org.apache.hadoop.conf.Configuration conf, java.lang.String classname)`
`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` | `setRpcPort(org.apache.hadoop.conf.Configuration conf, java.lang.String port)`

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

### setInputColumnFamily

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

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

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

### setOutputColumnFamily

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

  Set the keyspace and column family for the output of this job.

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

### 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)

### setInputSlicePredicate

    public static void setInputSlicePredicate(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` -

### getInputSlicePredicate

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

### getRawInputSlicePredicate

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

### setInputRange

    public static void setInputRange(org.apache.hadoop.conf.Configuration conf,
                                     java.lang.String startToken,
                                     java.lang.String endToken)

  Set the KeyRange to limit the rows.

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

### getInputKeyRange

    public static KeyRange getInputKeyRange(org.apache.hadoop.conf.Configuration conf)

  may be null if unset

### getInputKeyspace

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

### getOutputKeyspace

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

### getInputKeyspaceUserName

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

### getInputKeyspacePassword

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

### getOutputKeyspaceUserName

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

### getOutputKeyspacePassword

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

### getInputColumnFamily

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

### getOutputColumnFamily

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

### getReadConsistencyLevel

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

### getWriteConsistencyLevel

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

### getRpcPort

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

### setRpcPort

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

### getInitialAddress

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

### setInitialAddress

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

### setPartitioner

    public static void setPartitioner(org.apache.hadoop.conf.Configuration conf,
                                      java.lang.String classname)

### getPartitioner

    public static IPartitioner getPartitioner(org.apache.hadoop.conf.Configuration conf)

### getClientFromAddressList

    public static Cassandra.Client getClientFromAddressList(org.apache.hadoop.conf.Configuration conf)
                                                     throws java.io.IOException

  Throws:
    `java.io.IOException`

### createConnection

    public static Cassandra.Client createConnection(java.lang.String host,
                                                    java.lang.Integer port,
                                                    boolean framed)
                                             throws java.io.IOException

  Throws:
    `java.io.IOException`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2012 The Apache Software Foundation