Questions tagged [log4jdbc]

log4jdbc is a Java JDBC driver that can log SQL and/or JDBC calls (and optionally SQL timing information) for other JDBC drivers using the Simple Logging Facade For Java (SLF4J) logging system.

39 questions
1
vote
0 answers

(log4jdbc + slf4j + logback) how to auto line sort sql log?

I installed Log4jdbc-log4j2 + slf4j + logback on my dynamic web server project. During the test, the log and query statements come out as set, but like other people, the query statement does not wrap automatically. Only one line. If you set the…
namu
  • 11
  • 1
1
vote
1 answer

Getting syntax error (XML Config) in MySQL using Log4j2

I am currently working on my Spring project to create simple library portal (just for education purposes). And now I am struggling with logging some actions into MySQL database using Log4j2 JDBCAppender. To do that, I have created table in my…
1
vote
1 answer

log4jdbc force return ConnectionSpy driver

For some reason when I use: connection = DriverManager.getConnection("jdbc:log4jdbc:derby:/home/user/mydb"); I tend to get differing connections back. In this case, it's a mixture between: connection = (org.apache.derby.impl.jdbc.EmbedConnection)…
Hooli
  • 1,135
  • 3
  • 19
  • 46
1
vote
0 answers

Weblogic, log4j and log4jdbc, log in file but not in console

In Weblogic, using log4jdbc, I need to log queries (using org.jdbcdslog.StatementLogger) only in a specific file but not in console. I tried to start Weblogic with this parameter -Dlog4j.configuration=file:%LOG4JDBC_HOME%\log4j.xml This is the…
Francesca
  • 11
  • 1
1
vote
1 answer

How do I remove the Tomcat INFO just from log file

How I can remove all my Tomcat INFO from my log file, but just from my log file, I want to see that INFO only in console output
Dumitru Vlad
  • 109
  • 1
  • 2
  • 13
1
vote
1 answer

Configuring log4jdbc-log4j2 with Liberty Profile

I have a web application that is deployed locally to a Liberty Profile server, and that is already working with log4j2. My end goal is to log all of the PreparedStatements with their parameter values included in the query string, just before they…
Tyndareus
  • 13
  • 6
1
vote
3 answers

How to print Log4j java sql logger

I want to use log4j for java and sql. i want to print the java and sql logs without using "logger.debug("log4j logger")" in my class. Below are the class and log4j properties used package com.log4j; import java.sql.Connection; import…
Nisha
  • 91
  • 2
  • 3
  • 15
1
vote
2 answers

Replacing log4j-api-2.0-beta9.jar,log4j-core-2.0-beta9 with log4j-api-2.0.1.jar and log4j-core-2.0.1.jar not working

I am trying to use the new log4j2 release in my application and it is not working. It was working when i used log4j-api-2.0-beta9.jar and log4j-core-2.0-beta9 but its not working after i replaced it with the new release: log4j-api-2.0.1.jar and…
Lee land
  • 11
  • 1
1
vote
0 answers

Java Exception Manager - Enterprise Level

I am looking for an industrial strength FOSS logger for an Enterprise Java application, before I embark on re-inventing the wheel... We have all seen large apps that log exceptions (think SAPesque), but beyond log4J type stuff. These features are…
cmdematos
  • 883
  • 4
  • 12
  • 24
1
vote
1 answer

log4j(dbc) + Hibernate: filtering ONLY sql statments

Good evening everyone. I'm using log4j with log4jdbc to log my application's Hibernate fw. I have this log4j.xml file
0
votes
0 answers

SLF4J (2.0.6) compatibility with Log4JDBC

We are upgrading SLF4J to 2.0.6 and Log4J to 2.20.0. We also have Log4JDBC in our project for logging JDBC activities. The version being used is: 1.16 (log4jdbc-log4j2-jdbc4.1). We also have MDC configured in our logs. Post the upgrade, we are…
Shashi
  • 339
  • 1
  • 4
  • 15
0
votes
0 answers

Not able to found alternative of UnRecognisedElementHandler in log4j 2.19

There is code that is using log4j 1.2 and we are aiming to migrate to log4j 2.19. There is a class implementing UnRecognisedElementHandler. I am not able to find an alternative to it
adityaatri
  • 1,967
  • 2
  • 7
  • 10
0
votes
0 answers

Is there a way to update log4j to latest version?

1.How can we update log4j from older versions to latest version 2.What needs to be changed in pom.xml 3.What artifacts needs to be updated 4.Which verison of log4j is stable 5.What is the source to upgrade log4j to latest version
suneel
  • 1
  • 2
0
votes
1 answer

log4jdbc-log4j2-jdbc4 logging error ResultSet.isClosed

I am using log4j2, and I added "log4jdbc-log4j2-jdbc4" library to express the sql query statement log, but there is an error at runtime. System Specifications: jdk1.6 log4j2.3.2 slf4j-api 1.7.12 What I did: Add jar to maven …
0
votes
1 answer

Log4jdbc level configuration is not working

This is my logback.xml configuration %d{yyyyMMdd HH:mm:ss.SSS} [%thread] %-3level…
JunKim
  • 647
  • 7
  • 17