Skip to content

Commit 4a2f3f8

Browse files
committed
HBASE-24788 : TableOutputFormat source compatibility (ADDENDUM)
Brought back InterruptedException in throws clause of getRecordWriter and checkOutputSpecs of TableOutputFormat
1 parent 11cfb0f commit 4a2f3f8

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

hbase-mapreduce/src/main/java/org/apache/hadoop/hbase/mapreduce/TableOutputFormat.java

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -155,10 +155,11 @@ public void write(KEY key, Mutation value)
155155
* @param context The current task context.
156156
* @return The newly created writer instance.
157157
* @throws IOException When creating the writer fails.
158+
* @throws InterruptedException When the job is cancelled.
158159
*/
159160
@Override
160161
public RecordWriter<KEY, Mutation> getRecordWriter(TaskAttemptContext context)
161-
throws IOException {
162+
throws IOException, InterruptedException {
162163
return new TableRecordWriter();
163164
}
164165

@@ -167,11 +168,11 @@ public RecordWriter<KEY, Mutation> getRecordWriter(TaskAttemptContext context)
167168
*
168169
* @param context The current context.
169170
* @throws IOException When the check fails.
171+
* @throws InterruptedException When the job is aborted.
170172
* @see OutputFormat#checkOutputSpecs(JobContext)
171173
*/
172174
@Override
173-
public void checkOutputSpecs(JobContext context)
174-
throws IOException {
175+
public void checkOutputSpecs(JobContext context) throws IOException, InterruptedException {
175176
Configuration hConf = getConf();
176177
if (hConf == null) {
177178
hConf = context.getConfiguration();

0 commit comments

Comments
 (0)