tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Warnken, Jens" <Jens.Warn...@IZB-SOFT.de>
Subject AW: Properties File URGENT!!!!
Date Mon, 17 Jul 2000 11:44:01 GMT
Hi John,

you did the right thing, getting the InputStream through
this.getClass().getResourceAsStream(INI_FILENAME);

By this, you only have to put the db.properties file in the folder, where
the class resides. So, yes, you have to put it in the WEB-INF\classes\...
folder, just in the same folder, where the class is, that reads the
property-file. The INI_FILENAME than just says 'db.properties'. You dont't
have to put any path-info in the INI_FILENAME.

Hope this helps. Greetings,

Jens Warnken

> ----------
> Von: 	John Cox[SMTP:johnedwardcox@yahoo.com]
> Antwort an: 	tomcat-user@jakarta.apache.org
> Gesendet: 	Montag, 17. Juli 2000 13:28
> An: 	tomcat-user@jakarta.apache.org
> Betreff: 	Properties File URGENT!!!!
> 
> Slight off topic but it really is important this
> gets sorted out - please indulge me...
> 
> I'm using a database management class in a webapp
> which needs to read a db.properties file via
> Class.getResourceAsStream()
> 
> Problem is, the class loader doesn't see it; I've
> tried putting it in every place I can think of that
> the classloader might search for it with no luck.
> 
> *Please* could someone suggest where it should go:
> in the WEB-INF\classes folder or what??
> 
> TIA
> 
> __________________________________________________
> Do You Yahoo!?
> Get Yahoo! Mail - Free email you can access from anywhere!
> http://mail.yahoo.com/
> 

Mime
View raw message