List of usage examples for org.apache.hadoop.mapreduce.lib.db DBConfiguration getInputClass
public Class<?> getInputClass()
From source file:com.cloudera.sqoop.mapreduce.db.OracleDataDrivenDBInputFormat.java
License:Apache License
@Override protected RecordReader<LongWritable, T> createDBRecordReader(DBInputSplit split, Configuration conf) throws IOException { DBConfiguration dbConf = getDBConf(); @SuppressWarnings("unchecked") Class<T> inputClass = (Class<T>) (dbConf.getInputClass()); try {//from w w w. ja v a 2 s . co m // Use Oracle-specific db reader return new OracleDataDrivenDBRecordReader<T>(split, inputClass, conf, getConnection(), dbConf, dbConf.getInputConditions(), dbConf.getInputFieldNames(), dbConf.getInputTableName()); } catch (SQLException ex) { throw new IOException(ex.getMessage()); } }