AvroImportMapper.java 文件源码

java
阅读 18 收藏 0 点赞 0 评论 0

项目:aliyun-maxcompute-data-collectors 作者:
@Override
protected void map(LongWritable key, SqoopRecord val, Context context)
    throws IOException, InterruptedException {

  try {
    // Loading of LOBs was delayed until we have a Context.
    val.loadLargeObjects(lobLoader);
  } catch (SQLException sqlE) {
    throw new IOException(sqlE);
  }

  GenericRecord outKey = AvroUtil.toGenericRecord(val.getFieldMap(),
      schema, bigDecimalFormatString);
  wrapper.datum(outKey);
  context.write(wrapper, NullWritable.get());
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号