public void close() { try { elems.close(); } catch (HiveException e) { LOG.error(e.toString(), e); } }
public void close() { try { elems.close(); } catch (HiveException e) { LOG.error(e.toString(), e); } }
@Override public HiveMetaHook getHook(Table tbl) throws MetaException { if (tbl == null) { return null; } try { HiveStorageHandler storageHandler = HiveUtils.getStorageHandler(hiveConf, tbl.getParameters().get(META_TABLE_STORAGE)); return storageHandler == null ? null : storageHandler.getMetaHook(); } catch (HiveException e) { LOG.error(e.toString()); throw new MetaException("Failed to get storage handler: " + e); } } };
private int createTemporaryFunction(CreateFunctionDesc createFunctionDesc) { try { // Add any required resources FunctionResource[] resources = toFunctionResource(createFunctionDesc.getResources()); addFunctionResources(resources); Class<?> udfClass = getUdfClass(createFunctionDesc); FunctionInfo registered = FunctionRegistry.registerTemporaryUDF( createFunctionDesc.getFunctionName(), udfClass, resources); if (registered != null) { return 0; } console.printError("FAILED: Class " + createFunctionDesc.getClassName() + " does not implement UDF, GenericUDF, or UDAF"); return 1; } catch (HiveException e) { console.printError("FAILED: " + e.toString()); LOG.info("create function: ", e); return 1; } catch (ClassNotFoundException e) { console.printError("FAILED: Class " + createFunctionDesc.getClassName() + " not found"); LOG.info("create function: ", e); return 1; } }
private int createTemporaryFunction(CreateFunctionDesc createFunctionDesc) { try { // Add any required resources FunctionResource[] resources = toFunctionResource(createFunctionDesc.getResources()); addFunctionResources(resources); Class<?> udfClass = getUdfClass(createFunctionDesc); FunctionInfo registered = FunctionRegistry.registerTemporaryUDF( createFunctionDesc.getFunctionName(), udfClass, resources); if (registered != null) { return 0; } console.printError("FAILED: Class " + createFunctionDesc.getClassName() + " does not implement UDF, GenericUDF, or UDAF"); return 1; } catch (HiveException e) { console.printError("FAILED: " + e.toString()); LOG.info("create function: " + StringUtils.stringifyException(e)); return 1; } catch (ClassNotFoundException e) { console.printError("FAILED: Class " + createFunctionDesc.getClassName() + " not found"); LOG.info("create function: " + StringUtils.stringifyException(e)); return 1; } }
throw e; console.printError(ErrorMsg.STATS_SKIPPING_BY_ERROR.getErrorCodedMsg(e.toString()));
throw e; console.printError(ErrorMsg.STATS_SKIPPING_BY_ERROR.getErrorCodedMsg(e.toString()));
public void close() { try { elems.close(); } catch (HiveException e) { LOG.error(e.toString(), e); } }
@Override public HiveMetaHook getHook(Table tbl) throws MetaException { if (tbl == null) { return null; } try { HiveStorageHandler storageHandler = HiveUtils.getStorageHandler(hiveConf, tbl.getParameters().get(META_TABLE_STORAGE)); return storageHandler == null ? null : storageHandler.getMetaHook(); } catch (HiveException e) { LOG.error(e.toString()); throw new MetaException("Failed to get storage handler: " + e); } } };
@Override public HiveMetaHook getHook(Table tbl) throws MetaException { if (tbl == null) { return null; } try { HiveStorageHandler storageHandler = HiveUtils.getStorageHandler(hiveConf, tbl.getParameters().get(META_TABLE_STORAGE)); return storageHandler == null ? null : storageHandler.getMetaHook(); } catch (HiveException e) { LOG.error(e.toString()); throw new MetaException("Failed to get storage handler: " + e); } } };
private int createTemporaryFunction(CreateFunctionDesc createFunctionDesc) { try { // Add any required resources FunctionResource[] resources = toFunctionResource(createFunctionDesc.getResources()); addFunctionResources(resources); Class<?> udfClass = getUdfClass(createFunctionDesc); FunctionInfo registered = FunctionRegistry.registerTemporaryUDF( createFunctionDesc.getFunctionName(), udfClass, resources); if (registered != null) { return 0; } console.printError("FAILED: Class " + createFunctionDesc.getClassName() + " does not implement UDF, GenericUDF, or UDAF"); return 1; } catch (HiveException e) { console.printError("FAILED: " + e.toString()); LOG.info("create function: " + StringUtils.stringifyException(e)); return 1; } catch (ClassNotFoundException e) { console.printError("FAILED: Class " + createFunctionDesc.getClassName() + " not found"); LOG.info("create function: " + StringUtils.stringifyException(e)); return 1; } }
throw e; console.printError(ErrorMsg.STATS_SKIPPING_BY_ERROR.getErrorCodedMsg(e.toString()));