Re: Parallel.Invoke is failing for log4net EventLogAppender

2023-01-10 Thread Dominik Psenner
Hi anil, I have the impression you know by now what needs to be changed to make it work for parallel invocations. Would you be willing to write, test and propose a fix as a pull request? You should also add some unit tests that prove that the codebase still works as expected when not invoking from

Re: Parallel.Invoke is failing for log4net EventLogAppender

2023-01-10 Thread anil
Hi dominik, In EventLogAppender The below code is not able to handle the parallel calls. the highlighted code is failing when we are invoking the same method using Parallel.Invoke method override public void ActivateOptions() { base.ActivateOptions(); if (m_securityContext == null) { m_security

Re: Parallel.Invoke is failing for log4net EventLogAppender

2023-01-09 Thread Dominik Psenner
Hi Anil, without a stack trace the best I can provide is an educated guess. To me it looks suspicious that the exception message reads "Source *Log4NetTest.exe* already exists on the local computer.". I would start investigating why the executable name is in the exception message and why the appli

Fwd: Parallel.Invoke is failing for log4net EventLogAppender

2023-01-09 Thread anil
Hi Team, This is Anil. I am working as a .net Tech Lead and i am using log4net for logging purposes. Below are the version details of the same [image: image.png] I am trying to execute the Parllel.Invoke which intiializes the EventLog Appender as below and calls the ActivateOptions method Sys