Skip to content

Commit

Permalink
pick up more litter
Browse files Browse the repository at this point in the history
  • Loading branch information
purplefox committed Mar 14, 2013
1 parent d61fe7b commit d02b6a7
Show file tree
Hide file tree
Showing 6 changed files with 5 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,6 @@ public void reportException(Throwable t) {
if (deploymentContext != null) {
deploymentContext.reportException(t);
} else {
t.printStackTrace();
log.error("context Unhandled exception", t);
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,6 @@ public void run() {
}
});
}

} else {
log.error("Unhandled exception", t);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@ public void run() {

@Override
public void exceptionCaught(ChannelHandlerContext chctx, final Throwable t) throws Exception {
t.printStackTrace();
final Channel ch = chctx.channel();
final C sock = connectionMap.remove(ch);
if (sock != null && t instanceof Exception) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,12 @@ public class CountServer extends Verticle {

public void start() {
tu = new TestUtils(vertx);

server = vertx.createHttpServer().requestHandler(new Handler<HttpServerRequest>() {
public void handle(final HttpServerRequest req) {
tu.checkThread();
req.response.headers().put("count", req.headers().get("count"));
String cnt = req.headers().get("count");
req.response.headers().put("count", cnt);
req.response.end();
}
}).listen(8080);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2167,13 +2167,14 @@ private void testPooling(final boolean keepAlive) throws Exception {
final int numGets = 1000;
int maxPoolSize = 10;
client.setKeepAlive(keepAlive).setMaxPoolSize(maxPoolSize);
final AtomicInteger cnt = new AtomicInteger(0);
for (int i = 0; i < numGets; i++) {
final int theCount = i;
HttpClientRequest req = client.get(path, new Handler<HttpClientResponse>() {
public void handle(final HttpClientResponse response) {
tu.azzert(response.statusCode == 200);
tu.azzert(theCount == Integer.parseInt(response.headers().get("count")));
if (theCount == numGets - 1) {
if (cnt.incrementAndGet() == numGets) {
tu.testComplete();
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1187,15 +1187,13 @@ public void handle(AsyncResult<Void> ar) {
}
});
} catch (Throwable t) {
t.printStackTrace();
vertx.reportException(t);
doUndeploy(deploymentName, new SimpleHandler() {
public void handle() {
aggHandler.done(false);
}
});
}

}
};

Expand Down

0 comments on commit d02b6a7

Please sign in to comment.