Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GORA-613 Remove deprecated usages in gora-core module #164

Merged
merged 1 commit into from
May 2, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ protected void reduce(Text key, Iterable<WebPage> values, Context context)
*/
public Job createJob(DataStore<String, WebPage> inStore, Query<String, WebPage> query
, DataStore<String, WebPage> outStore) throws IOException {
Job job = new Job(getConf());
Job job = Job.getInstance(getConf());

job.setJobName("Check serialization of dirty bits");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ public Query<K, T> getQuery(DataStore<K,T> dataStore) {
* @throws IOException
*/
public Job createJob(Query<K,T> query) throws IOException {
Job job = new Job(getConf());
Job job = Job.getInstance(getConf());

job.setJobName("QueryCounter");
job.setNumReduceTasks(0);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ protected void reduce(Text key, Iterable<IntWritable> values, Context context)
*/
public Job createJob(Query<String,WebPage> query
, DataStore<String,TokenDatum> outStore) throws IOException {
Job job = new Job(getConf());
Job job = Job.getInstance(getConf());

job.setJobName("WordCount");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ public DataSource<Tuple2<KeyIn, ValueIn>> createDataSource(ExecutionEnvironment
throws IOException {
Preconditions.checkNotNull(classKeyIn);
Preconditions.checkNotNull(classValueIn);
Job job = new Job(conf);
Job job = Job.getInstance(conf);
DataStore<KeyIn, ValueIn> dataStore = DataStoreFactory.getDataStore(dataStoreClass
, classKeyIn, classValueIn, job.getConfiguration());
GoraInputFormat.setInput(job, dataStore.newQuery(), true);
Expand All @@ -86,7 +86,7 @@ public DataSource<Tuple2<KeyIn, ValueIn>> createDataSource(ExecutionEnvironment
throws IOException {
Preconditions.checkNotNull(classKeyIn);
Preconditions.checkNotNull(classValueIn);
Job job = new Job(conf);
Job job = Job.getInstance(conf);
GoraInputFormat.setInput(job, dataStore.newQuery(), true);
HadoopInputFormat<KeyIn, ValueIn> wrappedGoraInput =
new HadoopInputFormat<>(new GoraInputFormat<>(),
Expand All @@ -99,7 +99,7 @@ public OutputFormat<Tuple2<KeyOut, ValueOut>> createDataSink(Configuration conf,
throws IOException {
Preconditions.checkNotNull(classKeyOut);
Preconditions.checkNotNull(classValueOut);
Job job = new Job(conf);
Job job = Job.getInstance(conf);
GoraOutputFormat.setOutput(job, dataStore, true);
HadoopOutputFormat<KeyOut, ValueOut> wrappedGoraOutput =
new HadoopOutputFormat<>(
Expand All @@ -116,7 +116,7 @@ public OutputFormat<Tuple2<KeyOut, ValueOut>> createDataSink(Configuration conf,
throws IOException {
Preconditions.checkNotNull(classKeyOut);
Preconditions.checkNotNull(classValueOut);
Job job = new Job(conf);
Job job = Job.getInstance(conf);
DataStore<KeyOut, ValueOut> dataStore = DataStoreFactory.getDataStore(dataStoreClass
, classKeyOut, classValueOut, job.getConfiguration());
GoraOutputFormat.setOutput(job, dataStore, true);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,6 @@ public class NullOutputCommitter extends OutputCommitter {
public void abortTask(TaskAttemptContext arg0) throws IOException {
}

@Override
public void cleanupJob(JobContext arg0) throws IOException {
}

@Override
public void commitTask(TaskAttemptContext arg0) throws IOException {
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -339,7 +339,7 @@ public void testNewVersionBehavior() throws IOException {
.newBuilder(Bytes.toBytes("test-family"));
columnDescBuilder.setNewVersionBehavior(true);
ColumnFamilyDescriptor columnDescriptor = columnDescBuilder.build();
tableDescBuilder.addColumnFamily(columnDescriptor);
tableDescBuilder.setColumnFamily(columnDescriptor);
TableDescriptor tableDescriptor = tableDescBuilder.build();

conn.getAdmin().createTable(tableDescriptor);
Expand Down