From 0912a2a09acbf3df594e25bbf23706ea64a2acf3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Xavier=20L=C3=A9aut=C3=A9?= Date: Fri, 9 May 2014 22:44:04 -0700 Subject: [PATCH] use Guava's ForwardingExecutorService instead of DelegatingExecutorService --- .../query/DelegatingExecutorService.java | 127 ------------------ 1 file changed, 127 deletions(-) delete mode 100644 processing/src/main/java/io/druid/query/DelegatingExecutorService.java diff --git a/processing/src/main/java/io/druid/query/DelegatingExecutorService.java b/processing/src/main/java/io/druid/query/DelegatingExecutorService.java deleted file mode 100644 index 5a6be3f854c..00000000000 --- a/processing/src/main/java/io/druid/query/DelegatingExecutorService.java +++ /dev/null @@ -1,127 +0,0 @@ -/* - * Druid - a distributed column store. - * Copyright (C) 2012, 2013 Metamarkets Group Inc. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ - -package io.druid.query; - -import java.util.Collection; -import java.util.List; -import java.util.concurrent.Callable; -import java.util.concurrent.ExecutionException; -import java.util.concurrent.ExecutorService; -import java.util.concurrent.Future; -import java.util.concurrent.TimeUnit; -import java.util.concurrent.TimeoutException; - -/** - */ -public class DelegatingExecutorService implements ExecutorService -{ - private final ExecutorService delegate; - - public DelegatingExecutorService(ExecutorService delegate) - { - this.delegate = delegate; - } - - @Override - public void shutdown() - { - delegate.shutdown(); - } - - @Override - public List shutdownNow() - { - return delegate.shutdownNow(); - } - - @Override - public boolean isShutdown() - { - return delegate.isShutdown(); - } - - @Override - public boolean isTerminated() - { - return delegate.isTerminated(); - } - - @Override - public boolean awaitTermination(long l, TimeUnit timeUnit) throws InterruptedException - { - return delegate.awaitTermination(l, timeUnit); - } - - @Override - public Future submit(Callable tCallable) - { - return delegate.submit(tCallable); - } - - @Override - public Future submit(Runnable runnable, T t) - { - return delegate.submit(runnable, t); - } - - @Override - public Future submit(Runnable runnable) - { - return delegate.submit(runnable); - } - - @Override - public List> invokeAll(Collection> callables) throws InterruptedException - { - return delegate.invokeAll(callables); - } - - @Override - public List> invokeAll( - Collection> callables, - long l, - TimeUnit timeUnit - ) throws InterruptedException - { - return delegate.invokeAll(callables, l, timeUnit); - } - - @Override - public T invokeAny(Collection> callables) throws InterruptedException, ExecutionException - { - return delegate.invokeAny(callables); - } - - @Override - public T invokeAny( - Collection> callables, - long l, - TimeUnit timeUnit - ) throws InterruptedException, ExecutionException, TimeoutException - { - return delegate.invokeAny(callables, l, timeUnit); - } - - @Override - public void execute(Runnable runnable) - { - delegate.execute(runnable); - } -}