Hello,
I have a question about the WAR directory structure. Namely, where
is the appropriate place to put configuration files, log files, and
other files that need to be read/written-to by my application? Clearly
putting them in the webroot isn't right. Can my application access
arbitrary
Put stuff that isn't supposed to be accessed via the web under
WEB-INF. You can create whatever directory structures you want within that.
In order to obtain access to a file under WEB-INF in a completely portable
way, use something like...
getServletContext().getResourceAsStream("/WEB-INF/my
Read-only files can be placed anywhere you want. For files that you need to
write to, use the 'javax.servlet.context.tmpdir' attribute of the
ServletContext (since you can't write to a WAR file :). Assuming that your
servlet extends GenericServlet (this includes the cases of HttpServlet, and
Tomc
Jacob Kjome wrote:
In order to obtain access to a file under WEB-INF in a completely
portable way, use something like...
getServletContext().getResourceAsStream("/WEB-INF/myproperties.xml");
What about if we have a tag descriptor somewhere below WEB-INF, is it
safe to refer to the path dir
Jake,
Well, thanks anyway. Maybe somebody else knows the score on this one
and will pipe up. :)
Erik
Jacob Kjome wrote:
Hello Erik,
Sorry, I don't do JSP and haven't a clue about taglibs
Jake
Tuesday, February 04, 2003, 9:31:27 AM, you wrote:
EP> Jacob Kjome wrote:
In order to obta
--
Tim Moore / Blackboard Inc. / Software Engineer
1899 L Street, NW / 5th Floor / Washington, DC 20036
Phone 202-463-4860 ext. 258 / Fax 202-463-4863
> -Original Message-
> From: Erik Price [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, February 04, 2003 12:27 PM
> To: Tomcat
Tim Moore wrote:
Hi Erik,
EP> What about if we have a tag descriptor somewhere below
WEB-INF, is
EP> it
EP> safe to refer to the path directly from the "uri"
attribute of the <%@
taglib %>> directive?
Yeah, you can do that. :-)
Thanks. Actually, I've already done it and it work
> -Original Message-
> From: Erik Price [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, February 04, 2003 2:14 PM
> To: Tomcat Users List
> Subject: Re: WAR format question
>
>
>
>
> Tim Moore wrote:
> > Hi Erik,
> >
> >
> >>&g
Thanks. This answers my question, but I'm still left with the
impression that I'll need to go beyond the WAR format if I want to write
to a log or flat file DB (i.e., non-temp application file). Also, since
containers don't guarantee support for an unpacked WAR (are there any
containers tha
> -Original Message-
> From: Jim Carlson [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, February 04, 2003 3:07 PM
> To: Tomcat Users List
> Subject: Re: WAR format question
>
>
>Thanks. This answers my question, but I'm still left with the
> impression
> From: "Jim Carlson" <[EMAIL PROTECTED]>
> Sent: Tuesday, February 04, 2003 12:06 PM
> Subject: Re: WAR format question
>Thanks. This answers my question, but I'm still left with the
> impression that I'll need to go beyond the WAR format if I want
Hello Erik,
Sorry, I don't do JSP and haven't a clue about taglibs
Jake
Tuesday, February 04, 2003, 9:31:27 AM, you wrote:
EP> Jacob Kjome wrote:
>>
>> In order to obtain access to a file under WEB-INF in a completely
>> portable way, use something like...
>>
>> getServletContext().getReso
Hello Jim,
Use a framework like Log4j which has lots of different appenders in
addition to the FileAppender and RollingFileAppender. If you really
want to log to file, then provide a for the location
of the files. Then you can override that with server-specific config
such as with the element
13 matches
Mail list logo