Replaces Log4Net Shutdown in UmbracoAppBase Application_End event with Serilog CloseAndFlush- not 100% sure we need to do this as think LightInject tears it down nicely

This commit is contained in:
Warren
2018-07-27 15:32:12 +01:00
parent 0826928ffa
commit f6c02fb543

View File

@@ -4,8 +4,10 @@ using System.Threading;
using System.Web;
using System.Web.Hosting;
using LightInject;
using Serilog;
using Umbraco.Core.Composing;
using Umbraco.Core.Logging;
using ILogger = Umbraco.Core.Logging.ILogger;
namespace Umbraco.Core
{
@@ -200,7 +202,10 @@ namespace Umbraco.Core
{
HandleApplicationEnd();
OnApplicationEnd(sender, evargs);
LogManager.Shutdown();
//Not sure if we need to do this - as my POC approach I never had to deal with this
//As the LightInject container when tearing down will dispose of Serilog AFAIK
Log.CloseAndFlush();
}
#endregion