ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Davide Marche <ja...@email.it>
Subject iBATIS and log4j
Date Tue, 07 Feb 2006 08:46:18 GMT
Hi everybody,

i am trying to use iBATIS (with DAO) in my web application, but i have a
problem when I try to use log4j. In a standalone application i don't
have any problem with log4j, but in this web application i cannot find a
way for iBATIS to use log4j and to use log4j in the other parts of my
web application.
In other words, i created the file log4j.properties and put it into the
default package (which is WEB-INF/classes when you deploy the
application), and i am sure the file itself is correct (it perfectly
works if i load it in a servlet). Just it seems iBATIS cannot find it.
Then i tryed to write an InitServlet that id loaded at the startup
(with<load-on-startup>1</load-on-startup>). It works from the log4j
point of view, because i am actually able to use it from my servlets,
but iBATIS still doesn't see it and doesn't log anything.
If it can help i also noticed that sometimes when the application starts
using the iBATIS DAO objects i receive this message

finalized appender named [name_of_the_appender]

and it actually stops logging at all. In few words, it seems like a
conflict.
My question is: is there anybody who managed to use iBATIS (and log4j)
in a web application AND use log4j in the business and application logic?
I tryed to look for informations about how iBATIS initialize log4j but i
couldn't find anything.

Any help or hint would be appreciated

Thanks in advance,
Davide Marche


Mime
View raw message