Re: [jira] [Commented] (LOG4NET-562) LogicalThreadContext is not per Thread

2017-04-07 Thread Dominik Psenner
Thanks Alexander, that's exactly what I was suspecting. Parallel.ForEach() may not necessarily be using different threads to execute the tasks. Also, the latest stuff that can be implemented with async/await levers high parallelism without the need of multithreading. Only I'm afraid you have to

Re: [jira] [Commented] (LOG4NET-562) LogicalThreadContext is not per Thread

2017-04-07 Thread Alexander Houben
Hello Husain, I think the observed behavior lies in the implementation of Parallel.ForEach. All your assumptions seem correct to me except that Parallel.ForEach does not execute its actions on a separate thread or separate task each. If you look at mscorlib with ILSpy and find System.Threading.Ta