You are viewing a plain text version of this content. The canonical link for it is here.
Posted to torque-user@db.apache.org by "Puvvada, Sriram" <sp...@profilesys.com> on 2003/02/14 16:00:14 UTC
Torque Logging...
How to set logging in Torque?
I need to log each sql statement executed by torque. I have set the
following torque properties
log4j.category.org.apache.torque - ALL
log4j.appender.org.apache.torque -
org.apache.log4j.FileAppender
log4j.appender.org.apache.torque.file -
d:\torque.log
log4j.appender.org.apache.torque.layout -
org.apache.log4j.PatternLayout
log4j.appender.org.apache.torque.layout.conversionPattern %d [%t] %-5p
%c - %m%n
log4j.appender.org.apache.torque.append - false
But still any of sql statements is logging. Do i miss any property setting?
Regards,
Sriram.
Re: Torque Logging...
Posted by peter riegersperger <ri...@subnet.at>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Friday 14 February 2003 17:56, Travis McCauley wrote:
> Rick,
>
> Would this just go in the Torque.properties file when using standalone
> Torque?
sorry, i confused mailing lists. apparently, for the standalone torque, this
does not work.
i'm sure there is some way to log sql-statements (after all, they must be
coming from *somewhere* in turbine), but i don't know how to enable them.
rick
- --
|-
| peter riegersperger <ri...@subnet.at>
|-
| ein windows switcher tagebuch:
| http://forum.subnet.at/viewforum.php?f=22
|-
| subnet
| platform for media art and experimental technologies
|-
| http://www.subnet.at/
|-
| muehlbacherhofweg 5 // 5020 salzburg // austria
|-
| fon/fax +43/662/842 897
|-
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)
iD8DBQE+TSXKIMP39JYOy9IRAgI9AKD73S8FFRFF4nS4LmfQdz06pmEFJwCg/CAX
YY8RKJJ5yMgwF3PTaYJKqRY=
=ULvF
-----END PGP SIGNATURE-----
Re: Torque Logging...
Posted by Travis McCauley <tw...@virginia.edu>.
Rick,
Would this just go in the Torque.properties file when using standalone Torque?
Sincerely,
Travis McCauley
University of Virginia
> > How to set logging in Torque?
>> I need to log each sql statement executed by torque. I have set the
>> following torque properties
>
>set
>services.LoggingService.facilities=system,debug,security,sql
>services.LoggingService.system.level=DEBUG
>
>in TurbineResources.properties
>
>i think that's enough. if not, i can send you my complete logging settings.
>note though that only SELECT statements will get logged.
>
>rick
Re: Torque Logging...
Posted by peter riegersperger <ri...@subnet.at>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Friday 14 February 2003 16:00, Puvvada, Sriram wrote:
> How to set logging in Torque?
> I need to log each sql statement executed by torque. I have set the
> following torque properties
set
services.LoggingService.facilities=system,debug,security,sql
services.LoggingService.system.level=DEBUG
in TurbineResources.properties
i think that's enough. if not, i can send you my complete logging settings.
note though that only SELECT statements will get logged.
rick
- --
|-
| peter riegersperger <ri...@subnet.at>
|-
| ein windows switcher tagebuch:
| http://forum.subnet.at/viewforum.php?f=22
|-
| subnet
| platform for media art and experimental technologies
|-
| http://www.subnet.at/
|-
| muehlbacherhofweg 5 // 5020 salzburg // austria
|-
| fon/fax +43/662/842 897
|-
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)
iD8DBQE+TQwAIMP39JYOy9IRAngtAKCin3yJhc/7mPlKxHvBl8EmMcPPsACcCy5j
Zc7Mc8p9lh6HCJcLrL8g6Hw=
=eIth
-----END PGP SIGNATURE-----
Re: Torque Logging...
Posted by "Peter S. Hamlen" <ph...@mail.com>.
(Disclaimer: I'm using Torque 3.0b2 so this may be slightly out of
date.)
Sriram,
Probably the best way to handle this is to create a log4j.properties
file somewhere in your classpath. By the magic of
apache.commons.logging, it will find the log4j file and then use it for
logging.
I believe they took out the ability to place log4j configuration files
in the Torque.properties file. So you have to place them in your
log4j.properties file.
My sample log4j.properties file looks like this:
# log4j init properties
# By default, we only want WARNING errors or above
# for most classes.
#
# look for stdout and redOut appenders to understand
# what they're doing.
# category definitions
# we send ALL messages from torque, struts and redwood classes to
# stdout and redOut
log4j.category.org.apache.torque=debug, redOut
log4j.category.org.apache.struts=info, redOut
log4j.category.org.tfa.redwood=info, redOut
# called "redwood.log" - this file gets created
# in the local directory.
log4j.appender.redOut=org.apache.log4j.FileAppender
log4j.appender.redOut.File=redwood.log
log4j.appender.redOut.layout=org.apache.log4j.PatternLayout
log4j.appender.redOut.layout.ConversionPattern=[%p %c] - %m%n
-Peter
On Fri, 2003-02-14 at 10:00, Puvvada, Sriram wrote:
> How to set logging in Torque?
> I need to log each sql statement executed by torque. I have set the
> following torque properties
>
> log4j.category.org.apache.torque - ALL
> log4j.appender.org.apache.torque -
> org.apache.log4j.FileAppender
> log4j.appender.org.apache.torque.file -
> d:\torque.log
> log4j.appender.org.apache.torque.layout -
> org.apache.log4j.PatternLayout
> log4j.appender.org.apache.torque.layout.conversionPattern %d [%t] %-5p
> %c - %m%n
> log4j.appender.org.apache.torque.append - false
>
> But still any of sql statements is logging. Do i miss any property setting?
>
> Regards,
> Sriram.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
> For additional commands, e-mail: torque-user-help@db.apache.org
>