title: JBoss External Properties Files in Classpath
body: <p>I was going through <a href="https://developer.jboss.org/wiki/HowToPutAnExternalFileInTheClasspath" rel="nofollow">JBoss.org</a> how to put external file in the classpath, but it doesn't work. </p>
  
  <p>I have 1 file with name "config.properties". It is placed in jboss/modules/com/xsiraul/test/main/ folder. In the same folder there is module.xml which looks like -  </p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;  
  &lt;module xmlns="urn:jboss:module:1.1" name="com.xsiraul.test"&gt;  
      &lt;resources&gt;  
          &lt;resource-root path="."/&gt;  
      &lt;/resources&gt;  
  &lt;/module&gt;  
  </code></pre>
  
  <p>I have load <code>config.properties</code> file from Java using - </p>
  
  <pre><code>InputStream settingsStream = getClass().getClassLoader().getResourceAsStream("config.properties");  
  </code></pre>
  
  <p>Java class is in package named com.xsiraul.test</p>
  
  <p>The problem is that method <code>getResourceAsStream</code> returns NULL and I don't understand why. Maybe somebody has any ideas?</p>
  
  <p>I use <code>JBoss</code> <code>EAP</code> 6.1.0.GA version. </p>