private static void RemoveForceInstallation(ApplicationServer appServer, ApplicationWithOverrideVariableGroup appWithGroup) { // If this was a force install, remove it, so we don't keep trying to install it repeatedly. ServerForceInstallation forceInstallation = appServer.GetFromForceInstallList(appWithGroup); if (forceInstallation != null) { appServer.ForceInstallationsToDo.Remove(forceInstallation); // Remove so we don't install again. ApplicationServerLogic.RemoveForceInstallation(forceInstallation); } }
// We don't persist these; this is just used in memory when determining what force installations to process. // Because of this, when the Presto Task Runner removes from ServerForceInstallations (completely separate // in the database from the ApplicationServer class), we won't get concurrency issues. // Note: This is internal so the automated tests can access it. internal static void HydrateForceInstallationsToDo(ApplicationServer appServer) { appServer.ForceInstallationsToDo = new List <ServerForceInstallation>(ApplicationServerLogic.GetForceInstallationsByServerId(appServer.Id)); }