nasty growth of job queue testing
git-svn-id: svn+ssh://dev.eclipse.org/svnroot/rt/org.eclipse.jetty/jetty/trunk@420 7e9141cc-0065-0410-87d8-b60c137991c4
This commit is contained in:
parent
46cc510966
commit
2cb525bbf2
|
@ -34,6 +34,7 @@ import junit.framework.TestCase;
|
||||||
import org.eclipse.jetty.server.bio.SocketConnector;
|
import org.eclipse.jetty.server.bio.SocketConnector;
|
||||||
import org.eclipse.jetty.server.handler.HandlerWrapper;
|
import org.eclipse.jetty.server.handler.HandlerWrapper;
|
||||||
import org.eclipse.jetty.server.nio.SelectChannelConnector;
|
import org.eclipse.jetty.server.nio.SelectChannelConnector;
|
||||||
|
import org.eclipse.jetty.util.BlockingArrayQueue;
|
||||||
import org.eclipse.jetty.util.IO;
|
import org.eclipse.jetty.util.IO;
|
||||||
import org.eclipse.jetty.util.log.Log;
|
import org.eclipse.jetty.util.log.Log;
|
||||||
import org.eclipse.jetty.util.thread.QueuedThreadPool;
|
import org.eclipse.jetty.util.thread.QueuedThreadPool;
|
||||||
|
@ -48,7 +49,7 @@ public class StressTest extends TestCase
|
||||||
protected InetAddress _addr;
|
protected InetAddress _addr;
|
||||||
protected int _port;
|
protected int _port;
|
||||||
protected volatile AtomicInteger[] _loops;
|
protected volatile AtomicInteger[] _loops;
|
||||||
protected QueuedThreadPool _threads=new QueuedThreadPool();
|
protected QueuedThreadPool _threads=new QueuedThreadPool(new BlockingArrayQueue<Runnable>(4,4));
|
||||||
// protected ExecutorThreadPool _threads=new ExecutorThreadPool(100,500,10000,TimeUnit.MILLISECONDS);
|
// protected ExecutorThreadPool _threads=new ExecutorThreadPool(100,500,10000,TimeUnit.MILLISECONDS);
|
||||||
protected boolean _stress;
|
protected boolean _stress;
|
||||||
private AtomicInteger _handled=new AtomicInteger(0);
|
private AtomicInteger _handled=new AtomicInteger(0);
|
||||||
|
|
Loading…
Reference in New Issue