String rootPath = ContextLoader.getCurrentWebApplicationContext().getServletContext().getRealPath("/");
private HttpServletRequest getRequest() {
return ((ServletRequestAttributes) RequestContextHolder.currentRequestAttributes()).getRequest();
}