@Override public Object invoke(Object proxy, Method method, Object[] args) throws Throwable { try { Deadline.registerIfNot(socketTimeout); boolean isTimerStarted = Deadline.startTimer(method.getName()); try { return method.invoke(base, args); } finally { if (isTimerStarted) { Deadline.stopTimer(); } } } catch (UndeclaredThrowableException e) { throw e.getCause(); } catch (InvocationTargetException e) { throw e.getCause(); } }
ConfVars.CLIENT_SOCKET_TIMEOUT, TimeUnit.MILLISECONDS); Deadline.registerIfNot(timeout);
while (!isCachePrewarmed.get()) { Deadline.registerIfNot(1000000); Collection<String> catalogsToCache; try {
void update() { Deadline.registerIfNot(1000000); LOG.debug("CachedStore: updating cached objects"); try {
private static void dropAllStoreObjects(RawStore store) throws MetaException, InvalidObjectException, InvalidInputException { try { Deadline.registerIfNot(100000); Deadline.startTimer("getPartition"); List<String> dbs = store.getAllDatabases(DEFAULT_CATALOG_NAME); for (int i = 0; i < dbs.size(); i++) { String db = dbs.get(i); List<String> tbls = store.getAllTables(DEFAULT_CATALOG_NAME, db); for (String tbl : tbls) { List<Partition> parts = store.getPartitions(DEFAULT_CATALOG_NAME, db, tbl, 100); for (Partition part : parts) { store.dropPartition(DEFAULT_CATALOG_NAME, db, tbl, part.getValues()); } store.dropTable(DEFAULT_CATALOG_NAME, db, tbl); } store.dropDatabase(DEFAULT_CATALOG_NAME, db); } } catch (NoSuchObjectException e) { } }
@Override public void run() { Deadline.registerIfNot(timeout); try {
private static void dropAllStoreObjects(RawStore store) throws MetaException, InvalidObjectException, InvalidInputException { try { Deadline.registerIfNot(100000); List<Function> functions = store.getAllFunctions(DEFAULT_CATALOG_NAME); for (Function func : functions) {
@Override public Object invoke(final Object proxy, final Method method, final Object[] args) throws Throwable { Deadline.registerIfNot(timeout); try { Deadline.startTimer(method.getName()); final Object object = method.invoke(metacatHMSHandler, args); Deadline.stopTimer(); return object; } catch (InvocationTargetException e) { for (Throwable ex : Throwables.getCausalChain(e)) { if (ex instanceof JDODataStoreException) { throw ex; } } throw e.getCause(); } } }
@Override public Object invoke(final Object proxy, final Method method, final Object[] args) throws Throwable { Deadline.registerIfNot(timeout); try { Deadline.startTimer(method.getName()); final Object object = method.invoke(metacatHMSHandler, args); Deadline.stopTimer(); return object; } catch (InvocationTargetException e) { for (Throwable ex : Throwables.getCausalChain(e)) { if (ex instanceof JDODataStoreException) { throw ex; } } throw e.getCause(); } } }
@Override public Object invoke(Object proxy, Method method, Object[] args) throws Throwable { try { Deadline.registerIfNot(socketTimeout); boolean isTimerStarted = Deadline.startTimer(method.getName()); try { return method.invoke(base, args); } finally { if (isTimerStarted) { Deadline.stopTimer(); } } } catch (UndeclaredThrowableException e) { throw e.getCause(); } catch (InvocationTargetException e) { throw e.getCause(); } }
@Override public Object invoke(Object proxy, Method method, Object[] args) throws Throwable { Object ret = null; boolean isTimerStarted = false; try { try { if (!Deadline.isStarted()) { Deadline.startTimer(method.getName()); isTimerStarted = true; } } catch (MetaException e) { // Deadline was not registered yet. long timeout = HiveConf.getTimeVar(hiveConf, HiveConf.ConfVars.METASTORE_CLIENT_SOCKET_TIMEOUT, TimeUnit.MILLISECONDS); Deadline.registerIfNot(timeout); Deadline.startTimer(method.getName()); isTimerStarted = true; } ret = method.invoke(base, args); if (isTimerStarted) { Deadline.stopTimer(); } } catch (UndeclaredThrowableException e) { throw e.getCause(); } catch (InvocationTargetException e) { throw e.getCause(); } return ret; }
@Override public Object invoke(Object proxy, Method method, Object[] args) throws Throwable { Object ret = null; boolean isTimerStarted = false; try { try { if (!Deadline.isStarted()) { Deadline.startTimer(method.getName()); isTimerStarted = true; } } catch (MetaException e) { // Deadline was not registered yet. long timeout = HiveConf.getTimeVar(hiveConf, HiveConf.ConfVars.METASTORE_CLIENT_SOCKET_TIMEOUT, TimeUnit.MILLISECONDS); Deadline.registerIfNot(timeout); Deadline.startTimer(method.getName()); isTimerStarted = true; } ret = method.invoke(base, args); if (isTimerStarted) { Deadline.stopTimer(); } } catch (UndeclaredThrowableException e) { throw e.getCause(); } catch (InvocationTargetException e) { throw e.getCause(); } return ret; }
HiveConf.ConfVars.METASTORE_CLIENT_SOCKET_TIMEOUT, TimeUnit.MILLISECONDS); Deadline.registerIfNot(timeout);
HiveConf.ConfVars.METASTORE_CLIENT_SOCKET_TIMEOUT, TimeUnit.MILLISECONDS); Deadline.registerIfNot(timeout);
while (!isCachePrewarmed.get()) { Deadline.registerIfNot(1000000); Collection<String> catalogsToCache; try {
void update() { Deadline.registerIfNot(1000000); LOG.debug("CachedStore: updating cached objects"); try {