Re: Load properties file from Tomcat directory

2013-01-25 Thread Konstantin Kolinko
2013/1/25 Justin Rosenberg : > Is there a to load a properties file that is dropped in the > ${catalina.base}/lib directory? > > > > When I try the following it returns null: > > MyClass.class.getResourceAsStream(PROPERTY_FILE_NAME) You should beware of the difference between Class.getResource()

Load properties file from Tomcat directory

2013-01-24 Thread Justin Rosenberg
Is there a to load a properties file that is dropped in the ${catalina.base}/lib directory? When I try the following it returns null: MyClass.class.getResourceAsStream(PROPERTY_FILE_NAME) I realize I can do the following, but I don't want the code to be server specific: props.load(new Fi