Following best practices, I\'m using Thread.currentThread().getContextClassLoader().getResourceAsStream
to load resources in a web application (like text files or x
In addition to kschneid's answer which might work for Tomcat indeed, I wanted to add that for JBoss AS 5+ it already seems to work without needing any special tricks.
Caching of resources is probably class loader specific. The JBoss AS one either doesn't cache or is smart enough to see that the resource on disk has changed.