Added capability of sending a request without waiting for the response, to test async requests.
git-svn-id: svn+ssh://dev.eclipse.org/svnroot/rt/org.eclipse.jetty/jetty/trunk@832 7e9141cc-0065-0410-87d8-b60c137991c4
This commit is contained in:
parent
cbcbb96be1
commit
dc2a817cd1
|
@ -78,6 +78,12 @@ public class LocalConnector extends AbstractConnector
|
|||
return -1;
|
||||
}
|
||||
|
||||
public void executeRequest(String rawRequest) throws IOException
|
||||
{
|
||||
Request request = new Request(new ByteArrayBuffer(rawRequest, "UTF-8"), true, null);
|
||||
requests.add(request);
|
||||
}
|
||||
|
||||
private class Request implements Runnable
|
||||
{
|
||||
private final ByteArrayBuffer requestsBuffer;
|
||||
|
@ -115,7 +121,8 @@ public class LocalConnector extends AbstractConnector
|
|||
if (!leaveOpen)
|
||||
connectionClosed(connection);
|
||||
responsesBuffer = endPoint.getOut();
|
||||
latch.countDown();
|
||||
if (latch != null)
|
||||
latch.countDown();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue