Robert Mrkonjic (JIRA | 29 Jun 12:27 2016
Picon

[jira] [Commented] (LOG4NET-418) Recursive read lock acquisitions not allowed in this mode.


    [
https://issues.apache.org/jira/browse/LOG4NET-418?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15354997#comment-15354997
] 

Robert Mrkonjic commented on LOG4NET-418:
-----------------------------------------

Hi,

I have the same issue which ends critical. We are using log4net in a WCF service hosted as a Windows Service
and after update to 1.2.15 we experience that service crashes unexpectedly and log says nothing about
cause of it. Extensive investigation has shown that log4net throws many LockRecursionException which
fill up the stack and end in a stackoverflowexception which crashes the service. Unfortunately, cannot
pinpoint the place in code where it happens.

According to the latest comments of other users, this ticker should not be marked as Resolved as the bug is
still active. Please, provide us with some hint how to solve this issue or at least some hint what the cause
of this issue could be. Thanks in advance!

> Recursive read lock acquisitions not allowed in this mode.
> ----------------------------------------------------------
>
>                 Key: LOG4NET-418
>                 URL: https://issues.apache.org/jira/browse/LOG4NET-418
>             Project: Log4net
>          Issue Type: Bug
>          Components: Appenders
>            Reporter: Fabio Marini
>
(Continue reading)

Andras Nemes (JIRA | 29 Jun 10:17 2016
Picon

[jira] [Created] (LOG4NET-520) MessageObject property of LoggingEvent not populated if using constructor with LoggingEventData

Andras Nemes created LOG4NET-520:
------------------------------------

             Summary: MessageObject property of LoggingEvent not populated if using constructor with LoggingEventData
                 Key: LOG4NET-520
                 URL: https://issues.apache.org/jira/browse/LOG4NET-520
             Project: Log4net
          Issue Type: Bug
          Components: Appenders
            Reporter: Andras Nemes

If I use the constructor...

public LoggingEvent(Type callerStackBoundaryDeclaringType,
log4net.Repository.ILoggerRepository repository, string loggerName, Level level, object message,
Exception exception)

...to build a LoggingEvent object then the private field m_message will be populated with the incoming
"message" parameter. The result is that both the MessageObject and the RenderedMessage property of
LoggingEvent will have the correct message value.

However, if I use the following constructor...

public LoggingEvent(LoggingEventData data)

...where I populate the Message field of the LoggingEventData struct with some message then the m_message
private field is not populated at all, it remains null. Therefore the MessageObject property of
LoggingEvent will also be null. However, RenderedMessage will still have the correct value.

This causes an issue with at least one appender: gelf4net (https://github.com/jjchiw/gelf4net) which
(Continue reading)

ASF GitHub Bot (JIRA | 28 Jun 08:11 2016
Picon

[jira] [Commented] (LOG4NET-467) Is .NET Core, will be supported in the near future, or not


    [
https://issues.apache.org/jira/browse/LOG4NET-467?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15352426#comment-15352426
] 

ASF GitHub Bot commented on LOG4NET-467:
----------------------------------------

Github user pantonis commented on the issue:

    https://github.com/apache/log4net/pull/16

    +1

> Is .NET Core, will be supported in the near future, or not
> ----------------------------------------------------------
>
>                 Key: LOG4NET-467
>                 URL: https://issues.apache.org/jira/browse/LOG4NET-467
>             Project: Log4net
>          Issue Type: New Feature
>          Components: Core
>    Affects Versions: 1.2.13
>            Reporter: san kan
>              Labels: features
>
> As you know, ms is moving heavily toward .Net core:
> https://github.com/dotnet/core
> so, is there a road map for making a version that supports it?
> and i noticed that log4net, has not been updated for 2 years.
(Continue reading)

kolbasik | 27 Jun 16:19 2016
Picon
Gravatar

[GitHub] log4net pull request #28: Removed the event properties information from Logg...

GitHub user kolbasik opened a pull request:

    https://github.com/apache/log4net/pull/28

    Removed the event properties information from LoggingEvent

    
    ### Aim
    In order to increase the speed up operations in almost x10 times of using properties in the output when
UserName and Identity information are not needed.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/kolbasik/log4net hotfix/log-event-issue

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/log4net/pull/28.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #28

----
commit cece49dcd81c86847e634ad54e5ee3e3cae230b4
Author: Sergii Kolbasin <sergii.kolbasin <at> albumprinter.com>
Date:   2016-06-27T14:17:11Z

    Removed the event properties in CreateCompositeProperties
(Continue reading)

勝田均 | 26 Jun 14:26 2016
Picon

RollingFileAppender ignores the application base directory

I think RollingFileAppender should call ConvertToFullPath(string path) to get the full path of a log file, but two methods in RollingFileAppender call Path.GetFullPath(string path) directory.
And many methods of RollingFileAppenderTest should get the full path of a log file before pass to a constructor of FileInfo, StreamReader and FileStream.
// KATTA Hitoshi
Dominik Psenner (JIRA | 22 Jun 18:55 2016
Picon

[jira] [Resolved] (LOG4NET-518) Filters don't work when use multiple.


     [
https://issues.apache.org/jira/browse/LOG4NET-518?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dominik Psenner resolved LOG4NET-518.
-------------------------------------
    Resolution: Won't Fix
      Assignee: Dominik Psenner

A filter can deny or accept, but if neither option makes any sense it must say 'i dont care' and return the
decision token such that the next filter can continue checking.

> Filters don't work when use multiple.
> -------------------------------------
>
>                 Key: LOG4NET-518
>                 URL: https://issues.apache.org/jira/browse/LOG4NET-518
>             Project: Log4net
>          Issue Type: Bug
>          Components: Other
>    Affects Versions: 1.2.15
>            Reporter: huiqiang yan
>            Assignee: Dominik Psenner
>
> I have an application managed multiple AppDomains, and my master application can get messages from all
appDomain, then log them separately.
> I create appenders from each appDomains and use the 'domain name’ and 'log level' to discriminate。
> RollingFileAppender appender = new RollingFileAppender();
> appender.AddFilter(new LevelRangeFilter
> {
>     LevelMin = Level.Info,
>     LevelMax = Level.Info,
>     AcceptOnMatch = false,
>     Next = new LoggerMatchFilter
>     {
>         LoggerToMatch = name,
>         AcceptOnMatch = true                    
>     }
> });
> when name doesn't match, the If statement in filter LoggerMatchFilter file at line 140 ,I think it means
match or doesn't match, it should be deny in else statement.
> AcceptOnMatch only use when the match is passed ,it means if should return Accept when matched,and when it
is false then return Neutral.
> Not only LoggerMatchFilter has this problem, others too. 

--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Pavel Kilik (JIRA | 22 Jun 14:38 2016
Picon

[jira] [Created] (LOG4NET-519) Number of RollBackups files extremely increases

Pavel Kilik created LOG4NET-519:
-----------------------------------

             Summary: Number of RollBackups files extremely increases
                 Key: LOG4NET-519
                 URL: https://issues.apache.org/jira/browse/LOG4NET-519
             Project: Log4net
          Issue Type: Bug
    Affects Versions: 1.2.15
         Environment: Win 7
            Reporter: Pavel Kilik
            Priority: Minor

We have defined LogManager with repositories. In repositories are the RollingFileAppenders. For each
RollingFileAppender are defined values:
{code:title=C#, init value settings|borderStyle=solid}
        AppendToFile = true;
        RollingStyle = RollingFileAppender.RollingMode.Size;
        MaxSizeRollBackups = maxFileCount;
        MaximumFileSize = maxFileSize;
{code}
It works without problems and number of RollBackups files is equal to MaxSizeRollBackups. If values of
MaxSizeRollBackups and MaximumFileSize are runtime changed, the MaxSizeRollBackups is ignored,
RollBackups files are not deleted  and number of RollBackups files extremely increases. There can be more
than 1500 files!!!

RollingFileAppender change in our C# code:

{code:title=C#, runtime value changing|borderStyle=solid}
  foreach(var v in LogManager.GetRepository(CreateRepositoryName(id)).GetAppenders())
  {
	if(v is RollingFileAppender)
	{
	  RollingFileAppender roll = v as RollingFileAppender;
	  if (roll.MaximumFileSize != filesize)
	  {
		roll.MaximumFileSize = filesize;
	  }
	  if (roll.MaxSizeRollBackups != filecount)
	  {
		roll.MaxSizeRollBackups = filecount;
	  }
	}
  }
{code}

Part of log4net logging. There are 22 RollBackups, but maxSizeRollBackups is set to 2. The value of
maxSizeRollBackups is ignored.

{code:title=log4net logging|borderStyle=solid}
log4net: rolling over count [2058]
log4net: maxSizeRollBackups [2]
log4net: curSizeRollBackups [22]
log4net: countDirection [-1]
log4net: Moving
[C:\01_Data\Main\Trunk\KDA\FC\Core\bin\Debug\LogAdapter\11004_L1-AD_NoEquipment.log.22] -> [C:\01_Data\Main\Trunk\KDA\FC\Core\bin\Debug\LogAdapter\11004_L1-AD_NoEquipment.log.23]
log4net: Moving
[C:\01_Data\Main\Trunk\KDA\FC\Core\bin\Debug\LogAdapter\11004_L1-AD_NoEquipment.log.21] -> [C:\01_Data\Main\Trunk\KDA\FC\Core\bin\Debug\LogAdapter\11004_L1-AD_NoEquipment.log.22]
{code}

--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

huiqiang yan (JIRA | 22 Jun 05:44 2016
Picon

[jira] [Commented] (LOG4NET-518) Filters don't work when use multiple.


    [
https://issues.apache.org/jira/browse/LOG4NET-518?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15343652#comment-15343652
] 

huiqiang yan commented on LOG4NET-518:
--------------------------------------

In my understanding, the filters are performed in a sequential order, as long as there is a filter that does
not match, it should be denied, rather than continue to find the next filter. As LevelRangeFilter does now.

> Filters don't work when use multiple.
> -------------------------------------
>
>                 Key: LOG4NET-518
>                 URL: https://issues.apache.org/jira/browse/LOG4NET-518
>             Project: Log4net
>          Issue Type: Bug
>          Components: Other
>    Affects Versions: 1.2.15
>            Reporter: huiqiang yan
>
> I have an application managed multiple AppDomains, and my master application can get messages from all
appDomain, then log them separately.
> I create appenders from each appDomains and use the 'domain name’ and 'log level' to discriminate。
> RollingFileAppender appender = new RollingFileAppender();
> appender.AddFilter(new LevelRangeFilter
> {
>     LevelMin = Level.Info,
>     LevelMax = Level.Info,
>     AcceptOnMatch = false,
>     Next = new LoggerMatchFilter
>     {
>         LoggerToMatch = name,
>         AcceptOnMatch = true                    
>     }
> });
> when name doesn't match, the If statement in filter LoggerMatchFilter file at line 140 ,I think it means
match or doesn't match, it should be deny in else statement.
> AcceptOnMatch only use when the match is passed ,it means if should return Accept when matched,and when it
is false then return Neutral.
> Not only LoggerMatchFilter has this problem, others too. 

--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Dominik Psenner (JIRA | 21 Jun 19:08 2016
Picon

[jira] [Commented] (LOG4NET-518) Filters don't work when use multiple.


    [
https://issues.apache.org/jira/browse/LOG4NET-518?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15342201#comment-15342201
] 

Dominik Psenner commented on LOG4NET-518:
-----------------------------------------

I just reviewed your patch and from what i have understood it makes filters more restrictive than they have
been until now. Until your patch, a filter would filter log events if all requirements are met, now events
are filtered if some requirements are met. Given that it breaks current functionality, your patch wont
make it into trunk. Please feed back if my review was wrong.

> Filters don't work when use multiple.
> -------------------------------------
>
>                 Key: LOG4NET-518
>                 URL: https://issues.apache.org/jira/browse/LOG4NET-518
>             Project: Log4net
>          Issue Type: Bug
>          Components: Other
>    Affects Versions: 1.2.15
>            Reporter: huiqiang yan
>
> I have an application managed multiple AppDomains, and my master application can get messages from all
appDomain, then log them separately.
> I create appenders from each appDomains and use the 'domain name’ and 'log level' to discriminate。
> RollingFileAppender appender = new RollingFileAppender();
> appender.AddFilter(new LevelRangeFilter
> {
>     LevelMin = Level.Info,
>     LevelMax = Level.Info,
>     AcceptOnMatch = false,
>     Next = new LoggerMatchFilter
>     {
>         LoggerToMatch = name,
>         AcceptOnMatch = true                    
>     }
> });
> when name doesn't match, the If statement in filter LoggerMatchFilter file at line 140 ,I think it means
match or doesn't match, it should be deny in else statement.
> AcceptOnMatch only use when the match is passed ,it means if should return Accept when matched,and when it
is false then return Neutral.
> Not only LoggerMatchFilter has this problem, others too. 

--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

ASF GitHub Bot (JIRA | 21 Jun 09:10 2016
Picon

[jira] [Commented] (LOG4NET-518) Filters don't work when use multiple.


    [
https://issues.apache.org/jira/browse/LOG4NET-518?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15341264#comment-15341264
] 

ASF GitHub Bot commented on LOG4NET-518:
----------------------------------------

GitHub user efenghuo opened a pull request:

    https://github.com/apache/log4net/pull/27

    fixed issue LOG4NET-518.

    when filter passed, should return accept or neutral(then next filter to work),else return deny

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/efenghuo/log4net trunk

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/log4net/pull/27.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #27

----
commit e86b0fb87b3efec5a9ccfe0c6213436c82d230db
Author: yanhuiqiang <i <at> efenghuo.com>
Date:   2016-06-21T07:05:28Z

    fixed issue LOG4NET-518.

----

> Filters don't work when use multiple.
> -------------------------------------
>
>                 Key: LOG4NET-518
>                 URL: https://issues.apache.org/jira/browse/LOG4NET-518
>             Project: Log4net
>          Issue Type: Bug
>          Components: Other
>    Affects Versions: 1.2.15
>            Reporter: huiqiang yan
>
> I have an application managed multiple AppDomains, and my master application can get messages from all
appDomain, then log them separately.
> I create appenders from each appDomains and use the 'domain name’ and 'log level' to discriminate。
> RollingFileAppender appender = new RollingFileAppender();
> appender.AddFilter(new LevelRangeFilter
> {
>     LevelMin = Level.Info,
>     LevelMax = Level.Info,
>     AcceptOnMatch = false,
>     Next = new LoggerMatchFilter
>     {
>         LoggerToMatch = name,
>         AcceptOnMatch = true                    
>     }
> });
> when name doesn't match, the If statement in filter LoggerMatchFilter file at line 140 ,I think it means
match or doesn't match, it should be deny in else statement.
> AcceptOnMatch only use when the match is passed ,it means if should return Accept when matched,and when it
is false then return Neutral.
> Not only LoggerMatchFilter has this problem, others too. 

--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

efenghuo | 21 Jun 09:10 2016
Picon
Gravatar

[GitHub] log4net pull request #27: fixed issue LOG4NET-518.

GitHub user efenghuo opened a pull request:

    https://github.com/apache/log4net/pull/27

    fixed issue LOG4NET-518.

    when filter passed, should return accept or neutral(then next filter to work),else return deny

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/efenghuo/log4net trunk

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/log4net/pull/27.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #27

----
commit e86b0fb87b3efec5a9ccfe0c6213436c82d230db
Author: yanhuiqiang <i <at> efenghuo.com>
Date:   2016-06-21T07:05:28Z

    fixed issue LOG4NET-518.

----

---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure <at> apache.org or file a JIRA ticket
with INFRA.
---


Gmane