Added Thread.Sleep hack during package installer to attempt to always fluke out that the app pool will be restarted after redirect.
Currently this has worked in the past but only by fluke, this hack just makes the fluke probably work more often. In the next release we'll need to refactor the package installers (there are about 7 instances of them in the codebase) to all use the same ajax methodology to ensure that the app pool is restarted properly (which is now done properly during the install process).
This commit is contained in:
@@ -3,6 +3,7 @@ using System.Collections;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Threading;
|
||||
using System.Web;
|
||||
using System.Web.SessionState;
|
||||
using System.Web.UI;
|
||||
@@ -275,6 +276,12 @@ namespace umbraco.presentation.developer.packages
|
||||
//and then copy over the files. This will take some time if it contains .dlls that will reboot the system..
|
||||
_installer.InstallFiles(pId, tempFile.Value);
|
||||
|
||||
//TODO: This is a total hack, we need to refactor the installer to be just like the package installer during the
|
||||
// install process and use AJAX to ensure that app pool restarts and restarts PROPERLY before installing the business
|
||||
// logic. Until then, we are going to put a thread sleep here for 2 seconds in hopes that we always fluke out and the app
|
||||
// pool will be restarted after redirect.
|
||||
Thread.Sleep(2000);
|
||||
|
||||
Response.Redirect("installer.aspx?installing=businesslogic&dir=" + tempFile.Value + "&pId=" + pId.ToString());
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user