title: Problem retrieving properties file from webapp in tomcat
body: <p>I've developed a web application that worked fine in JBoss 4. Now, I need to make it work in Tomcat 6, but I'm having trouble to access some properties file. I use the following code to read read these files:</p>
  
  <pre><code>InputStream is = Thread.currentThread().getContextClassLoader()
                  .getResourceAsStream(fileName);
  if (is == null) {
      throw new StartupError("Error loading " + fileName);
  }
  
  properties.load(is);
  </code></pre>
  
  <p>As I've said before, it works fine in JBoss 4. But when I deploy my app in tomcat, it doesn't find the file, assigning null to 'is' variable, causing the StartupError to be thrown. The file is located at WEB-INF/config directory, and the webapp is deployed as a war.</p>
  
  <p>Any solution for this problem?</p>
  
  <p>Thanks,
  Alexandre</p>