code: private final boolean filteringResources(Response response, final String path) throws IOException {
          String translated = translateResource(path);
          if (translated != null) {
              
              // Setting default headers for static files
              // One week - Google recommendation
              // https://developers.google.com/speed/docs/insights/LeverageBrowserCaching
              response.header(HttpHeaders.CACHE_CONTROL, "public, max-age=604800");
              File file = new File(injector.getInstance(DeploymentInfo.class).getRealPath(translated));
              if (file.canRead())
                  response.header(HttpHeaders.ETAG, String.valueOf(file.lastModified()));
              
              if (translated.endsWith(".css"))
                  response.header(HttpHeaders.CONTENT_TYPE, "text/css");
              else if (translated.endsWith(".js"))
                  response.header(HttpHeaders.CONTENT_TYPE, "text/javascript");
              else if (translated.endsWith(".webm"))
                  response.header(HttpHeaders.CONTENT_TYPE, "video/webm");
              else if (translated.endsWith(".mp4"))
                  response.header(HttpHeaders.CONTENT_TYPE, "video/mp4");
              else if (translated.endsWith(".svg")) {
                  response.header(HttpHeaders.CONTENT_TYPE, "image/svg+xml");
                  response.header("mime-type","image/svg+xml");
                  response.header(HttpHeaders.CONTENT_DISPOSITION, "");
              }
              
              //try (FileInputStream fis = new FileInputStream(file)) {
              try {
                  response.send(new FileInputStream(file)); // gets closed by the response
                  response.end();
              } catch (Exception e) {
                  // TODO Auto-generated catch block
                  e.printStackTrace();
              }
              return true;
          }
          return false;
      }
docs: TODO extract to an independent Filter