title: Howto access properties file from Java EE web application?
body: <p>I have created a dynamic web project within Eclipse. I created a properties file inside the src directory:</p>
  
  <pre><code>&lt;project-root&gt;/src/props.properties
  </code></pre>
  
  <p>I'm starting Tomcat via Eclipse in debug mode. Now I want to read the properties file from one of my POJOs, but I get a FileNotFoundException. The current path seems to be the Eclipse path. </p>
  
  <p>I had a look into the web for solution, but none of them worked for me. Maybe I did something wrong. The code is like this:</p>
  
  <pre><code>File file = new File("props.properties");
  FileReader reader = new FileReader(file);
  properties.load(reader);
  </code></pre>
  
  <p>How should I acces the properties file?
  Where should it be located?</p>
  
  <p>Thanks in advance.</p>