logging-log4j-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gary Gregory <garydgreg...@gmail.com>
Subject Re: Fastest no logging config
Date Tue, 15 Mar 2016 15:07:23 GMT
On Tue, Mar 15, 2016 at 3:15 AM, Mikael Ståldal <mikael.staldal@magine.com>
wrote:

> Is this for testing purposes only?
>

Well no, I want the code to go as fast as possible under controlled
conditions in both tests and production, like when a well tested use case
has been proven to run flawlessly and can be unleashed with an extra
(small) boost of speed.

Gary


> On Tue, Mar 15, 2016 at 10:36 AM, Gary Gregory <garydgregory@gmail.com>
> wrote:
>
>> On Tue, Mar 15, 2016 at 1:56 AM, Mikael Ståldal <
>> mikael.staldal@magine.com> wrote:
>>
>>> How would you use such a thing?
>>>
>>
>> (1) Run my app performance driver, make sure it works.
>> (2) Set logging to "no-op" for all logging to make it go faster (as Remko
>> describes in theory)
>>
>> We implement standard APIs (like JDBC) and we call traceEntry/traceExit
>> on these standard APIs, some of which are in tight loops: get each column
>> value for each row of a 50m row table for example.
>>
>> Calling Logger.isTraceEnabled() is called 50m x # of columns and then
>> some and shows up as between 2 and 5% in a profiler (I use YourKit for now).
>>
>> I want to eliminate that in get the raw performance timings as low as
>> possible. We can also tell customers that once they have everything set up
>> just so, then can toggle this switch to get a 2-5% improvement (depending
>> on the job).
>>
>> Gary
>>
>>
>>> On Mon, Mar 14, 2016 at 10:00 PM, Gary Gregory <garydgregory@gmail.com>
>>> wrote:
>>>
>>>> I'm seeing mehtods isTraceEnabled() show up in my profiling sessions.
>>>>
>>>> I'd like to be able to configure Log4j as totally no-op when for use
>>>> cases where performance is all that matters.
>>>>
>>>> I wonder if we could have a NoOpLogger in core that just stubs out
>>>> everything, and another ErrorLogger that NoOps everything below ERROR.
>>>>
>>>> Thoughts?
>>>>
>>>> Gary
>>>>
>>>> --
>>>> E-Mail: garydgregory@gmail.com | ggregory@apache.org
>>>> Java Persistence with Hibernate, Second Edition
>>>> <http://www.manning.com/bauer3/>
>>>> JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
>>>> Spring Batch in Action <http://www.manning.com/templier/>
>>>> Blog: http://garygregory.wordpress.com
>>>> Home: http://garygregory.com/
>>>> Tweet! http://twitter.com/GaryGregory
>>>>
>>>
>>>
>>>
>>> --
>>> [image: MagineTV]
>>>
>>> *Mikael Ståldal*
>>> Senior software developer
>>>
>>> *Magine TV*
>>> mikael.staldal@magine.com
>>> Grev Turegatan 3  | 114 46 Stockholm, Sweden  |   www.magine.com
>>>
>>> Privileged and/or Confidential Information may be contained in this
>>> message. If you are not the addressee indicated in this message
>>> (or responsible for delivery of the message to such a person), you may
>>> not copy or deliver this message to anyone. In such case,
>>> you should destroy this message and kindly notify the sender by reply
>>> email.
>>>
>>
>>
>>
>> --
>> E-Mail: garydgregory@gmail.com | ggregory@apache.org
>> Java Persistence with Hibernate, Second Edition
>> <http://www.manning.com/bauer3/>
>> JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
>> Spring Batch in Action <http://www.manning.com/templier/>
>> Blog: http://garygregory.wordpress.com
>> Home: http://garygregory.com/
>> Tweet! http://twitter.com/GaryGregory
>>
>
>
>
> --
> [image: MagineTV]
>
> *Mikael Ståldal*
> Senior software developer
>
> *Magine TV*
> mikael.staldal@magine.com
> Grev Turegatan 3  | 114 46 Stockholm, Sweden  |   www.magine.com
>
> Privileged and/or Confidential Information may be contained in this
> message. If you are not the addressee indicated in this message
> (or responsible for delivery of the message to such a person), you may not
> copy or deliver this message to anyone. In such case,
> you should destroy this message and kindly notify the sender by reply
> email.
>



-- 
E-Mail: garydgregory@gmail.com | ggregory@apache.org
Java Persistence with Hibernate, Second Edition
<http://www.manning.com/bauer3/>
JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
Spring Batch in Action <http://www.manning.com/templier/>
Blog: http://garygregory.wordpress.com
Home: http://garygregory.com/
Tweet! http://twitter.com/GaryGregory

Mime
View raw message