You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-user@logging.apache.org by Anshul Chhabra <ac...@tollbridgetech.com> on 2002/01/17 20:18:20 UTC

FileAppender and file Location & getOptions

Hi 
	I know that the getOptions is deprecated in 1.3.1. That basically
means that Log4j itself does not use it internally, and recommends that
users not use it either.
	
	Coming to getOptions on FileAppender - shouldn't the code be cleaned
up so that it uses setters instead of directly setting the internal
variables? In the case of FileAppender it is not so (and perhaps it is a
more general problem as well).

	Is there currently no way of separately specifying a directory name
in which you want the logs to go? Has anybody extended the FileAppender to
support this capability on a per appender basis?


Thanks
Anshul

Re: FileAppender and file Location & getOptions

Posted by T Master <tm...@iknowledgeinc.com>.
There is no way to set a log directory.
You want to set the actual file name.
use  fileAppender.setFile( "/foo/bar/mylog.txt")    .

Look up its usage in the javadoc for FileAppender.


Read up on the terminolgy for deprecated.  It meanswill be
discontinued/unsupported in future sometime  (not recommened for use).  The
code is still existant.

You mean log4j v1.1.3 i assume.

T Master


----- Original Message -----
From: "Anshul Chhabra" <ac...@tollbridgetech.com>
To: "'Log4J Users List'" <lo...@jakarta.apache.org>
Sent: Thursday, January 17, 2002 12:18 PM
Subject: FileAppender and file Location & getOptions


> Hi
> I know that the getOptions is deprecated in 1.3.1. That basically
> means that Log4j itself does not use it internally, and recommends that
> users not use it either.
>
> Coming to getOptions on FileAppender - shouldn't the code be cleaned
> up so that it uses setters instead of directly setting the internal
> variables? In the case of FileAppender it is not so (and perhaps it is a
> more general problem as well).
>
> Is there currently no way of separately specifying a directory name
> in which you want the logs to go? Has anybody extended the FileAppender to
> support this capability on a per appender basis?
>
>
> Thanks
> Anshul
>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>