I have a JSP/Servlet project and I would like to access a .json or a .xml file from one of my servlets. But where do I place those files?
I can access
String filename = "/WEB-INF/myFile.xml";
But how about the following:
filename ="/WEB-INF/resources/myFile.xml";
? How do I get the file from /resources?
ServletContext context = getServletContext();
InputStream is = context.getResourceAsStream(filename);
Where do I save files, that I want deployed and accessable from my servlets with my application to tomcat/webapps?