Thank you Tim.
Nate
--- Tim Funk <[EMAIL PROTECTED]> wrote:
> correct.
>
> -Tim
>
>
> Nathan Hook wrote:
>
> > Greetings,
> >
> > Does Tomcat itself ever use either the
> > workers.properties or the worker2.properties
> files?
correct.
-Tim
Nathan Hook wrote:
Greetings,
Does Tomcat itself ever use either the
workers.properties or the worker2.properties files?
My understanding is that these files are just example
property files for the Apache2 mod_jk(2) modules and
that Tomcat itself never references these files
Greetings,
Does Tomcat itself ever use either the
workers.properties or the worker2.properties files?
My understanding is that these files are just example
property files for the Apache2 mod_jk(2) modules and
that Tomcat itself never references these files? Is
this true?
Thank you for your
n the /WEB-INF/classes/ directory. Not sure yet about
the /WEB-INF/lib/ directory.
Am I doing something wrong? Is there a different command? After I "deploy"
I tried "reload"ing. Same result.
Seems like the only way to get Tomcat to reload things like .properties
files is to res
Ralf,
I have a properties file in my jar and put in under
Tomcat/webapps/opencms/WEB-INF/lib/mystuff.jar
Inside the jar the properties file is under /res/myconfig.properties.
OpenCms is a servlet in tomcat, depoyed and working. I think this question is
generally enough to be allowed to ask here in
Hi,
I have a properties file in my jar and put in under
Tomcat/webapps/opencms/WEB-INF/lib/mystuff.jar
Inside the jar the properties file is under /res/myconfig.properties.
OpenCms is a servlet in tomcat, depoyed and working. I think this question is
generally enough to be allowed to ask here in t
> -Original Message-
> From: Shapira, Yoav [mailto:[EMAIL PROTECTED]
> Sent: Friday, September 19, 2003 9:14 AM
> To: [EMAIL PROTECTED]
> Subject: RE: Where should I put properties files
>
>
>
> Don't do this in the constructor of your servlet, as it's
;To: Tomcat Users List; [EMAIL PROTECTED]
>Subject: Re: Where should I put properties files
>
>Configuration files are a problem area in Java, particularly J2EE. You
>can:
>1. Use a Preferences object (although I personally have found this
quite
>painful - you need to provide a UI to
Configuration files are a problem area in Java, particularly J2EE. You can:
1. Use a Preferences object (although I personally have found this quite
painful - you need to provide a UI to set up and administer your preferences
and system preferences require admin privileges on Windows).
2. Put your
ailto:[EMAIL PROTECTED]
> Sent: Thursday, September 18, 2003 2:53 PM
> To: [EMAIL PROTECTED]; Tomcat Users List
> Subject: RE: Where should I put properties files
>
>
>
> Howdy,
>
> >I hate to be totally ignorant, but I can't seem to discover how my
> >web s
Howdy,
>I hate to be totally ignorant, but I can't seem to discover how my
>web service class gets access to ServletContext. I'm sure there's
>some static method in Axis that I can call, but I've just been rooting
>around in the source for about two hours, to no avail.
It depends what your web
> -Original Message-
> From: Shapira, Yoav [mailto:[EMAIL PROTECTED]
> Sent: Thursday, September 18, 2003 11:09 AM
> To: Tomcat Users List; [EMAIL PROTECTED]
> Subject: RE: Where should I put properties files
>
>
>
> Howdy,
> This is a FAQ, you could r
letContext#getResource or ServletContext#getResourceAsStream.
Yoav Shapira
Millennium ChemInformatics
>-Original Message-
>From: Michael D. Spence [mailto:[EMAIL PROTECTED]
>Sent: Thursday, September 18, 2003 10:57 AM
>To: [EMAIL PROTECTED]
>Subject: Where should I put propert
I have a web service (call it XYZ) which requires a .properties file. I had
been putting it in
%CATALINA_HOME%\webapps\axis\services\XYZ, with the classes in
%CATALINA_HOME%\webapps\axis\services\WEB_INF\classes and using this to
open the properties file.
File PFile = new File("webapps" + Fil
I have a web service (call it XYZ) which requires a .properties file. I had
been putting it in
%CATALINA_HOME%\webapps\axis\services\XYZ, with the classes in
%CATALINA_HOME%\webapps\axis\services\WEB_INF\classes and using this to
open the properties file.
File PFile = new File("webapps" + Fil
try /properties/framework.properties ?
> -Original Message-
> From: Shailesh Modi [mailto:[EMAIL PROTECTED]
> Sent: Monday, September 08, 2003 12:11 AM
> To: 'Tomcat Users List'
> Subject: RE: Deployment problems in tomcat 4.1.27 : jdbc and
> properties fi
3 11:28 AM
To: Tomcat Users List; [EMAIL PROTECTED]
Subject: Re[2]: Deployment problems in tomcat 4.1.27 : jdbc and
properties files
Hello Shailesh!
SM> properties files(configuration files) for my web-app are not getting
SM> picked up. I have tried following ways one by one:
SM> 1. ke
Hello Shailesh!
SM> properties files(configuration files) for my web-app are not getting
SM> picked up. I have tried following ways one by one:
SM> 1. kept them in \WEB-INF\classes folder
the right move
SM> 2. kept them in \WEB-INF\lib
won't work, it's for jars only
SM&g
Hi James,
It is classes.jar and now it is being picked up when i kept it in
\common\lib directory.
But properties files(configuration files) for my web-app are not getting
picked up.
I have tried following ways one by one:
1. kept them in \WEB-INF\classes folder
2. kept them in \WEB-INF\lib
tomcat 4
directory(C:\jakarta-tomcat-4.1.27\common\lib or
C:\jakarta-tomcat-4.1.27\server\lib), but no help.
Also keeping properties files into my web-app's WEB-INF/classes directory
too not able to help me out.
Alternatively, I have tried giving relative path (eg
"/WEB-INF/
Hi,
I have kept classes12.jar in every possible places in tomcat 4
directory(C:\jakarta-tomcat-4.1.27\common\lib or
C:\jakarta-tomcat-4.1.27\server\lib), but no help.
Also keeping properties files into my web-app's WEB-INF/classes directory
too not able to help me out.
Alternatively, I
Hi All,
I had successfully configured TC 5 + Apache 2 using mod_jk2 on
Win2k.
But I couldn't found any documentation about the details of files
workers2.properties and jk2.properties.
Can some one help me out on this, by providing some info about all
the options and their meaning which we can
properties files that the Web application must be aware of to run properly.
Given the above choice of deployment, how should I go about ensuring that the
application loads in
these properties files? Is this possible?
Thanks
Jorge Castro
Howdy,
>I'm expecting that when I go to load the properties, it will look in
>WEB-INF/classes *first*, from this snip from the CLASSLOADER doc
>
>Therefore, from the perspective of a web application, class or resource
>loading lo
Hello,
So I'm writing a few library classes that I hope I'll be able to use
over and over again. Because goodness knows, someone needs to invent the
wheel again. ;)
Anyways.. I want my classes to use properties files for configuration,
and what I really want is something like:
1.
t;To: [EMAIL PROTECTED]
>Subject: RE: placement of properties files
>
>I did that for a while but changed when teting them became difficult.
>
>By putting them in the classpath, you can test without any
>monkey-business (tech. term) to get the ServletContext, and the class
>that gets
I did that for a while but changed when teting them became difficult.
By putting them in the classpath, you can test without any
monkey-business (tech. term) to get the ServletContext, and the class
that gets the config is also not coupled to servlets, so I can use it
for a swing app, or command
Howdy,
>Good options all. I was leaning towards /WEB-INF/. I like Yoav's
>suggestion for the more pure organizational aspect. However, could one
>also just:
>
>InputStream is = ServletContext.getResourceAsStream(
"/WEB-INF/a.props"); ?
One could, sure. And if you have a small system / few file
To: 'Tomcat Users List'
Subject: RE: placement of properties files
I'd recommend WEB-INF/classes - then it's in the classpath.
-Original Message-
From: Schwartz, David (CHR) [mailto:[EMAIL PROTECTED]
Sent: Wednesday, May 28, 2003 6:57 AM
To: 'Tomcat Users List'
Subject:
dnesday, May 28, 2003 9:02 AM
>To: 'Tomcat Users List'
>Subject: RE: placement of properties files
>
>I'd recommend WEB-INF/classes - then it's in the classpath.
>
>-Original Message-
>From: Schwartz, David (CHR) [mailto:[EMAIL PROTECTED]
>Se
I'd recommend WEB-INF/classes - then it's in the classpath.
-Original Message-
From: Schwartz, David (CHR) [mailto:[EMAIL PROTECTED]
Sent: Wednesday, May 28, 2003 6:57 AM
To: 'Tomcat Users List'
Subject: RE: placement of properties files
I think web-inf folder - sin
I think web-inf folder - since tomcat wont serve files contained therein.
-Original Message-
From: Timothy Stone [mailto:[EMAIL PROTECTED]
Sent: Wednesday, May 28, 2003 8:55 AM
To: Tomcat Users
Subject: placement of properties files
Q: where is the proper place for [props].properties
Q: where is the proper place for [props].properties files? such as
something that might store username and password pairs. Not the best
practice, but if one wanted to.
Thanks,
Tim
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For
Erik Price wrote:
However, it must be possible because I believe log4j uses properties
files from JAR files in webapps. So, you might want to ask around there
or check the log4j source code. Please let us know what you find!
Responding to my own post, I took a look at the Log4J source and
at this requires you to know the absolute path to
the JAR file, which I do not know if it is possible for a webapp to give
you the absolute path.
However, it must be possible because I believe log4j uses properties
files from JAR files in webapps. So, you might want to ask around there
or ch
Users List
Assunto: Re: R: properties files
Simone Chiaretta wrote:
> I store properties in my the app WEB-INF/web.xml
>
>
> smtpServer
> my.smtpserver.net
> SMTP server to be used to send email from forms in the
> website
>
Simone Chiaretta wrote:
I store properties in my the app WEB-INF/web.xml
smtpServer
my.smtpserver.net
SMTP server to be used to send email from forms in the
website
and I access the value also in JSP pages with
String value = ge
On Feb 25, Arnaud HERITIER had something to say about RE: properties files
>You need to put your property files in WEB-INF/classes or in a jar in
>WEB-INF/lib
This will lock you into the current Tomcat incarnation, though. The WAR
format does not say anything about exploding the archive
aud
-Message d'origine-
De : José Moreira [mailto:[EMAIL PROTECTED]
Envoyé : mardi 25 février 2003 13:36
À : Tomcat Users List
Objet : properties files
Hello, im using a propeties file to store and retrieve
application settings
(like db conection) using this code :
private Properties
yep, that will work because due to my inexperience im having a lot trouble
working with files ...
ill go try web.xml
-Mensagem original-
De: Simone Chiaretta [mailto:[EMAIL PROTECTED]
Enviada: terça-feira, 25 de Fevereiro de 2003 14:36
Para: Tomcat Users List
Assunto: R: properties files
--
> Da: José Moreira [mailto:[EMAIL PROTECTED]
> Inviato: martedì 25 febbraio 2003 15.25
> A: Tomcat Users List; [EMAIL PROTECTED]
> Oggetto: RE: properties files
>
>
> thank you for the attention, im developing a bean to
> interact with the
> properties file.
>
:)
-Mensagem original-
De: Arnaud HERITIER [mailto:[EMAIL PROTECTED]
Enviada: terça-feira, 25 de Fevereiro de 2003 12:51
Para: 'Tomcat Users List'
Assunto: RE: properties files
You need to put your property files in WEB-INF/classes or in a jar in
WEB-INF/lib
Then you c
; De : José Moreira [mailto:[EMAIL PROTECTED]
> Envoyé : mardi 25 février 2003 13:36
> À : Tomcat Users List
> Objet : properties files
>
>
> Hello, im using a propeties file to store and retrieve
> application settings
> (like db conection) using this code :
>
> priva
sers List
> Oggetto: properties files
>
>
> Hello, im using a propeties file to store and retrieve
> application settings
> (like db conection) using this code :
>
> private Properties properties;
>
> private String status;
>
> private boolean NovoCon
Hello, im using a propeties file to store and retrieve application settings
(like db conection) using this code :
private Properties properties;
private String status;
private boolean NovoConfig;
/** Creates new ConfigReaderBean */
public ConfigReaderBean() {
Proper
On Wed, 4 Dec 2002, micael wrote:
> Date: Wed, 04 Dec 2002 17:13:16 -0800
> From: micael <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: Tomcat Users List <[EMAIL PROTECTED]>
> Subject: RE: Loading Properties Files
>
>
A .war file is just a wrapper for a web application. I think he does not
know what one is. It is like a .zip or a .jar file. Do you know that?
At 06:56 PM 12/4/2002 -0600, you wrote:
No, that's not true at all.
The examples already given will find properties files for you just fine
wh
No, that's not true at all.
The examples already given will find properties files for you just fine
whether the file is in a directory structure or inside an archive. How do
you think Java loads classes? It works out of archives, no?
here are some various was to access a properties
If you're using the ClassLoader to locate your properties files, then the
properties files need to be within your classpath. For WARs, the only places
that you really have much control over is the 'classes' directory.
The other issue is that your can not assume that you will be a
If I understand you correctly, the properties file CANNOT be in the war
file, it needs to be external. Right.
> -Original Message-
> From: micael [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, December 04, 2002 3:25 PM
> To: Tomcat Users List
> Subject: RE: Loading P
Depends upon what you want to do with the properties files and how you
access them. Some ways of accessing them require that the name to access
be relative to the classpath, others don't. You are better off to learn
about properties files in this instance. There is nothing peculiar t
And if you have a .war file? Then where would you put your properties
files?
> -Original Message-
> From: Roberto Bouza [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, December 04, 2002 2:49 PM
> To: Tomcat Users List
> Subject: Re: Loading Properties Files
>
&g
Thats right.
If you don't have a .war file, you can use the classes dir inside your WEB-INF
dir, and create a new directory like "conf", the put inside all the properties
files. In that way the ClassLoader looks for the files in there when you use
something like thi
> From: <[EMAIL PROTECTED]>
> Subject: Loading Properties Files
> My problem is that the class cannot location my properties file. I am
> unable to
> use other suggested methods that I have noticed on this list since those
> problems
> involved Properties File with
Hello All:
I have a handful of classes, some static, that contain commonly used
functionality
that my web applications are using. Now, I am adding in a new static method
which
will require the Class to load a properties file within the Static
Initializer.
My problem is that the class cannot locat
e file properties "db" in WEB-INF/config ?
>
>
>>-Message d'origine-
>>De : Glenn Nielsen [mailto:[EMAIL PROTECTED]]
>>Envoyé : mardi 27 août 2002 15:32
>>À : Tomcat Users List
>>Objet : Re: Loading properties files
>>
>>
>>j
On Tue, 27 Aug 2002, Laurent Michenaud wrote:
> Date: Tue, 27 Aug 2002 15:43:29 +0200
> From: Laurent Michenaud <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: Tomcat Users List <[EMAIL PROTECTED]>
> Cc: [EMAIL PROTECTED]
> S
ldn't have).
Al
- Original Message -
From: "randie ursal" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>
Sent: Tuesday, August 27, 2002 7:05 AM
Subject: Re: Loading properties files
why is it tomcat could not locate the property file if
So, how can i modify my interface so that it reads
the file properties "db" in WEB-INF/config ?
> -Message d'origine-
> De : Glenn Nielsen [mailto:[EMAIL PROTECTED]]
> Envoyé : mardi 27 août 2002 15:32
> À : Tomcat Users List
> Objet
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" <[EMAIL PROTECTED]>
>> To: <[EMAIL
: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:[EMAIL PROTECTED]]
> Envoyé : mardi 27 août 2002 12:15
> À : Tomcat Users List
> Objet :
http://jakarta.apache.org/tomcat/tomcat-4.1-doc/class-loader-howto.html
- Original Message -
From: "Laurent Michenaud" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Tuesday, August 27, 2002 1:09 PM
Subje
I can't find the documentation u speak about.
Could u give me the url ?
> -Message d'origine-
> De : Alan Tingley - Iperia [mailto:[EMAIL PROTECTED]]
> Envoyé : mardi 27 août 2002 12:15
> À : Tomcat Users List
> Objet : Re: Loading properties files
>
>
loaders in Tomcat.
>Alan Tingley
>
>- Original Message -
>From: "Laurent Michenaud" <[EMAIL PROTECTED]>
>To: <[EMAIL PROTECTED]>
>Sent: Tuesday, August 27, 2002 4:40 AM
>Subject: Loading properties files
>
>
>Hi,
>
>Could u tell me what is no
gley
- Original Message -
From: "Laurent Michenaud" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
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 file
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").getStri
elow webapps but above WEB-INF.
> -Original Message-
> From: Xiao, Wei [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, March 26, 2002 12:55 PM
> To: Tomcat Users List
> Subject: RE: Properties files.
>
>
> I just removed "/" in front of the properties files. I eve
I just removed "/" in front of the properties files. I even checked
index$jsp.java file. But I am still getting the same exception.
Wei
-Original Message-
From: David Burns [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, March 26, 2002 3:49 PM
To: Tomcat Users List
Subject: Re:
; at java.util.Properties.load(Properties.java:176)
> at org.apache.jsp.index$jsp._jspService(index$jsp.java:66)
>
> Thank you.
>
> Wei
>
> -Original Message-
> From: David Burns [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, March 26, 2002 3:06 PM
> To: Tomcat U
.index$jsp._jspService(index$jsp.java:66)
Thank you.
Wei
-Original Message-
From: Mauricio Nuñez [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, March 26, 2002 3:01 PM
To: Tomcat Users List; Xiao, Wei; [EMAIL PROTECTED]
Subject: Re: Properties files.
Hi
try this:
jar cvf properties.jar *.
al Message-
From: David Burns [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, March 26, 2002 3:06 PM
To: Tomcat Users List
Subject: Re: Properties files.
I load application property files off the classpath and was able to load
property files from mywebapp/WEB-INF/classes directory. Had a little
trouble
.
-- David.
On Tuesday 26 March 2002 02:56 pm, you wrote:
> Hi all,
>
> I was trying to migrating an existing application to Tomcat 4.0. We used a
> lot of properties files and just specified the directory in classpath, then
> we can call
> load("/abc.properties"). W
Hi
try this:
jar cvf properties.jar *.properties
move properties.jar to WEB-INF/lib
and restart!
bye
El Martes 26 Marzo 2002 15:56, Xiao, Wei escribió:
> Hi all,
>
> I was trying to migrating an existing application to Tomcat 4.0. We used a
> lot of properties files and just s
Hi all,
I was trying to migrating an existing application to Tomcat 4.0. We used a
lot of properties files and just specified the directory in classpath, then
we can call
load("/abc.properties"). Where should I put properties files (*.properties)
in tomcat? How should I call to load i
>
>
> >
> > In tomcat 4.0b6 on Win2000 I'm using properties files that are in a jar
> > file in WEB-INF/lib.
> >
>
>This is equivalent to putting them unpacked under WEB-INF/classes. The
>key issue is that the package naming hierarchy has to match t
On Wed, 1 Aug 2001, Jim Cheesman wrote:
> At 10:56 PM 31/07/01, you wrote:
>
> >Where does tomcat expect to find the *.properties files. I've got a class
> >that fails with it's ResourceBundle call to a properties file. I've tried
> >it in the WEB-INF
At 10:56 PM 31/07/01, you wrote:
>Where does tomcat expect to find the *.properties files. I've got a class
>that fails with it's ResourceBundle call to a properties file. I've tried
>it in the WEB-INF and WEB-INF/classes directories for the specific web app.
In tom
UNSUBSCRIBE!!!
-Ursprüngliche Nachricht-
Von: Jay Wright [mailto:[EMAIL PROTECTED]]
Gesendet: Dienstag, 31. Juli 2001 22:57
An: '[EMAIL PROTECTED]'
Betreff: *.properties files
Where does tomcat expect to find the *.properties files. I've got a class
that
Where does tomcat expect to find the *.properties files. I've got a class
that fails with it's ResourceBundle call to a properties file. I've tried
it in the WEB-INF and WEB-INF/classes directories for the specific web app.
I have tomcat running as a standalone server o
, May 22, 2001 8:36 PM
To: [EMAIL PROTECTED]
Subject: Re: Context loading of .properties files
Here is another way to thinkabout it...
Create a config table in your database that holds all the properties you
need to run your app.
One record for each context - the key will be the different URL each
t: Context
loading of .properties files
I
have several contexts which use a ".properties" file for configuration.
I need each context to have its own version of that configuration file.
Is there a way to load properties files based on context? I am looking
for a way to load prop
22, 2001 3:33 PM
To: '[EMAIL PROTECTED]'
Subject: Context loading of .properties files
I have several contexts which use a ".properties" file for configuration. I
need each context to have its own version of that configuration file. Is
there a way to load properties files based
properties
and go from there. Keep everything in the database.
Bryan
[EMAIL PROTECTED] wrote:
>
> I have several contexts which use a ".properties" file for configuration. I
> need each context to have its own version of that configuration file. Is
> there a way to
I have
several contexts which use a ".properties" file for configuration. I need
each context to have its own version of that configuration file. Is there
a way to load properties files based on context? I am looking for a way to
load properties files that is similar to the wa
Over the past few months we've been converting a considerable number of
Web applications from Servlet 2.0 (JServ type) to Servlet 2.2 (Tomcat
style). One of the major chores in doing this has been converting
Servlet zone properties files into web.xml format, and so of course
we've
4.0 world?
thanx,
JP
- Original Message -
From: "Craig R. McClanahan" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Saturday, March 31, 2001 8:59 PM
Subject: Re: getResourceAsStream - properties files
>
>
> On Sat, 31 Mar 2001, Java Poop wrote:
>
&g
March 31, 2001 8:59 PM
Subject: Re: getResourceAsStream - properties files
>
>
> On Sat, 31 Mar 2001, Java Poop wrote:
>
> >
> > InputStream stream =
> > this.getClass().getResourceAsStream("testApp.properties");
> >
>
> This is supposed to work
On Sat, 31 Mar 2001, Java Poop wrote:
> Hey guys-
>
> I'm trying to figure out way to separate my initialization parameters
> from my application.war file. Because certain things are different
> between dev, qa and live machines (such as database hostname,
> username, password, etcs), I rather
Hey guys-
I'm trying to figure out way to separate my
initialization parameters from my application.war file. Because certain things
are different between dev, qa and live machines (such as database hostname,
username, password, etcs), I rather not put these values in the web.xml file.
(Th
>What deployment tool are you using to create the war file ?
Jar-Tool from JDK 1.3
Michael Specht
T-Systems
debis Systemhaus Dienstleistungen GmbH, BU CRM Nord
Hausanschrift: Frankfurter Straße 27, 65760 Eschborn
Telefon: (0 61 96) 9 61 - 575
Telefax: (0 61 96) 9 61 - 564
Mobiltelefon: (0171)
What deployment tool are you using to create the war file ?
-Original Message-
From: Michael Specht [mailto:[EMAIL PROTECTED]]
Sent: Monday, February 26, 2001 12:47 PM
To: [EMAIL PROTECTED]
Subject: Where to place .properties-Files when deploying a .war ?
Importance: High
Hello
Hello,
where i have to place the .properties-Files, when deploying an application as an
.war-File?
I tried several locations:
- in root of war-File
- in the WEB-INF/lib-directory
- in the WEB-INF/classes directory
- in the root of the web-apps/ dir
and ...
I always get the Message
properties files
Hi, I've been having problem to use *.properties files.
I'm running Slackware 7.1 (Linux), Tomcat 3.x, JDK 1.2.2, Apache 1.3.12
/www/index.jsp
/www/db.properties
/www/servlets/test.class
/www/servlets/db.properties
Also tried:
/www/WEB-INF/lib/db.properties
/www/ME
Hi, I've been having problem to use *.properties files.
I'm running Slackware 7.1 (Linux), Tomcat 3.x, JDK 1.2.2, Apache 1.3.12
/www/index.jsp
/www/db.properties
/www/servlets/test.class
/www/servlets/db.properties
Also tried:
/www/WEB-INF/lib/db.properties
/www/META-INF/db.properties
ties file like this :
>
> Properties.class.getResourceAsStream("my.properties");
>
> This function should find the properties files when it's in the CLASSPATH.
>
> I have putted the properties file in the WEB-APPS dir ...
>
> anyone ?
>
> thanks ...Christoph
>
>
roperties");
>
> This function should find the properties files when it's in the CLASSPATH.
>
> I have putted the properties file in the WEB-APPS dir ...
>
> anyone ?
>
> thanks ...Christoph
>
>
Christoph Rooms wrote:
> Hi Greg,
>
> You can use the CLASSPATH to load properties files ...
>
> Properties p = new Properties();
> java.io.InputStream is;
>
> is = getClass().getResourceAsStream("rnb.properties");
> if (is == null)
> throw
Hi Greg,
You can use the CLASSPATH to load properties files ...
Properties p = new Properties();
java.io.InputStream is;
is = getClass().getResourceAsStream("rnb.properties");
if (is == null)
throw new Exception("Properties file not found");
p.load(is);
This
using
FileInputStream is the way to go. For general purpose properties file usage,
I reccommend you stay with getResourceAsStream. It makes it easy to switch
the properties files you use by just changing the classpath a little bit.
And it allows you to have defaults buried deep in the class path whic
ream.close();
try this, URL should point to your props file. If you need you can use
File() method rather than URL
raghu
-Original Message-
From: Greg Schueler [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 23, 2001 12:18 PM
To: [EMAIL PROTECTED]
Subject: RE: properties files and tomcat
1 - 100 of 115 matches
Mail list logo