Return-Path: X-Original-To: apmail-logging-log4net-user-archive@www.apache.org Delivered-To: apmail-logging-log4net-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 4A191D675 for ; Thu, 23 May 2013 18:26:31 +0000 (UTC) Received: (qmail 1129 invoked by uid 500); 23 May 2013 18:26:31 -0000 Delivered-To: apmail-logging-log4net-user-archive@logging.apache.org Received: (qmail 920 invoked by uid 500); 23 May 2013 18:26:30 -0000 Mailing-List: contact log4net-user-help@logging.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: "Log4NET User" List-Id: Delivered-To: mailing list log4net-user@logging.apache.org Received: (qmail 886 invoked by uid 99); 23 May 2013 18:26:30 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 23 May 2013 18:26:30 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS,UNPARSEABLE_RELAY X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [216.82.254.104] (HELO mail1.bemta7.messagelabs.com) (216.82.254.104) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 23 May 2013 18:26:24 +0000 Received: from [216.82.254.20:24482] by server-8.bemta-7.messagelabs.com id 14/0A-14907-C3F5E915; Thu, 23 May 2013 18:26:04 +0000 X-Env-Sender: rajy@michaels.com X-Msg-Ref: server-13.tower-47.messagelabs.com!1369333563!2300805!1 X-Originating-IP: [66.142.244.3] X-StarScan-Received: X-StarScan-Version: 6.9.6; banners=michaels.com,-,- X-VirusChecked: Checked Received: (qmail 2092 invoked from network); 23 May 2013 18:26:03 -0000 Received: from mmg.michaels.com (HELO MSIM1) (66.142.244.3) by server-13.tower-47.messagelabs.com with SMTP; 23 May 2013 18:26:03 -0000 Received: from WHVEXHC1.corp.msi.michaels.com ([10.4.31.202]) by MSIM1 with Microsoft SMTPSVC(6.0.3790.4675); Thu, 23 May 2013 13:26:03 -0500 Received: from WHVEXMBX2.corp.msi.michaels.com ([169.254.2.111]) by WHVEXHC1.corp.msi.michaels.com ([10.4.31.202]) with mapi id 14.02.0342.003; Thu, 23 May 2013 13:26:02 -0500 From: Yuvraj Raj To: "log4net-user@logging.apache.org" Subject: log4net.dll version 1.2.10.0 (FileSystemWatcher objects) Thread-Topic: log4net.dll version 1.2.10.0 (FileSystemWatcher objects) Thread-Index: Ac5X4vPvfDNnPnN0S6ytY1/88HH3fQ== Date: Thu, 23 May 2013 18:26:02 +0000 Message-ID: <75CF8BEDFEE65A4981D0AEFF27D7D7CE1383667C@WHVEXMBX2.corp.msi.michaels.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.4.31.254] Content-Type: multipart/alternative; boundary="_000_75CF8BEDFEE65A4981D0AEFF27D7D7CE1383667CWHVEXMBX2corpms_" MIME-Version: 1.0 X-OriginalArrivalTime: 23 May 2013 18:26:03.0213 (UTC) FILETIME=[FB632FD0:01CE57E2] X-Virus-Checked: Checked by ClamAV on apache.org --_000_75CF8BEDFEE65A4981D0AEFF27D7D7CE1383667CWHVEXMBX2corpms_ Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hi, I am application developer team supporting.NET project in Michaels Stores.= We have been using log4net.dll version 1.2.10.0 for application logs for = our project. The application is implemented in .NET , C# with 3.5 framewor= k. Recently we have faced System.OutOfMemoryException exception thrown by the= application. We have opened case with Microsoft. Microsoft analyzed and = said memory consumption is due to FileSystemWatcher objects used by log4ne= t.Config.XmlConfigurator+ConfigureAndWatchHandler which are still alive an= d pinned objects. >From the memory dump, They found >2000 instances of log4net.Config.XmlConf= igurator+ConfigureAndWatchHandler and the FileSystemWatcher objects create= d that contributed this issue. The issue is happening due to the fragmenta= tion of Gen2 Heap. The reason for the fragmentation is the pinned System.I= O.Overlapped objects used by FileSystemWatcher objects. To resolve the memory issue, we need to get rid of the fragmentation caus= ed by pinned objects used by FileSystemWatcher objects We have created logger object in singleton class but not sure how multiple= objects are being created. When looking at the log4net.dll help from Apache web page, we found the be= low link for log4net that have bug (LOG4NET-158) in version 1.2.10.0 sayin= g XmlConfigurator.ConfigureAndWatch() leaks resources if called multiple t= imes https://issues.apache.org/jira/browse/LOG4NET-158?page=3Dcom.atlassian.jir= a.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D1260114= 8#action_12601148 The issue was fixed in version 1.2.11.0. Please let us know if above memor= y issue was related to the bug and it has been resolved in the next releas= e. Any help would be greatly appreciated. Best Regards, Yuvraj Work: 972 409 5703 | Support: 972 400 0174 | Cell: 469 438 1396 __________________________________________________________________________= ___ Scanned by IBM Email Security Management Services powered by MessageLabs. = For more information please visit http://www-935.ibm.com/services/us/index= .wss/offerfamily/iss/a1026954 __________________________________________________________________________= ___ --_000_75CF8BEDFEE65A4981D0AEFF27D7D7CE1383667CWHVEXMBX2corpms_ Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable

Hi,=

 

I am application deve= loper team supporting.NET project in Michaels Stores. We have been using l= og4net.dll version 1.2.10.0 for application logs for our project. The application is i= mplemented in .NET , C# with 3.5 framework.

 

Recently we have face= d System.OutOfMemoryException exception thrown by the application. We have= opened case with Microsoft.  Microsoft analyzed and said memory cons= umption is due to FileSystemWatcher objects used by log4net.Config.XmlConfigurator= +ConfigureAndWatchHandler which are still alive and pinned objects= .

 

From the memory dump,= They found >2000 instances of log4net.Config.XmlConfigurator+= ;ConfigureAndWatchHandler and the= FileSystemWatcher objects created that contributed this issue. The = issue is happening due to the fragmentation of Gen2 Heap. The reason for t= he fragmentation is the pinned System.IO.Overlapped objects used by FileSystemWatcher objects.

 

To resolve the memory=  issue, we need to get rid of the fragmentation caused by pinned obj= ects used by FileSystemWatcher objects

 

We have created logge= r object in singleton class but not sure how multiple objects are being cr= eated.

 

When looking at the l= og4net.dll help from Apache web page, we found the below link for log4net = that have bug (LOG4NET-158) in version 1.2.10.0 saying XmlConfigurator.Con= figureAndWatch() leaks resources if called multiple times

 

https://issues.apache.org/jira/browse/LOG4NET-158?page=3Dc= om.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focuse= dCommentId=3D12601148#action_12601148

 

The issue was fixed i= n version 1.2.11.0. Please let us know if above memory issue was related t= o the bug and it has been resolved in the next release.

 

Any help would be gre= atly appreciated.

 

 

 

Best Regards,

Yuvraj

Work: 972 409 5703 | = Support: 972 400 0174 | Cell: 469 438 1396

 


__________________________________________________________________________= ___
Scanned by IBM Email Security Management Services powered by MessageLabs. = For more information please visit http://www-935.ibm.com/services/us/index= .wss/offerfamily/iss/a1026954
__________________________________________________________________________= ___
--_000_75CF8BEDFEE65A4981D0AEFF27D7D7CE1383667CWHVEXMBX2corpms_--