This commit is contained in:
@@ -12,6 +12,9 @@ namespace AyaNova.Generator
|
||||
//This is a temporary class until .net 2.1 is released
|
||||
//https://docs.microsoft.com/en-us/dotnet/standard/microservices-architecture/multi-container-microservice-net-applications/background-tasks-with-ihostedservice
|
||||
|
||||
//Here is how it's supposed to be done with .net 3.x:
|
||||
//https://docs.microsoft.com/en-us/aspnet/core/fundamentals/host/hosted-services?view=aspnetcore-3.0&tabs=netcore-cli
|
||||
//right now it's working so fuck it basically
|
||||
|
||||
// Copyright (c) .NET Foundation. Licensed under the Apache License, Version 2.0.
|
||||
/// <summary>
|
||||
|
||||
@@ -81,6 +81,7 @@ namespace AyaNova.Generator
|
||||
if (!serverState.IsOpen)
|
||||
{
|
||||
log.LogDebug($"GeneratorService: ServerState is closed returning without processing jobs, will try again next iteration");
|
||||
return;
|
||||
}
|
||||
|
||||
//=================================================================
|
||||
|
||||
@@ -25,6 +25,11 @@ namespace AyaNova.Util
|
||||
{
|
||||
get
|
||||
{
|
||||
#if (DEBUG)
|
||||
if(_provider==null){
|
||||
throw new System.NotSupportedException("ServiceProviderProvider.cs - Attempt to use service provider before it's been initialized");
|
||||
}
|
||||
#endif
|
||||
return _provider;
|
||||
}
|
||||
set
|
||||
|
||||
Reference in New Issue
Block a user