MAPREDUCE-7368. DBOutputFormat.DBRecordWriter#write must throw exception when it fails. (#3671). Contributed by Stamatis Zampetakis.

Signed-off-by: Ayush Saxena <ayushsaxena@apache.org>
This commit is contained in:
Stamatis Zampetakis 2021-12-08 12:10:11 +01:00 committed by GitHub
parent 25849ff7b7
commit bface2ac6c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -122,7 +122,7 @@ public void write(K key, V value) throws IOException {
key.write(statement);
statement.addBatch();
} catch (SQLException e) {
e.printStackTrace();
throw new IOException("Failed to execute SQL statement for key " + key, e);
}
}
}