if (null != fileLocation) {
File file = new File(fileLocation, localResourcePath);
log.debug("trying to find {} ({})", file.getAbsolutePath(), file.exists());
if (file.exists()) {
log.debug("found {} ({})", file.getAbsolutePath(), file.exists());
resource = file.toURI().toURL();
}
}
if (resource == null) {
resource = getServletContext().getResource(localResourcePath);