diff --git a/ethereumj-core/pom.xml b/ethereumj-core/pom.xml index 82b7acf4..575c6e64 100644 --- a/ethereumj-core/pom.xml +++ b/ethereumj-core/pom.xml @@ -10,7 +10,7 @@ diff --git a/ethereumj-core/src/main/java/org/ethereum/net/peerdiscovery/PeerDiscovery.java b/ethereumj-core/src/main/java/org/ethereum/net/peerdiscovery/PeerDiscovery.java index 6b8979c2..b48826b8 100644 --- a/ethereumj-core/src/main/java/org/ethereum/net/peerdiscovery/PeerDiscovery.java +++ b/ethereumj-core/src/main/java/org/ethereum/net/peerdiscovery/PeerDiscovery.java @@ -1,10 +1,7 @@ package org.ethereum.net.peerdiscovery; -import org.ethereum.manager.MainData; import org.ethereum.net.client.PeerData; -import samples.threadpool.MyMonitorThread; -import samples.threadpool.RejectedExecutionHandlerImpl; import java.util.List; import java.util.concurrent.*; diff --git a/ethereumj-core/src/main/java/org/ethereum/net/peerdiscovery/PeerTaster.java b/ethereumj-core/src/main/java/org/ethereum/net/peerdiscovery/PeerTaster.java index a21a54f3..11e1e097 100644 --- a/ethereumj-core/src/main/java/org/ethereum/net/peerdiscovery/PeerTaster.java +++ b/ethereumj-core/src/main/java/org/ethereum/net/peerdiscovery/PeerTaster.java @@ -9,10 +9,6 @@ import org.ethereum.gui.PeerListener; import org.ethereum.manager.MainData; import org.ethereum.net.client.EthereumFrameDecoder; import org.ethereum.net.client.PeerData; - -import java.net.Inet4Address; -import java.net.InetAddress; -import java.net.UnknownHostException; import java.util.ArrayList; diff --git a/ethereumj-core/src/main/java/org/ethereum/net/peerdiscovery/RejectedExecutionHandlerImpl.java b/ethereumj-core/src/main/java/org/ethereum/net/peerdiscovery/RejectedExecutionHandlerImpl.java new file mode 100644 index 00000000..27ddfeb2 --- /dev/null +++ b/ethereumj-core/src/main/java/org/ethereum/net/peerdiscovery/RejectedExecutionHandlerImpl.java @@ -0,0 +1,17 @@ +package org.ethereum.net.peerdiscovery; + +import java.util.concurrent.RejectedExecutionHandler; +import java.util.concurrent.ThreadPoolExecutor; + +/** + * www.ethereumJ.com + * User: Roman Mandeleil + * Created on: 22/05/2014 10:31 + */ + +public class RejectedExecutionHandlerImpl implements RejectedExecutionHandler { + @Override + public void rejectedExecution(Runnable r, ThreadPoolExecutor executor) { + System.out.println(r.toString() + " is rejected"); + } +} diff --git a/ethereumj-core/src/main/java/org/ethereum/net/peerdiscovery/WorkerThread.java b/ethereumj-core/src/main/java/org/ethereum/net/peerdiscovery/WorkerThread.java index f3310922..a1368cf0 100644 --- a/ethereumj-core/src/main/java/org/ethereum/net/peerdiscovery/WorkerThread.java +++ b/ethereumj-core/src/main/java/org/ethereum/net/peerdiscovery/WorkerThread.java @@ -1,6 +1,5 @@ package org.ethereum.net.peerdiscovery; -import org.ethereum.manager.MainData; import org.ethereum.net.client.PeerData; import java.util.concurrent.ThreadPoolExecutor;