IISExpress is now attached to NZBDrone.exe earlier, which means it should almost have a garanteed termination as soon as the host is killed.

Console logging starts earlier in the app.
Moved Default profiles to QualityProvider.
This commit is contained in:
kay.one 2011-06-12 20:45:22 -07:00
commit 8686eb5d32
6 changed files with 63 additions and 67 deletions

View file

@ -49,7 +49,8 @@ namespace NzbDrone
IISProcess.ErrorDataReceived += (OnErrorDataReceived);
//Set Variables for the config file.
Environment.SetEnvironmentVariable("NZBDRONE_PATH", Config.ProjectRoot);
IISProcess.StartInfo.EnvironmentVariables.Add("NZBDRONE_PATH", Config.ProjectRoot);
IISProcess.StartInfo.EnvironmentVariables.Add("NZBDRONE_PID", Process.GetCurrentProcess().Id.ToString());
try
{
@ -120,7 +121,7 @@ namespace NzbDrone
try
{
var response = new WebClient().DownloadString(AppUrl + "/health");
if (!response.Contains("OK"))
{
throw new ServerException("Health services responded with an invalid response.");
@ -148,6 +149,12 @@ namespace NzbDrone
e.Data.StartsWith("Request ended:") || e.Data == ("IncrementMessages called"))
return;
if (e.Data.Contains(" NzbDrone."))
{
Console.WriteLine(e.Data);
return;
}
IISLogger.Trace(e.Data);
}