Package org.apache.hadoop.mapred.lib.db.DBInputFormat

Examples of org.apache.hadoop.mapred.lib.db.DBInputFormat.DBRecordReader.createValue()


    DBRecordReader reader = new DBInputFormat<NullDBWritable>().new DBRecordReader(
        new DBInputSplit(),  NullDBWritable.class, job,
        DriverForTest.getConnection(), dbConfig, "condition", fields, "table");
    LongWritable key = reader.createKey();
    assertEquals(0, key.get());
    DBWritable value = reader.createValue();
    assertEquals(
        "org.apache.hadoop.mapred.lib.db.DBInputFormat$NullDBWritable", value
            .getClass().getName());
    assertEquals(0, reader.getPos());
    assertFalse(reader.next(key, value));
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.