0

我有一些设置代码进入 Hive UDF 构造函数。代码在每个被调用以运行 map/reduce 作业的 TaskTracker 上运行。这工作正常。但是在 UDF 抽象类中没有定义 tearDown()/close() 类型的方法。关于如何实现该功能的任何建议?

4

1 回答 1

0

Hive 版本 11 GenericUDF 现在具有我正在寻找的内容:

  /**
   * Close GenericUDF.
   * This is only called in runtime of MapRedTask.
   */
  public void close() throws IOException {
  }
于 2014-01-29T16:00:33.473 回答