<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
    <head> 
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> 
        <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0"> 
        <base href="https://jira.qos.ch"> 
        <title>Message Title</title> 
    </head> 
    <body class="jira" style="color: #333333; font-family: Arial, sans-serif; font-size: 14px; line-height: 1.429"> 
        <table id="background-table" cellpadding="0" cellspacing="0" width="100%" style="border-collapse: collapse; mso-table-lspace: 0pt; mso-table-rspace: 0pt; background-color: #f5f5f5; border-collapse: collapse; mso-table-lspace: 0pt; mso-table-rspace: 0pt" bgcolor="#f5f5f5"> 
            <!-- header here --> 
            <tbody>
                <tr> 
                    <td id="header-pattern-container" style="padding: 0px; border-collapse: collapse; padding: 10px 20px"> 
                        <table id="header-pattern" cellspacing="0" cellpadding="0" border="0" style="border-collapse: collapse; mso-table-lspace: 0pt; mso-table-rspace: 0pt"> 
                            <tbody>
                                <tr> 
                                    <td id="header-avatar-image-container" valign="top" style="padding: 0px; border-collapse: collapse; vertical-align: top; width: 32px; padding-right: 8px" width="32"> <img id="header-avatar-image" class="image_fix" src="cid:jira-generated-image-avatar-5a1f4475-700a-48e8-be15-4b5526fee886" height="32" width="32" border="0" style="border-radius: 3px; vertical-align: top"> </td> 
                                    <td id="header-text-container" valign="middle" style="padding: 0px; border-collapse: collapse; vertical-align: middle; font-family: Arial, sans-serif; font-size: 14px; line-height: 20px; mso-line-height-rule: exactly; mso-text-raise: 1px"> <a class="user-hover" rel="ceki" id="email_ceki" href="https://jira.qos.ch/secure/ViewProfile.jspa?name=ceki" style="color:#3b73af;; color: #3b73af; text-decoration: none">Ceki Gülcü</a> <strong>commented</strong> on <a href="https://jira.qos.ch/browse/LOGBACK-1279" style="color: #3b73af; text-decoration: none"><img src="cid:jira-generated-image-avatar-972e6dbf-f31b-41c1-8f60-2fedd273fba6" height="16" width="16" border="0" align="absmiddle" alt="Bug"> LOGBACK-1279</a> </td> 
                                </tr> 
                            </tbody>
                        </table> </td> 
                </tr> 
                <tr> 
                    <td id="email-content-container" style="padding: 0px; border-collapse: collapse; padding: 0 20px"> 
                        <table id="email-content-table" cellspacing="0" cellpadding="0" border="0" width="100%" style="border-collapse: collapse; mso-table-lspace: 0pt; mso-table-rspace: 0pt; border-spacing: 0; border-collapse: separate"> 
                            <tbody>
                                <tr> 
                                    <!-- there needs to be content in the cell for it to render in some clients --> 
                                    <td class="email-content-rounded-top mobile-expand" style="padding: 0px; border-collapse: collapse; color: #ffffff; padding: 0 15px 0 16px; height: 15px; background-color: #ffffff; border-left: 1px solid #cccccc; border-top: 1px solid #cccccc; border-right: 1px solid #cccccc; border-bottom: 0; border-top-right-radius: 5px; border-top-left-radius: 5px; height: 10px; line-height: 10px; padding: 0 15px 0 16px; mso-line-height-rule: exactly" height="10" bgcolor="#ffffff"> </td> 
                                </tr> 
                                <tr> 
                                    <td class="email-content-main mobile-expand " style="padding: 0px; border-collapse: collapse; border-left: 1px solid #cccccc; border-right: 1px solid #cccccc; border-top: 0; border-bottom: 0; padding: 0 15px 0 16px; background-color: #ffffff" bgcolor="#ffffff"> 
                                        <table class="page-title-pattern" cellspacing="0" cellpadding="0" border="0" width="100%" style="border-collapse: collapse; mso-table-lspace: 0pt; mso-table-rspace: 0pt"> 
                                            <tbody>
                                                <tr> 
                                                    <td style="vertical-align: top;; padding: 0px; border-collapse: collapse; padding-right: 5px; font-size: 20px; line-height: 30px; mso-line-height-rule: exactly" class="page-title-pattern-header-container"> <span class="page-title-pattern-header" style="font-family: Arial, sans-serif; padding: 0; font-size: 20px; line-height: 30px; mso-text-raise: 2px; mso-line-height-rule: exactly; vertical-align: middle"> <a href="https://jira.qos.ch/browse/LOGBACK-1279" style="color: #3b73af; text-decoration: none">Re: Async appenders do not scale well across multiple threads</a> </span> </td> 
                                                </tr> 
                                            </tbody>
                                        </table> </td> 
                                </tr> 
                                <tr> 
                                    <td id="text-paragraph-pattern-top" class="email-content-main mobile-expand  comment-top-pattern" style="padding: 0px; border-collapse: collapse; border-left: 1px solid #cccccc; border-right: 1px solid #cccccc; border-top: 0; border-bottom: 0; padding: 0 15px 0 16px; background-color: #ffffff; border-bottom: none; padding-bottom: 0" bgcolor="#ffffff"> 
                                        <table class="text-paragraph-pattern" cellspacing="0" cellpadding="0" border="0" width="100%" style="border-collapse: collapse; mso-table-lspace: 0pt; mso-table-rspace: 0pt; font-family: Arial, sans-serif; font-size: 14px; line-height: 20px; mso-line-height-rule: exactly; mso-text-raise: 2px"> 
                                            <tbody>
                                                <tr> 
                                                    <td class="text-paragraph-pattern-container mobile-resize-text " style="padding: 0px; border-collapse: collapse; padding: 0 0 10px 0"> <p style="margin: 10px 0 0 0; margin-top: 0">The AsyncFileAppender performance test is now in a separate file. Each benchmark, in addition to logging performs an additional operation taking a few microseconds, aka the baseline. The baseline duration is a benchmark parameter. When the baseline duration approaches 1 over the AsyncAppender logging throughput, the cost of AsyncAppender becomes invisible.</p> <p style="margin: 10px 0 0 0">Here is the command to run the benchmark test:</p> 
                                                        <div class="code panel" style="border-width: 1px;; border: 1px solid #cccccc; background: #f5f5f5; font-size: 12px; line-height: 1.333; font-family: monospace; border: 1px solid #cccccc; -moz-border-radius: 3px 3px 3px 3px; border-radius: 3px 3px 3px 3px; margin: 9px 0">
                                                            <div class="codeContent panelContent" style="padding: 9px 12px"> 
                                                                <pre class="code-java" style="margin: 10px 0 0 0; margin-top: 0; max-height: 30em; overflow: auto; white-space: pre-wrap; word-wrap: normal">java -jar target/benchmarks.jar  <span class="code-quote" style="color: #009100">".*AsyncFileAppenderBenchmark.*"</span> -f 1 -bm avgt -tu us -wi 5 -i 10 -t 16</pre> 
                                                            </div>
                                                        </div> <p style="margin: 10px 0 0 0">Here are the results with 16 threads</p> 
                                                        <div class="code panel" style="border-width: 1px;; border: 1px solid #cccccc; background: #f5f5f5; font-size: 12px; line-height: 1.333; font-family: monospace; border: 1px solid #cccccc; -moz-border-radius: 3px 3px 3px 3px; border-radius: 3px 3px 3px 3px; margin: 9px 0">
                                                            <div class="codeContent panelContent" style="padding: 9px 12px"> 
                                                                <pre class="code-java" style="margin: 10px 0 0 0; margin-top: 0; max-height: 30em; overflow: auto; white-space: pre-wrap; word-wrap: normal">
Benchmark                               (powerOf2)  Mode  Cnt    Score    Error  Units
AsyncFileAppenderBenchmark.baseline              8  avgt   10    4.116 ±  0.107  us/op
AsyncFileAppenderBenchmark.baseline             10  avgt   10   16.356 ±  0.602  us/op
AsyncFileAppenderBenchmark.baseline             12  avgt   10   66.020 ±  2.877  us/op
AsyncFileAppenderBenchmark.baseline             14  avgt   10  274.693 ± 23.184  us/op
AsyncFileAppenderBenchmark.log4j1File            8  avgt   10   18.592 ±  0.305  us/op
AsyncFileAppenderBenchmark.log4j1File           10  avgt   10   29.431 ±  0.529  us/op
AsyncFileAppenderBenchmark.log4j1File           12  avgt   10   70.657 ±  2.448  us/op
AsyncFileAppenderBenchmark.log4j1File           14  avgt   10  272.282 ±  3.867  us/op
AsyncFileAppenderBenchmark.log4j2RAF             8  avgt   10   14.797 ±  0.162  us/op
AsyncFileAppenderBenchmark.log4j2RAF            10  avgt   10   23.318 ±  0.415  us/op
AsyncFileAppenderBenchmark.log4j2RAF            12  avgt   10   64.871 ±  0.827  us/op
AsyncFileAppenderBenchmark.log4j2RAF            14  avgt   10  257.394 ±  3.796  us/op
AsyncFileAppenderBenchmark.logbackFile           8  avgt   10   54.249 ±  0.575  us/op
AsyncFileAppenderBenchmark.logbackFile          10  avgt   10   50.049 ±  0.356  us/op
AsyncFileAppenderBenchmark.logbackFile          12  avgt   10   73.832 ±  2.264  us/op
AsyncFileAppenderBenchmark.logbackFile          14  avgt   10  268.423 ±  6.736  us/op
</pre> 
                                                            </div>
                                                        </div> <p style="margin: 10px 0 0 0">Here are the results with 32 threads</p> 
                                                        <div class="code panel" style="border-width: 1px;; border: 1px solid #cccccc; background: #f5f5f5; font-size: 12px; line-height: 1.333; font-family: monospace; border: 1px solid #cccccc; -moz-border-radius: 3px 3px 3px 3px; border-radius: 3px 3px 3px 3px; margin: 9px 0">
                                                            <div class="codeContent panelContent" style="padding: 9px 12px"> 
                                                                <pre class="code-java" style="margin: 10px 0 0 0; margin-top: 0; max-height: 30em; overflow: auto; white-space: pre-wrap; word-wrap: normal">
Benchmark                               (powerOf2)  Mode  Cnt    Score    Error  Units
AsyncFileAppenderBenchmark.baseline              8  avgt   10    8.204 ±  0.136  us/op
AsyncFileAppenderBenchmark.baseline             10  avgt   10   32.935 ±  0.913  us/op
AsyncFileAppenderBenchmark.baseline             12  avgt   10  129.007 ±  2.421  us/op
AsyncFileAppenderBenchmark.baseline             14  avgt   10  547.678 ± 26.003  us/op
AsyncFileAppenderBenchmark.log4j1File            8  avgt   10   39.147 ±  6.186  us/op
AsyncFileAppenderBenchmark.log4j1File           10  avgt   10   58.539 ±  1.001  us/op
AsyncFileAppenderBenchmark.log4j1File           12  avgt   10  150.811 ±  8.552  us/op
AsyncFileAppenderBenchmark.log4j1File           14  avgt   10  579.674 ± 25.329  us/op
AsyncFileAppenderBenchmark.log4j2RAF             8  avgt   10   32.096 ±  2.859  us/op
AsyncFileAppenderBenchmark.log4j2RAF            10  avgt   10   47.249 ±  0.910  us/op
AsyncFileAppenderBenchmark.log4j2RAF            12  avgt   10  133.443 ±  2.474  us/op
AsyncFileAppenderBenchmark.log4j2RAF            14  avgt   10  513.933 ± 15.221  us/op
AsyncFileAppenderBenchmark.logbackFile           8  avgt   10  113.088 ±  1.204  us/op
AsyncFileAppenderBenchmark.logbackFile          10  avgt   10  119.610 ±  3.122  us/op
AsyncFileAppenderBenchmark.logbackFile          12  avgt   10  165.772 ±  2.294  us/op
AsyncFileAppenderBenchmark.logbackFile          14  avgt   10  552.415 ± 15.728  us/op
</pre> 
                                                            </div>
                                                        </div> <p style="margin: 10px 0 0 0">I don't understand why the base line cost increases with the number of threads but the gist should come across.</p> </td> 
                                                </tr> 
                                            </tbody>
                                        </table> </td> 
                                </tr> 
                                <tr> 
                                    <td class="email-content-main mobile-expand " style="padding: 0px; border-collapse: collapse; border-left: 1px solid #cccccc; border-right: 1px solid #cccccc; border-top: 0; border-bottom: 0; padding: 0 15px 0 16px; background-color: #ffffff" bgcolor="#ffffff"> 
                                        <table id="actions-pattern" cellspacing="0" cellpadding="0" border="0" width="100%" style="border-collapse: collapse; mso-table-lspace: 0pt; mso-table-rspace: 0pt; font-family: Arial, sans-serif; font-size: 14px; line-height: 20px; mso-line-height-rule: exactly; mso-text-raise: 1px"> 
                                            <tbody>
                                                <tr> 
                                                    <td id="actions-pattern-container" valign="middle" style="padding: 0px; border-collapse: collapse; padding: 10px 0 10px 24px; vertical-align: middle; padding-left: 0"> 
                                                        <table align="left" style="border-collapse: collapse; mso-table-lspace: 0pt; mso-table-rspace: 0pt"> 
                                                            <tbody>
                                                                <tr> 
                                                                    <td class="actions-pattern-action-icon-container" style="padding: 0px; border-collapse: collapse; font-family: Arial, sans-serif; font-size: 14px; line-height: 20px; mso-line-height-rule: exactly; mso-text-raise: 0px; vertical-align: middle"> <a href="https://jira.qos.ch/browse/LOGBACK-1279#add-comment" target="_blank" title="Add Comment" style="color: #3b73af; text-decoration: none"> <img class="actions-pattern-action-icon-image" src="cid:jira-generated-image-static-comment-icon-e8553018-6908-4bbb-830d-8528cc336572" alt="Add Comment" title="Add Comment" height="16" width="16" border="0" style="vertical-align: middle"> </a> </td> 
                                                                    <td class="actions-pattern-action-text-container" style="padding: 0px; border-collapse: collapse; font-family: Arial, sans-serif; font-size: 14px; line-height: 20px; mso-line-height-rule: exactly; mso-text-raise: 4px; padding-left: 5px"> <a href="https://jira.qos.ch/browse/LOGBACK-1279#add-comment" target="_blank" title="Add Comment" style="color: #3b73af; text-decoration: none">Add Comment</a> </td> 
                                                                </tr> 
                                                            </tbody>
                                                        </table> </td> 
                                                </tr> 
                                            </tbody>
                                        </table> </td> 
                                </tr> 
                                <!-- there needs to be content in the cell for it to render in some clients --> 
                                <tr> 
                                    <td class="email-content-rounded-bottom mobile-expand" style="padding: 0px; border-collapse: collapse; color: #ffffff; padding: 0 15px 0 16px; height: 5px; line-height: 5px; background-color: #ffffff; border-top: 0; border-left: 1px solid #cccccc; border-bottom: 1px solid #cccccc; border-right: 1px solid #cccccc; border-bottom-right-radius: 5px; border-bottom-left-radius: 5px; mso-line-height-rule: exactly" height="5" bgcolor="#ffffff"> </td> 
                                </tr> 
                            </tbody>
                        </table> </td> 
                </tr> 
                <tr> 
                    <td id="footer-pattern" style="padding: 0px; border-collapse: collapse; padding: 12px 20px"> 
                        <table id="footer-pattern-container" cellspacing="0" cellpadding="0" border="0" style="border-collapse: collapse; mso-table-lspace: 0pt; mso-table-rspace: 0pt"> 
                            <tbody>
                                <tr> 
                                    <td id="footer-pattern-text" class="mobile-resize-text" width="100%" style="padding: 0px; border-collapse: collapse; color: #999999; font-size: 12px; line-height: 18px; font-family: Arial, sans-serif; mso-line-height-rule: exactly; mso-text-raise: 2px"> This message was sent by Atlassian JIRA <span id="footer-build-information">(v7.3.1#73012-<span title="68837e38d8ed1b069612405186dcdceed665bb39" data-commit-id="68837e38d8ed1b069612405186dcdceed665bb39}">sha1:68837e3</span>)</span> </td> 
                                    <td id="footer-pattern-logo-desktop-container" valign="top" style="padding: 0px; border-collapse: collapse; padding-left: 20px; vertical-align: top"> 
                                        <table style="border-collapse: collapse; mso-table-lspace: 0pt; mso-table-rspace: 0pt"> 
                                            <tbody>
                                                <tr> 
                                                    <td id="footer-pattern-logo-desktop-padding" style="padding: 0px; border-collapse: collapse; padding-top: 3px"> <img id="footer-pattern-logo-desktop" src="cid:jira-generated-image-static-footer-desktop-logo-441d4b15-41b6-435c-9054-71acbf6de8f9" alt="Atlassian logo" title="Atlassian logo" width="169" height="36" class="image_fix"> </td> 
                                                </tr> 
                                            </tbody>
                                        </table> </td> 
                                </tr> 
                            </tbody>
                        </table> </td> 
                </tr> 
            </tbody>
        </table>   
    </body>
</html>