[JIRA] Created: (LBCLASSIC-175) ILoggingEvent prepareForDeferredProcessing does not include callerDataArray

ILoggingEvent prepareForDeferredProcessing does not include callerDataArray --------------------------------------------------------------------------- Key: LBCLASSIC-175 URL: http://jira.qos.ch/browse/LBCLASSIC-175 Project: logback-classic Issue Type: Bug Components: layout Reporter: Konstantin Alexandrov Assignee: Logback dev list I've implement asynchronous file appender, and enqueue events, but %caller pattern can not be used in the case of deferred processing becouse caller information is losed. My suggestion is to create Throwable object in prepareForDeferredProcessing -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira

[ http://jira.qos.ch/browse/LBCLASSIC-175?page=com.atlassian.jira.plugin.syste... ] Torsten Juergeleit commented on LBCLASSIC-175: ---------------------------------------------- Please keep LogEvent.prepareForDeferredProcessing()s current behavior of only preparing the "cheap" stuff like thread name and MDC. The "expensive" stuff (mainly the caller data) can be easily prepared by calling LogEvent.getCallerData() if really wanted. This is what the suggested implementation of an AsyncAppender attached to http://jira.qos.ch/browse/LBCLASSIC-177 is currently doing. Here the preparation of the caller data is only be done if requested by the user via configuration.
ILoggingEvent prepareForDeferredProcessing does not include callerDataArray ---------------------------------------------------------------------------
Key: LBCLASSIC-175 URL: http://jira.qos.ch/browse/LBCLASSIC-175 Project: logback-classic Issue Type: Bug Components: layout Reporter: Konstantin Alexandrov Assignee: Logback dev list
I've implement asynchronous file appender, and enqueue events, but %caller pattern can not be used in the case of deferred processing becouse caller information is losed. My suggestion is to create Throwable object in prepareForDeferredProcessing
-- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira

[ http://jira.qos.ch/browse/LBCLASSIC-175?page=com.atlassian.jira.plugin.syste... ] Torsten Juergeleit edited comment on LBCLASSIC-175 at 1/2/10 12:36 AM: ----------------------------------------------------------------------- Please keep LogEvent.prepareForDeferredProcessing()s current behavior of only preparing the "cheap" stuff like thread name and MDC. The "expensive" stuff (mainly the caller data) can be easily prepared by calling LogEvent.getCallerData() if really wanted. This is what the suggested implementation of an AsyncAppender attached to LBCLASSIC-177 is currently doing. Here the preparation of the caller data is only be done if requested by the user via configuration. was (Author: tjuerge): Please keep LogEvent.prepareForDeferredProcessing()s current behavior of only preparing the "cheap" stuff like thread name and MDC. The "expensive" stuff (mainly the caller data) can be easily prepared by calling LogEvent.getCallerData() if really wanted. This is what the suggested implementation of an AsyncAppender attached to http://jira.qos.ch/browse/LBCLASSIC-177 is currently doing. Here the preparation of the caller data is only be done if requested by the user via configuration.
ILoggingEvent prepareForDeferredProcessing does not include callerDataArray ---------------------------------------------------------------------------
Key: LBCLASSIC-175 URL: http://jira.qos.ch/browse/LBCLASSIC-175 Project: logback-classic Issue Type: Bug Components: layout Reporter: Konstantin Alexandrov Assignee: Logback dev list
I've implement asynchronous file appender, and enqueue events, but %caller pattern can not be used in the case of deferred processing becouse caller information is losed. My suggestion is to create Throwable object in prepareForDeferredProcessing
-- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira

[ http://jira.qos.ch/browse/LBCLASSIC-175?page=com.atlassian.jira.plugin.syste... ] Konstantin Alexandrov commented on LBCLASSIC-175: ------------------------------------------------- Expensive is parse of caller data, " new Throwable()" is cheap, just need to store Throwable object in prepare
ILoggingEvent prepareForDeferredProcessing does not include callerDataArray ---------------------------------------------------------------------------
Key: LBCLASSIC-175 URL: http://jira.qos.ch/browse/LBCLASSIC-175 Project: logback-classic Issue Type: Bug Components: layout Reporter: Konstantin Alexandrov Assignee: Logback dev list
I've implement asynchronous file appender, and enqueue events, but %caller pattern can not be used in the case of deferred processing becouse caller information is losed. My suggestion is to create Throwable object in prepareForDeferredProcessing
-- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira

[ http://jira.qos.ch/browse/LBCLASSIC-175?page=com.atlassian.jira.plugin.syste... ] Torsten Juergeleit commented on LBCLASSIC-175: ----------------------------------------------
" new Throwable()" is cheap
Sorry, I'm not buying that calling Throwable.fillInStackTrace() for every single logging event is "cheap" (at least not cpu-wise). And I'm not buying that storing a stack trace within every logging event (whether or not the caller data is calculated later on) is "cheap" (memory-wise, gc-wise) as well.
ILoggingEvent prepareForDeferredProcessing does not include callerDataArray ---------------------------------------------------------------------------
Key: LBCLASSIC-175 URL: http://jira.qos.ch/browse/LBCLASSIC-175 Project: logback-classic Issue Type: Bug Components: layout Reporter: Konstantin Alexandrov Assignee: Logback dev list
I've implement asynchronous file appender, and enqueue events, but %caller pattern can not be used in the case of deferred processing becouse caller information is losed. My suggestion is to create Throwable object in prepareForDeferredProcessing
-- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira

[ http://jira.qos.ch/browse/LBCLASSIC-175?page=com.atlassian.jira.plugin.syste... ] Torsten Juergeleit commented on LBCLASSIC-175: ----------------------------------------------
From http://blogs.sun.com/jrose/entry/longjumps_considered_inexpensive :
The most costly part of exception processing on the JVM is creating the exception, not throwing it. Exception creation involves a native method named Throwable.fillInStackTrace, which looks down the stack (before the actual throw) and puts a whole backtrace into the exception object. It's great for debugging, but a terrible waste if all you want to do is pop a frame or two.
ILoggingEvent prepareForDeferredProcessing does not include callerDataArray ---------------------------------------------------------------------------
Key: LBCLASSIC-175 URL: http://jira.qos.ch/browse/LBCLASSIC-175 Project: logback-classic Issue Type: Bug Components: layout Reporter: Konstantin Alexandrov Assignee: Logback dev list
I've implement asynchronous file appender, and enqueue events, but %caller pattern can not be used in the case of deferred processing becouse caller information is losed. My suggestion is to create Throwable object in prepareForDeferredProcessing
-- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira

[ http://jira.qos.ch/browse/LBCLASSIC-175?page=com.atlassian.jira.plugin.syste... ] Torsten Juergeleit commented on LBCLASSIC-175: ---------------------------------------------- Instead of wasting cpu and memory by default the user should be able to configure the cost of prepareForDeferredProcessing() as suggested in LBCORE-132.
ILoggingEvent prepareForDeferredProcessing does not include callerDataArray ---------------------------------------------------------------------------
Key: LBCLASSIC-175 URL: http://jira.qos.ch/browse/LBCLASSIC-175 Project: logback-classic Issue Type: Bug Components: layout Reporter: Konstantin Alexandrov Assignee: Logback dev list
I've implement asynchronous file appender, and enqueue events, but %caller pattern can not be used in the case of deferred processing becouse caller information is losed. My suggestion is to create Throwable object in prepareForDeferredProcessing
-- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira

[ http://jira.qos.ch/browse/LBCLASSIC-175?page=com.atlassian.jira.plugin.syste... ] Konstantin Alexandrov commented on LBCLASSIC-175: ------------------------------------------------- You right, sorry.
ILoggingEvent prepareForDeferredProcessing does not include callerDataArray ---------------------------------------------------------------------------
Key: LBCLASSIC-175 URL: http://jira.qos.ch/browse/LBCLASSIC-175 Project: logback-classic Issue Type: Bug Components: layout Reporter: Konstantin Alexandrov Assignee: Logback dev list
I've implement asynchronous file appender, and enqueue events, but %caller pattern can not be used in the case of deferred processing becouse caller information is losed. My suggestion is to create Throwable object in prepareForDeferredProcessing
-- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira
participants (2)
-
Konstantin Alexandrov (JIRA)
-
Torsten Juergeleit (JIRA)