T
- The input type of this sourcepublic class DataBaseSource<T extends org.apache.hadoop.mapreduce.lib.db.DBWritable & org.apache.hadoop.io.Writable>
extends org.apache.crunch.io.impl.FileSourceImpl<T>
DBInputFormat
.
A type that is input via this class must be a Writable that also implements
DBWritable. On the DBWritable.readFields(java.sql.ResultSet)
method
needs to be fully implemented form DBWritable
.
Modifier and Type | Class and Description |
---|---|
static class |
DataBaseSource.Builder<T extends org.apache.hadoop.mapreduce.lib.db.DBWritable & org.apache.hadoop.io.Writable> |
Modifier and Type | Method and Description |
---|---|
long |
getLastModifiedAt(org.apache.hadoop.conf.Configuration configuration)
Returns the time (in milliseconds) that this
Source was most recently
modified (e.g., because an input file was edited or new files were added to
a directory.) |
long |
getSize(org.apache.hadoop.conf.Configuration configuration)
Returns the number of bytes in this
Source . |
public long getSize(org.apache.hadoop.conf.Configuration configuration)
Source
Source
.public long getLastModifiedAt(org.apache.hadoop.conf.Configuration configuration)
Source
Source
was most recently
modified (e.g., because an input file was edited or new files were added to
a directory.)getLastModifiedAt
in interface Source<T extends org.apache.hadoop.mapreduce.lib.db.DBWritable & org.apache.hadoop.io.Writable>
getLastModifiedAt
in class org.apache.crunch.io.impl.FileSourceImpl<T extends org.apache.hadoop.mapreduce.lib.db.DBWritable & org.apache.hadoop.io.Writable>
Copyright © 2016 The Apache Software Foundation. All rights reserved.