I have a GWT application and I load a .json file on the server side like this:
InputStream source = new FileInputStream(testFile.json);
This works perfectly when I start the application directly in eclipse. However, when I deploy the app on tomcat, it does not work. It seems like, that the application is looking for that file in the bin folder of tomcat (???). However, the correct path would be tomcat/webapps/myProject/testFile.json.
Does anyone know how to get the correct path (without harcoding it)?