Re: Override log4j.properties during testing

2016-07-12 Thread Debraj Manna
The issue was not due to log4j version. It was because one of the dependency (s3ninja ) we were using during testing. It seems it was also using log4j and has its default log level set to INFO. To solve this I also set s3ninja's log level to the rootLogger level

Re: Override log4j.properties during testing

2016-06-15 Thread Matt Sicker
I thought karaf used a file called org.ops4j.pax.logging.cfg, not log4j.properties. If you do that, then you'll have one config used for testing and another used by karaf. On 15 June 2016 at 12:50, Debraj Manna wrote: > Is it possible to resolve my issue without

Re: Override log4j.properties during testing

2016-06-15 Thread Debraj Manna
Is it possible to resolve my issue without upgrading to log4j2? I am asking this because right now we are using log4j in a karaf bundle. If we are moving to log4j2 we also have to configure karaf to use as log4j2. On Jun 15, 2016 9:50 PM, "Matt Sicker" wrote: > That's not the

Re: Override log4j.properties during testing

2016-06-15 Thread Matt Sicker
That's not the right artifact. Take a look here: < http://logging.apache.org/log4j/2.x/manual/migration.html> On 15 June 2016 at 11:16, Debraj Manna wrote: > I updated my pom as shown below. Rest all are same. But still no luck. Same > issue all INFO logs are getting

Re: Override log4j.properties during testing

2016-06-15 Thread Debraj Manna
I updated my pom as shown below. Rest all are same. But still no luck. Same issue all INFO logs are getting printed even though I have specified ERROR log level in my src/test/resources/log4j.properties Added the below dependency:- org.apache.logging.log4j log4j 2.6 pom Removed the

Re: Override log4j.properties during testing

2016-06-15 Thread Ralph Goers
You are using log4j 1.2.17, which reached end-of-life last year. We recommend you upgrade to Log4j 2 since we no longer support log4j 1. Ralph > On Jun 15, 2016, at 6:04 AM, Debraj Manna wrote: > > I want to log only the ERROR during testing in maven. For this

Re: Override log4j.properties during testing

2016-06-15 Thread Remko Popma
Please take a look at the log4j2 manual (https://logging.apache.org/log4j/2.x/manual/configuration.html) for how to configure. The documentation is much better than Log4j-1.2. Sent from my iPhone > On 2016/06/15, at 22:29, Remko Popma wrote: > > Your pom looks wrong:

Re: Override log4j.properties during testing

2016-06-15 Thread Remko Popma
Your pom looks wrong: it seems to be using log4j-1.2. Can you try with log4j 2.6.1? Sent from my iPhone > On 2016/06/15, at 22:04, Debraj Manna wrote: > > I want to log only the ERROR during testing in maven. For this purpose I > created a file

Override log4j.properties during testing

2016-06-15 Thread Debraj Manna
I want to log only the ERROR during testing in maven. For this purpose I created a file src/test/resources/log4j.properties, which is going to override the configuration I already have in src/main/resources/log4j.properties. But this is not working. My log4j.properties looks like below:-