org.apache.hadoop.hive.metastore.api.Function.setCreateTime()方法的使用及代码示例

x33g5p2x  于2022-01-19 转载在 其他  
字(3.4k)|赞(0)|评价(0)|浏览(165)

本文整理了Java中org.apache.hadoop.hive.metastore.api.Function.setCreateTime()方法的一些代码示例,展示了Function.setCreateTime()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Function.setCreateTime()方法的具体详情如下:
包路径:org.apache.hadoop.hive.metastore.api.Function
类名称:Function
方法名:setCreateTime

Function.setCreateTime介绍

暂无

代码示例

代码示例来源:origin: apache/hive

func.setCreateTime((int) time);
ms.createFunction(func);
if (!transactionalListeners.isEmpty()) {

代码示例来源:origin: apache/hive

unsetCreateTime();
} else {
 setCreateTime((Integer)value);

代码示例来源:origin: apache/hive

newFunction.setCreateTime(alteredFunction.getCreateTime());
Assert.assertEquals("Comparing functions", newFunction, alteredFunction);
try {
newFunction.setCreateTime(alteredFunction.getCreateTime());
Assert.assertEquals("Comparing functions", newFunction, alteredFunction);
try {

代码示例来源:origin: apache/hive

function.setCreateTime(createdFunction.getCreateTime());
Assert.assertEquals("Comparing functions", function, createdFunction);

代码示例来源:origin: apache/hive

function.getFunctionName());
function.setCreateTime(createdFunction.getCreateTime());
Assert.assertEquals("Comparing functions", function, createdFunction);
client.dropFunction(function.getDbName(), function.getFunctionName());

代码示例来源:origin: org.apache.hive/hive-standalone-metastore

func.setCreateTime((int) time);
ms.createFunction(func);
if (!transactionalListeners.isEmpty()) {

代码示例来源:origin: com.facebook.presto.hive/hive-apache

@Override
public void create_function(Function func) throws AlreadyExistsException,
  InvalidObjectException, MetaException, NoSuchObjectException,
  TException {
 validateFunctionInfo(func);
 boolean success = false;
 RawStore ms = getMS();
 try {
  ms.openTransaction();
  Database db = ms.getDatabase(func.getDbName());
  if (db == null) {
   throw new NoSuchObjectException("The database " + func.getDbName() + " does not exist");
  }
  Function existingFunc = ms.getFunction(func.getDbName(), func.getFunctionName());
  if (existingFunc != null) {
   throw new AlreadyExistsException(
     "Function " + func.getFunctionName() + " already exists");
  }
  // set create time
  long time = System.currentTimeMillis() / 1000;
  func.setCreateTime((int) time);
  ms.createFunction(func);
  success = ms.commitTransaction();
 } finally {
  if (!success) {
   ms.rollbackTransaction();
  }
 }
}

代码示例来源:origin: org.spark-project.hive/hive-metastore

@Override
public void create_function(Function func) throws AlreadyExistsException,
  InvalidObjectException, MetaException, NoSuchObjectException,
  TException {
 validateFunctionInfo(func);
 boolean success = false;
 RawStore ms = getMS();
 try {
  ms.openTransaction();
  Database db = ms.getDatabase(func.getDbName());
  if (db == null) {
   throw new NoSuchObjectException("The database " + func.getDbName() + " does not exist");
  }
  Function existingFunc = ms.getFunction(func.getDbName(), func.getFunctionName());
  if (existingFunc != null) {
   throw new AlreadyExistsException(
     "Function " + func.getFunctionName() + " already exists");
  }
  // set create time
  long time = System.currentTimeMillis() / 1000;
  func.setCreateTime((int) time);
  ms.createFunction(func);
  success = ms.commitTransaction();
 } finally {
  if (!success) {
   ms.rollbackTransaction();
  }
 }
}

代码示例来源:origin: com.facebook.presto.hive/hive-apache

unsetCreateTime();
} else {
 setCreateTime((Integer)value);

代码示例来源:origin: org.spark-project.hive/hive-metastore

unsetCreateTime();
} else {
 setCreateTime((Integer)value);

代码示例来源:origin: org.apache.hive/hive-standalone-metastore

unsetCreateTime();
} else {
 setCreateTime((Integer)value);

相关文章