private static RecordWriter<Writable, Writable>
createProtoWriter(Class<?> protoClass, final File file)
throws IOException, InterruptedException {
OutputFormat outputFormat = (
new RCFileProtobufOutputFormat(Protobufs.getTypeRef(protoClass.getName())) {
@Override
public Path getDefaultWorkFile(TaskAttemptContext context,
String extension) throws IOException {
return new Path(file.toURI().toString());
}