tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alan Tingley - Iperia" <ating...@iperia.com>
Subject Re: Loading properties files
Date Tue, 27 Aug 2002 12:25:37 GMT
try http://jakarta.apache.org/tomcat/tomcat-4.1-doc/class-loader-howto.html
Al

----- Original Message -----
From: "Laurent Michenaud" <lmichenaud@adeuza.fr>
To: "Tomcat Users List" <tomcat-user@jakarta.apache.org>
Cc: <atingley@iperia.com>
Sent: Tuesday, August 27, 2002 7:09 AM
Subject: RE: Loading properties files


I can't find the documentation u speak about.

Could u give me the url ?

> -----Message d'origine-----
> De : Alan Tingley - Iperia [mailto:atingley@iperia.com]
> Envoyé : mardi 27 août 2002 12:15
> À : Tomcat Users List
> Objet : Re: Loading properties files
>
>
> Your properties file must be in a location that Tomcat knows
> about via its
> classpath (WEB-INF/classes is on Tomcat's classpath, that's
> why it worked
> when your file was there).  See the Tomcat docs under
> "Classpath How-to",
> which describes the class loaders in Tomcat.
> Alan Tingley
>
> ----- Original Message -----
> From: "Laurent Michenaud" <lmichenaud@adeuza.fr>
> To: <tomcat-user@jakarta.apache.org>
> Sent: Tuesday, August 27, 2002 4:40 AM
> Subject: Loading properties files
>
>
> Hi,
>
> Could u tell me what is not correct with that :
>
> Before we had that ( the properties files were in
> WEB-INF/classes ) and
> that works :
>
> package com.a2a.util ;
> public interface A2aConstantes
> {
>   public static final String SCHEMA =
> java.util.ResourceBundle.getBundle("db").getString("schema");
> }
>
>
> Now we want to have properties files in WEB-INF/config so we change
> the file like this :
>
> package com.a2a.util ;
> public interface A2aConstantes
> {
>   public static final String SCHEMA =
> java.util.ResourceBundle.getBundle("/WEB-INF/config/db").getSt
> ring("sche
> ma");
> }
>
> But it doesnot work, it can't find the db.properties. I have
> tried with
> "WEB-INF/config/db" and "/WEB-INF/config/db.properties" but
> it doesnot work too.
>
> Can u tell me what's wrong ?
>
>
>
>
> Michenaud Laurent
> - Adeuza -
> [ Développeur Web - Administrateur Réseau ]
>
>
> --
> To unsubscribe, e-mail:
> <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
> <mailto:tomcat-user-help@jakarta.apache.org>
>
>
>
> --
> To unsubscribe, e-mail:
> <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
> <mailto:tomcat-user-help@jakarta.apache.org>
>
>



--
To unsubscribe, e-mail:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:tomcat-user-help@jakarta.apache.org>


Mime
View raw message