Use multiple versions of nlog?

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Use multiple versions of nlog?

droneclub
Hi,

I'm new to nlog, pardon my ignorance if I've missed something trivial.

I'm hosting several applications using IIS7, some use nlog 1.0.0.505 and some use NLog 2.0. I'm not sure how to create a web.config to accomodate both versions.

Is it possible to put several versions of the nlog.dll into the GAC so that each application has a list of versions to select from?

Is it perhaps a better idea to remove nlog from the GAC and let the application use the nlog it was deployed with? In that case, how do I reference nlog in web.config (to set targets etc)

Would greatly appreciate any help or pointers to where I can read more.

Thanks in advance.
Reply | Threaded
Open this post in threaded view
|

Re: Use multiple versions of nlog?

Jason LaFlair
Administrator
It is possible to put both versions in the GAC but personally I try to stay away from the GAC as much as I can.

I'd just include the version you need in your deployment (then you can deploy anywhere not caring what version(s) are in the GAC).

As for your configuration file - take a look at the docs here: Configuration File

Happy logging.

Jason.