0
votes

I've read this question: log4net-and-logging-from-parallel-instances

I have written a DLL that uses log4net for logging.

I have a process that uses my DLL with 2 instances (same process)

The first instance of the class has access to the log. the second instance doesn't log at all.

I can't use the processID in the file name - as it works only with 2 different instance of the app, not from the same app.

how can I make all calls to log from both instance to write to the log file ?

(I get the logger using Ilog log = LogManager.GetLogger("ClassName") ) and in the Ctor I read the configuration file...

The only solution I thought is to get the log from the external app in the ctor but I don't want to external app to do anything with my own logging.

1

1 Answers

1
votes

The problem was using the configurator at the constructor.

You can't call the configurator more than once.