//response.setStatus(HttpServletResponse.SC_OK);
}catch(IOException e) {
log.error("Exception during upload: " + e.getMessage(), e);
//response.setStatus(HttpServletResponse.SC_INTERNAL_SERVER_ERROR);
//response.getWriter().print("{ \"success\": false }");
tracker.getQueue().queueCommand(CommandType.EXCEPTION, null, null, new ExceptionDetails(e.getClass().getName(), e.getMessage()));
}
response.setStatus(HttpServletResponse.SC_OK);
if (tracker.hasDataToFlush())
tracker.getObjectMapper().writeValue(response.getWriter(), tracker.getQueue());
}