The application logs great from a console app with .NET 4 and Ent Lib 5 on Windows 7 x64.
It does not log and creates the error below when deployed as a Windows Service to a Windows 2008 R2 server.
Due to UCMA 3.0 the application has to be built to target platform x64.
It works great as a console app and as a service deployed to W2008R2 when I changed everything to target .NET 3.5 and x64 with EntLib 5.0.
I switched everything to use Ent Lib 4.1 and it works fine in .NET 3.5 and .NET 4.0.
I really wanted to use Ent Lib 5 as I am using it elsewhere without issue. UCMA does not work with .NET 4.5 and it is not supposed to work with 4.0 but it does. I am using VS 2012 and don't want to start too far in the past. Any ideas?
Service cannot be started. Microsoft.Practices.ServiceLocation.ActivationException: Activation error occured while trying to get instance of type LogWriter, key "" ---> Microsoft.Practices.Unity.ResolutionFailedException: Resolution of the dependency
failed, type = "Microsoft.Practices.EnterpriseLibrary.Logging.LogWriter", name = "(none)".
Exception occurred while: while resolving.
Exception is: InvalidOperationException - The type Database cannot be constructed. You must configure the container to supply this value.
At the time of the exception, the container was:
Resolving Microsoft.Practices.EnterpriseLibrary.Logging.LogWriterImpl,LogWriter.__default__ (mapped from Microsoft.Practices.EnterpriseLibrary.Logging.LogWriter, (none))
Resolving parameter "structureHolder" of constructor Microsoft.Practices.EnterpriseLibrary.Logging.LogWriterImpl(Microsoft.Practices.EnterpriseLibrary.Logging.LogWriterStructureHolder structureHolder, Microsoft.Practices.EnterpriseLibrary.Logging...