httpServerFilter, connection, request, HttpHandler.this);
service(request, response);
return !suspendStatus.getAndInvalidate();
} else {
final FilterChainContext ctx = request.getContext();
ctx.suspend();
threadPool.execute(new Runnable() {
@Override
public void run() {
final SuspendStatus suspendStatus = response.initSuspendStatus();
boolean wasSuspended;
try {
HttpServerProbeNotifier.notifyBeforeService(
httpServerFilter, connection, request,
HttpHandler.this);
service(request, response);
wasSuspended = suspendStatus.getAndInvalidate();
} catch (Exception e) {
LOGGER.log(Level.FINE, "service exception", e);
if (!response.isCommitted()) {
response.reset();
try {
HtmlHelper.setErrorAndSendErrorPage(
request, response,
response.getErrorPageGenerator(),
500, HttpStatus.INTERNAL_SERVER_ERROR_500.getReasonPhrase(),
HttpStatus.INTERNAL_SERVER_ERROR_500.getReasonPhrase(),
e);
} catch (IOException ignored) {
}
}
wasSuspended = false;
}
if (!wasSuspended) {
ctx.resume();
}
}
});
return false;