From 482c86a73156049286c9c3ce87138fe7a538bf78 Mon Sep 17 00:00:00 2001 From: Mihaela Stoica Date: Wed, 21 Aug 2019 11:43:11 +0100 Subject: [PATCH] =?UTF-8?q?CP-31527:=20Add=20notifications=20in=20XenCente?= =?UTF-8?q?r=20for=20versions=20that=20are=20no=20lon=E2=80=A6=20(#2486)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit CP-31527: Add notifications in XenCenter for versions that are no longer eligible for hotfixes Signed-off-by: Mihaela Stoica --- .../Alerts/Types/HotfixEligibilityAlert.cs | 131 ++++++++++++++ XenAdmin/Core/Updates.cs | 33 ++++ XenAdmin/Help/HelpManager.resx | 163 +++++++++--------- XenAdmin/MainWindow.cs | 2 + XenAdmin/TabPages/GeneralTabPage.cs | 39 ++++- XenAdmin/XenAdmin.csproj | 1 + .../AlertTests/XenServerUpdateAlertTests.cs | 8 +- .../Updates/DownloadUpdatesXmlAction.cs | 15 +- XenModel/Actions/Updates/XenServerVersion.cs | 30 +++- XenModel/Messages.Designer.cs | 99 +++++++++++ XenModel/Messages.resx | 33 ++++ 11 files changed, 466 insertions(+), 88 deletions(-) create mode 100644 XenAdmin/Alerts/Types/HotfixEligibilityAlert.cs diff --git a/XenAdmin/Alerts/Types/HotfixEligibilityAlert.cs b/XenAdmin/Alerts/Types/HotfixEligibilityAlert.cs new file mode 100644 index 000000000..22c873e9c --- /dev/null +++ b/XenAdmin/Alerts/Types/HotfixEligibilityAlert.cs @@ -0,0 +1,131 @@ +/* Copyright (c) Citrix Systems, Inc. + * All rights reserved. + * + * Redistribution and use in source and binary forms, + * with or without modification, are permitted provided + * that the following conditions are met: + * + * * Redistributions of source code must retain the above + * copyright notice, this list of conditions and the + * following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the + * following disclaimer in the documentation and/or other + * materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND + * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +using System; +using XenAdmin.Core; +using XenAdmin.Network; +using XenAPI; + +namespace XenAdmin.Alerts.Types +{ + public class HotfixEligibilityAlert: Alert + { + private readonly Pool pool; + private readonly XenServerVersion version; + + public HotfixEligibilityAlert(IXenConnection connection, XenServerVersion version) + { + Connection = connection; + this.version = version; + pool = Helpers.GetPoolOfOne(connection); + _timestamp = DateTime.Now; + } + + #region Overrides of Alert + + public override string Title + { + get + { + if (pool == null || version == null) + return string.Empty; + + var productVersionText = string.Format(Messages.STRING_SPACE_STRING, + Helpers.NaplesOrGreater(Connection) ? Messages.XENSERVER : Messages.XENSERVER_LEGACY, + Helpers.GetMaster(Connection)?.ProductVersionText()); + + switch (version.HotfixEligibility) + { + case hotfix_eligibility.premium: + return string.Format(Messages.HOTFIX_ELIGIBILITY_ALERT_TITLE_FREE, productVersionText); + case hotfix_eligibility.cu: + return pool.IsFreeLicenseOrExpired() + ? string.Format(Messages.HOTFIX_ELIGIBILITY_ALERT_TITLE_FREE, productVersionText) + : Messages.HOTFIX_ELIGIBILITY_ALERT_TITLE_CU; + case hotfix_eligibility.none: + return string.Format(Messages.HOTFIX_ELIGIBILITY_ALERT_TITLE_EOL, productVersionText); + default: + return string.Empty; + } + } + } + + public override string Description + { + get + { + if (pool == null) + return string.Empty; + + var versionText = Helpers.GetMaster(Connection)?.ProductVersionText(); + var productVersionText = string.Format(Messages.STRING_SPACE_STRING, + Helpers.NaplesOrGreater(Connection) ? Messages.XENSERVER : Messages.XENSERVER_LEGACY, + versionText); + + switch (version.HotfixEligibility) + { + case hotfix_eligibility.premium: + return string.Format(Messages.HOTFIX_ELIGIBILITY_ALERT_DESCRIPTION_FREE, productVersionText, HelpersGUI.DateTimeToString(version.HotfixEligibilityPremiumDate.ToLocalTime(), Messages.DATEFORMAT_DMY, true)); + case hotfix_eligibility.cu: + return pool.IsFreeLicenseOrExpired() + ? string.Format(Messages.HOTFIX_ELIGIBILITY_ALERT_DESCRIPTION_FREE, productVersionText, HelpersGUI.DateTimeToString(version.HotfixEligibilityPremiumDate.ToLocalTime(), Messages.DATEFORMAT_DMY, true)) + : string.Format(Messages.HOTFIX_ELIGIBILITY_ALERT_DESCRIPTION_CU, productVersionText, HelpersGUI.DateTimeToString(version.HotfixEligibilityNoneDate.ToLocalTime(), Messages.DATEFORMAT_DMY, true), versionText); + case hotfix_eligibility.none: + return pool.IsFreeLicenseOrExpired() + ? string.Format(Messages.HOTFIX_ELIGIBILITY_ALERT_DESCRIPTION_EOL_FREE, productVersionText, HelpersGUI.DateTimeToString(version.EolDate.ToLocalTime(), Messages.DATEFORMAT_DMY, true)) + : string.Format(Messages.HOTFIX_ELIGIBILITY_ALERT_DESCRIPTION_EOL, productVersionText, HelpersGUI.DateTimeToString(version.HotfixEligibilityNoneDate.ToLocalTime(), Messages.DATEFORMAT_DMY, true)); + default: + return string.Empty; + } + } + } + + public override AlertPriority Priority => AlertPriority.Priority3; + + public override string AppliesTo => Helpers.GetName(Helpers.GetPoolOfOne(Connection)); + + public override string FixLinkText => null; + + public override Action FixLinkAction => null; + + public override string HelpID => "HotfixEligibilityAlert"; + + public override bool Equals(Alert other) + { + if (other is HotfixEligibilityAlert alert) + { + return Connection == alert.Connection; + } + return base.Equals(other); + } + #endregion + } +} diff --git a/XenAdmin/Core/Updates.cs b/XenAdmin/Core/Updates.cs index dd90d2321..049e638c8 100644 --- a/XenAdmin/Core/Updates.cs +++ b/XenAdmin/Core/Updates.cs @@ -41,6 +41,7 @@ using System.Diagnostics; using System.Windows.Forms; using XenAdmin.Dialogs; using System.Text; +using XenAdmin.Alerts.Types; using XenCenterLib; namespace XenAdmin.Core @@ -943,5 +944,37 @@ namespace XenAdmin.Core return null; return FindPatchAlert(p => p.Name.Equals(patchName, StringComparison.OrdinalIgnoreCase)); } + + public static hotfix_eligibility HotfixEligibility(Host host, out XenServerVersion xenServerVersion) + { + xenServerVersion = null; + if (XenServerVersions == null) + return hotfix_eligibility.all; + + xenServerVersion = GetServerVersions(host, XenServerVersions).FirstOrDefault(); + + return xenServerVersion?.HotfixEligibility ?? hotfix_eligibility.all; + } + + public static void CheckHotfixEligibility(IXenConnection connection) + { + var master = Helpers.GetMaster(connection); + if (master == null) + return; + + var hotfixEligibility = HotfixEligibility(master, out var xenServerVersion); + + if (hotfixEligibility == hotfix_eligibility.all || + hotfixEligibility == hotfix_eligibility.premium && !master.IsFreeLicenseOrExpired()) + { + Alert.RemoveAlert(a => a.Connection != null && a.Connection.Equals(connection)); + return; + } + + var alert = new HotfixEligibilityAlert(connection, xenServerVersion); + + if (Alert.FindAlert(alert) == null) + Alert.AddAlert(alert); + } } } diff --git a/XenAdmin/Help/HelpManager.resx b/XenAdmin/Help/HelpManager.resx index 847c54ee5..1df9142a4 100644 --- a/XenAdmin/Help/HelpManager.resx +++ b/XenAdmin/Help/HelpManager.resx @@ -117,18 +117,18 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - rbac-join-domain - - - rbac-join-domain - hosts-add vgpu-add + + rbac-join-domain + + + rbac-join-domain + systemalerts @@ -249,6 +249,21 @@ resources-customfields + + intro-welcome + + + wlb-disable + + + hosts-disconnect + + + systemalerts + + + systemalerts + dr-config @@ -270,10 +285,10 @@ dr-testfailover - + dr-testfailover - + dr-testfailover @@ -294,10 +309,10 @@ dr-failback - + dr-failback - + dr-failback @@ -318,10 +333,10 @@ dr-failover - + dr-failover - + dr-failover @@ -330,21 +345,6 @@ dr-failover - - intro-welcome - - - wlb-disable - - - hosts-disconnect - - - systemalerts - - - systemalerts - systemalerts @@ -378,6 +378,12 @@ vms-properties + + pools-ha-config + + + vms-network-properties + 6536 @@ -390,12 +396,6 @@ vapps-properties - - pools-ha-config - - - vms-network-properties - pvs-read-cache @@ -474,24 +474,27 @@ pools-ha-about - - pools-ha-about - - - pools-ha-enable - pools-ha-config pools-ha-config + + pools-ha-about + + + pools-ha-enable + health-check health-check + + updates-about + vms-import @@ -570,9 +573,6 @@ dr-testfailover - - storage-pools-add-hba - licensing-about @@ -585,6 +585,9 @@ troubleshooting-eventlog + + storage-pools-add-hba + updates-applying @@ -624,12 +627,12 @@ systemalerts - - vms-relocate - vms-storage-move + + vms-relocate + resources-searching-saved @@ -759,15 +762,15 @@ vapps-create + + vapps-create + vapps-create vapps-create - - vapps-create - vms-network @@ -777,15 +780,15 @@ vms-new-template - - vms-new-cpu-memory - vms-new-media vms-new-cloudconfig + + vms-new-cpu-memory + vms-new-finish @@ -804,12 +807,12 @@ vms-new-media - - vms-new-media - vms-new-networking + + vms-new-media + vms-new @@ -915,6 +918,9 @@ upgrade + + upgrade + upgrade @@ -924,9 +930,6 @@ upgrade - - upgrade - hosts-connect-save @@ -957,10 +960,10 @@ tabs - + tabs - + tabs @@ -984,12 +987,6 @@ intro-welcome - - tabs - - - hosts-nics - tabs @@ -999,15 +996,18 @@ vms-network + + tabs + + + hosts-nics + performance pvs-read-cache - - tabs - tabs @@ -1020,6 +1020,9 @@ tabs + + tabs + tabs @@ -1038,12 +1041,12 @@ resources-tagging - - tabs - intro-xencenterwindow + + tabs + wlb-get-started-help @@ -1056,6 +1059,9 @@ updates-applying + + vms-properties + vms-storage-move @@ -1065,21 +1071,15 @@ vapps-manage + + vms-snapshots-take + vms-snapshots-newtemplate vms-snapshotschedule-about - - vms-properties - - - vms-snapshots-take - - - wlb-reports-creating - cbt-overview @@ -1107,6 +1107,9 @@ wlb-placement-strategy-change + + wlb-reports-creating + wlb-reports-creating diff --git a/XenAdmin/MainWindow.cs b/XenAdmin/MainWindow.cs index d303f0403..f92d7c432 100755 --- a/XenAdmin/MainWindow.cs +++ b/XenAdmin/MainWindow.cs @@ -971,6 +971,7 @@ namespace XenAdmin Updates.CheckServerPatches(); Updates.CheckServerVersion(); + Updates.CheckHotfixEligibility(connection); HealthCheck.SendMetadataToHealthCheck(); RequestRefreshTreeView(); @@ -1124,6 +1125,7 @@ namespace XenAdmin case "license_params": UpdateHeader(); UpdateToolbars(); + Updates.CheckHotfixEligibility(host.Connection); break; case "other_config": // other_config may contain HideFromXenCenter diff --git a/XenAdmin/TabPages/GeneralTabPage.cs b/XenAdmin/TabPages/GeneralTabPage.cs index 4bdbe3604..f2c4b9310 100644 --- a/XenAdmin/TabPages/GeneralTabPage.cs +++ b/XenAdmin/TabPages/GeneralTabPage.cs @@ -1084,7 +1084,15 @@ namespace XenAdmin.TabPages if (!Helpers.ElyOrGreater(host) && host.software_version.ContainsKey("build_number")) pdSectionVersion.AddEntry(Messages.SOFTWARE_VERSION_BUILD_NUMBER, host.software_version["build_number"]); if (host.software_version.ContainsKey("product_version")) - pdSectionVersion.AddEntry(Messages.SOFTWARE_VERSION_PRODUCT_VERSION, host.ProductVersionText()); + { + var hotfixEligibilityString = AdditionalVersionString(host); + if (string.IsNullOrEmpty(hotfixEligibilityString)) + pdSectionVersion.AddEntry(Messages.SOFTWARE_VERSION_PRODUCT_VERSION, host.ProductVersionText()); + else + pdSectionVersion.AddEntry(Messages.SOFTWARE_VERSION_PRODUCT_VERSION, + string.Format(Messages.MAINWINDOW_CONTEXT_REASON, host.ProductVersionText(), hotfixEligibilityString), + Color.Red); + } if (host.software_version.ContainsKey("dbv")) pdSectionVersion.AddEntry("DBV", host.software_version["dbv"]); } @@ -1329,7 +1337,13 @@ namespace XenAdmin.TabPages { if (p.IsPoolFullyUpgraded()) { - s.AddEntry(Messages.SOFTWARE_VERSION_PRODUCT_VERSION, master.ProductVersionText()); + var hotfixEligibilityString = AdditionalVersionString(master); + if (string.IsNullOrEmpty(hotfixEligibilityString)) + s.AddEntry(Messages.SOFTWARE_VERSION_PRODUCT_VERSION, master.ProductVersionText()); + else + s.AddEntry(Messages.SOFTWARE_VERSION_PRODUCT_VERSION, + string.Format(Messages.MAINWINDOW_CONTEXT_REASON, master.ProductVersionText(), hotfixEligibilityString), + Color.Red); } else { @@ -1380,6 +1394,27 @@ namespace XenAdmin.TabPages } } + private string AdditionalVersionString(Host host) + { + var hotfixEligibility = Updates.HotfixEligibility(host, out var xenServerVersion); + + switch (hotfixEligibility) + { + case hotfix_eligibility.premium: + return host.IsFreeLicenseOrExpired() + ? string.Format(Messages.HOTFIX_ELIGIBILITY_WARNING_FREE, HelpersGUI.DateTimeToString(xenServerVersion.HotfixEligibilityPremiumDate.ToLocalTime(), Messages.DATEFORMAT_DMY, true)) + : string.Empty; + case hotfix_eligibility.cu: + return host.IsFreeLicenseOrExpired() + ? string.Format(Messages.HOTFIX_ELIGIBILITY_WARNING_FREE, HelpersGUI.DateTimeToString(xenServerVersion.HotfixEligibilityPremiumDate.ToLocalTime(), Messages.DATEFORMAT_DMY, true)) + : string.Format(Messages.HOTFIX_ELIGIBILITY_WARNING_CU, HelpersGUI.DateTimeToString(xenServerVersion.HotfixEligibilityNoneDate.ToLocalTime(), Messages.DATEFORMAT_DMY, true)); + case hotfix_eligibility.none: + return string.Format(Messages.HOTFIX_ELIGIBILITY_WARNING_EOL, HelpersGUI.DateTimeToString(xenServerVersion.EolDate.ToLocalTime(), Messages.DATEFORMAT_DMY, true)); + default: + return string.Empty; + } + } + private static void GenerateVirtualisationStatusForGeneralBox(PDSection s, VM vm) { if (vm != null && vm.Connection != null) diff --git a/XenAdmin/XenAdmin.csproj b/XenAdmin/XenAdmin.csproj index a6827438b..8f87cc188 100755 --- a/XenAdmin/XenAdmin.csproj +++ b/XenAdmin/XenAdmin.csproj @@ -100,6 +100,7 @@ + diff --git a/XenAdminTests/UnitTests/AlertTests/XenServerUpdateAlertTests.cs b/XenAdminTests/UnitTests/AlertTests/XenServerUpdateAlertTests.cs index 36ad0baee..cdbe83e12 100644 --- a/XenAdminTests/UnitTests/AlertTests/XenServerUpdateAlertTests.cs +++ b/XenAdminTests/UnitTests/AlertTests/XenServerUpdateAlertTests.cs @@ -54,7 +54,7 @@ namespace XenAdminTests.UnitTests.AlertTests [Test] public void TestAlertWithConnectionAndHosts() { - XenServerVersion ver = new XenServerVersion("1.2.3", "name", true, false, "http://url", new List(), new List(), new DateTime(2011, 4, 1).ToString(), "123", "", false, ""); + XenServerVersion ver = new XenServerVersion("1.2.3", "name", true, false, "http://url", new List(), new List(), new DateTime(2011, 4, 1).ToString(), "123", "", false, "", "", "", "", ""); var alert = new XenServerVersionAlert(ver); alert.IncludeConnection(connA.Object); alert.IncludeConnection(connB.Object); @@ -80,7 +80,7 @@ namespace XenAdminTests.UnitTests.AlertTests [Test] public void TestAlertWithHostsAndNoConnection() { - XenServerVersion ver = new XenServerVersion("1.2.3", "name", true, false, "http://url", new List(), new List(), new DateTime(2011, 4, 1).ToString(), "123", "", false, ""); + XenServerVersion ver = new XenServerVersion("1.2.3", "name", true, false, "http://url", new List(), new List(), new DateTime(2011, 4, 1).ToString(), "123", "", false, "", "", "", "", ""); var alert = new XenServerVersionAlert(ver); alert.IncludeHosts(new List { hostA.Object, hostB.Object }); @@ -104,7 +104,7 @@ namespace XenAdminTests.UnitTests.AlertTests [Test] public void TestAlertWithConnectionAndNoHosts() { - XenServerVersion ver = new XenServerVersion("1.2.3", "name", true, false, "http://url", new List(), new List(), new DateTime(2011, 4, 1).ToString(), "123", "", false, ""); + XenServerVersion ver = new XenServerVersion("1.2.3", "name", true, false, "http://url", new List(), new List(), new DateTime(2011, 4, 1).ToString(), "123", "", false, "", "", "", "", ""); var alert = new XenServerVersionAlert(ver); alert.IncludeConnection(connA.Object); alert.IncludeConnection(connB.Object); @@ -129,7 +129,7 @@ namespace XenAdminTests.UnitTests.AlertTests [Test] public void TestAlertWithNoConnectionAndNoHosts() { - XenServerVersion ver = new XenServerVersion("1.2.3", "name", true, false, "http://url", new List(), new List(), new DateTime(2011, 4, 1).ToString(), "123", "", false, ""); + XenServerVersion ver = new XenServerVersion("1.2.3", "name", true, false, "http://url", new List(), new List(), new DateTime(2011, 4, 1).ToString(), "123", "", false, "", "", "", "", ""); var alert = new XenServerVersionAlert(ver); ClassVerifiers.VerifyGetters(alert, new AlertClassUnitTestData diff --git a/XenModel/Actions/Updates/DownloadUpdatesXmlAction.cs b/XenModel/Actions/Updates/DownloadUpdatesXmlAction.cs index 9f3ea84fd..192b8d894 100644 --- a/XenModel/Actions/Updates/DownloadUpdatesXmlAction.cs +++ b/XenModel/Actions/Updates/DownloadUpdatesXmlAction.cs @@ -252,6 +252,11 @@ namespace XenAdmin.Actions string patchUuid = ""; bool presentAsUpdate = false; string minXcVersion = ""; + string hotfixEligibility = ""; + string hotfixEligibilityPremiumDate = ""; + string hotfixEligibilityNoneDate = ""; + string eolDate = ""; + foreach (XmlAttribute attrib in version.Attributes) { @@ -275,6 +280,14 @@ namespace XenAdmin.Actions presentAsUpdate = attrib.Value.ToUpperInvariant() == bool.TrueString.ToUpperInvariant(); else if (attrib.Name == "minimum-xc-version") minXcVersion = attrib.Value; + else if (attrib.Name == "hotfix-eligibility") + hotfixEligibility = attrib.Value; + else if (attrib.Name == "hotfix-eligibility-premium-date") + hotfixEligibilityPremiumDate = attrib.Value; + else if (attrib.Name == "hotfix-eligibility-none-date") + hotfixEligibilityNoneDate = attrib.Value; + else if (attrib.Name == "eol-date") + eolDate = attrib.Value; } List patches = new List(); @@ -310,7 +323,7 @@ namespace XenAdmin.Actions } XenServerVersions.Add(new XenServerVersion(version_oem, name, is_latest, is_latest_cr, url, patches, minimalPatches, timestamp, - buildNumber, patchUuid, presentAsUpdate, minXcVersion)); + buildNumber, patchUuid, presentAsUpdate, minXcVersion, hotfixEligibility, hotfixEligibilityPremiumDate, hotfixEligibilityNoneDate, eolDate)); } } } diff --git a/XenModel/Actions/Updates/XenServerVersion.cs b/XenModel/Actions/Updates/XenServerVersion.cs index d82fa568a..bfdbbd559 100644 --- a/XenModel/Actions/Updates/XenServerVersion.cs +++ b/XenModel/Actions/Updates/XenServerVersion.cs @@ -47,6 +47,10 @@ namespace XenAdmin.Core public string PatchUuid; public bool PresentAsUpdate; public Version MinimumXcVersion; + public hotfix_eligibility HotfixEligibility; + public DateTime HotfixEligibilityPremiumDate; + public DateTime HotfixEligibilityNoneDate; + public DateTime EolDate; /// /// A host of this version is considered up-to-date when it has all the patches in this list installed on it @@ -72,7 +76,8 @@ namespace XenAdmin.Core /// /// Indicates that the new version (usually a CU) should be presented as an update where possible public XenServerVersion(string version_oem, string name, bool latest, bool latestCr, string url, List patches, List minimumPatches, - string timestamp, string buildNumber, string patchUuid, bool presentAsUpdate, string minXcVersion) + string timestamp, string buildNumber, string patchUuid, bool presentAsUpdate, string minXcVersion, string hotfixEligibility, string hotfixEligibilityPremiumDate, + string HotfixEligibilityNoneDate, string eolDate) { ParseVersion(version_oem); Name = name; @@ -86,6 +91,10 @@ namespace XenAdmin.Core PatchUuid = patchUuid; PresentAsUpdate = presentAsUpdate; ParseMinXcVersion(minXcVersion); + Enum.TryParse(hotfixEligibility, out HotfixEligibility); + DateTime.TryParse(hotfixEligibilityPremiumDate, out HotfixEligibilityPremiumDate); + DateTime.TryParse(HotfixEligibilityNoneDate, out this.HotfixEligibilityNoneDate); + DateTime.TryParse(eolDate, out EolDate); } private void ParseVersion(string version_oem) @@ -115,6 +124,25 @@ namespace XenAdmin.Core return !string.IsNullOrEmpty(PatchUuid); } } + } + public enum hotfix_eligibility + { + /// + /// All customers are eligible for hotfixes. + /// + all, + /// + /// Only paying customers are eligible for hotfixes. + /// + premium, + /// + /// The only hotfix available is a Cumulative Update, for paying customers. + /// + cu, + /// + /// The version has reached EOL for all customers and no more hotfixes will be released. + /// + none } } \ No newline at end of file diff --git a/XenModel/Messages.Designer.cs b/XenModel/Messages.Designer.cs index e9a54d598..7c08fa904 100755 --- a/XenModel/Messages.Designer.cs +++ b/XenModel/Messages.Designer.cs @@ -18662,6 +18662,96 @@ namespace XenAdmin { } } + /// + /// Looks up a localized string similar to A new Cumulative Update is available for {0}. After {1} there will be no further hotfixes released for {2}. Please update to the latest Cumulative Update.. + /// + public static string HOTFIX_ELIGIBILITY_ALERT_DESCRIPTION_CU { + get { + return ResourceManager.GetString("HOTFIX_ELIGIBILITY_ALERT_DESCRIPTION_CU", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to {0} reached End of Life on {1}. There will be no further hotfixes released after this date. Please upgrade to the latest supported version.. + /// + public static string HOTFIX_ELIGIBILITY_ALERT_DESCRIPTION_EOL { + get { + return ResourceManager.GetString("HOTFIX_ELIGIBILITY_ALERT_DESCRIPTION_EOL", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to {0} reached End of Life on {1}. There will be no further hotfixes released after this date. Please upgrade to the latest CR.. + /// + public static string HOTFIX_ELIGIBILITY_ALERT_DESCRIPTION_EOL_FREE { + get { + return ResourceManager.GetString("HOTFIX_ELIGIBILITY_ALERT_DESCRIPTION_EOL_FREE", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to {0} reached End of Life for express customers on {1}. You are no longer eligible for hotfixes released after this date. Please upgrade to the latest CR.. + /// + public static string HOTFIX_ELIGIBILITY_ALERT_DESCRIPTION_FREE { + get { + return ResourceManager.GetString("HOTFIX_ELIGIBILITY_ALERT_DESCRIPTION_FREE", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to A new Cumulative Update is available. + /// + public static string HOTFIX_ELIGIBILITY_ALERT_TITLE_CU { + get { + return ResourceManager.GetString("HOTFIX_ELIGIBILITY_ALERT_TITLE_CU", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to {0} has reached End of Life. + /// + public static string HOTFIX_ELIGIBILITY_ALERT_TITLE_EOL { + get { + return ResourceManager.GetString("HOTFIX_ELIGIBILITY_ALERT_TITLE_EOL", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to {0} has reached End of Life for express customers. + /// + public static string HOTFIX_ELIGIBILITY_ALERT_TITLE_FREE { + get { + return ResourceManager.GetString("HOTFIX_ELIGIBILITY_ALERT_TITLE_FREE", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to No further hotfixes released after {0}. + /// + public static string HOTFIX_ELIGIBILITY_WARNING_CU { + get { + return ResourceManager.GetString("HOTFIX_ELIGIBILITY_WARNING_CU", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to End of Life on {0}. + /// + public static string HOTFIX_ELIGIBILITY_WARNING_EOL { + get { + return ResourceManager.GetString("HOTFIX_ELIGIBILITY_WARNING_EOL", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to Not eligible for hotfixes released after {0}. + /// + public static string HOTFIX_ELIGIBILITY_WARNING_FREE { + get { + return ResourceManager.GetString("HOTFIX_ELIGIBILITY_WARNING_FREE", resourceCulture); + } + } + /// /// Looks up a localized string similar to Hourly; at {0} minutes past each hour. /// @@ -40699,6 +40789,15 @@ namespace XenAdmin { } } + /// + /// Looks up a localized string similar to [Legacy XenServer product]. + /// + public static string XENSERVER_LEGACY { + get { + return ResourceManager.GetString("XENSERVER_LEGACY", resourceCulture); + } + } + /// /// Looks up a localized string similar to [XenServer] Templates. /// diff --git a/XenModel/Messages.resx b/XenModel/Messages.resx index 09e65a63f..a9bba9453 100755 --- a/XenModel/Messages.resx +++ b/XenModel/Messages.resx @@ -6524,6 +6524,36 @@ This might result in failure to migrate VMs to this server during the RPU or to Hotfix check + + A new Cumulative Update is available for {0}. After {1} there will be no further hotfixes released for {2}. Please update to the latest Cumulative Update. + + + {0} reached End of Life on {1}. There will be no further hotfixes released after this date. Please upgrade to the latest supported version. + + + {0} reached End of Life on {1}. There will be no further hotfixes released after this date. Please upgrade to the latest CR. + + + {0} reached End of Life for express customers on {1}. You are no longer eligible for hotfixes released after this date. Please upgrade to the latest CR. + + + A new Cumulative Update is available + + + {0} has reached End of Life + + + {0} has reached End of Life for express customers + + + No further hotfixes released after {0} + + + End of Life on {0} + + + Not eligible for hotfixes released after {0} + Hourly; at {0} minutes past each hour @@ -14038,6 +14068,9 @@ Are you sure you want to enable automated power management for this Host? [XenServer] [BRANDING_VERSION_6_5] + + [Legacy XenServer product] + [XenServer] Templates