Commit Graph

4929 Commits

Author SHA1 Message Date
Mihaela Stoica
f7b27ec222
Merge pull request #1994 from xenserver/REQ-477
Merge REQ-477 into master
2018-03-19 13:23:19 +00:00
Cheng Zhang
76365e9dec CA-286093: Refine VIF hotplug error message
VIF hotplug actully needs a shutdown and restart to take effect. Change the error message.

Signed-off-by: Cheng Zhang <cheng.zhang@citrix.com>
2018-03-16 14:03:24 +00:00
Mihaela Stoica
713877b49e CA-285268: Code simplification
Signed-off-by: Mihaela Stoica <mihaela.stoica@citrix.com>
2018-03-16 14:00:07 +00:00
jishengx
0c13d8786d CA-274082: Check status of SR uploaded updates during update installa… (#1937)
* CA-274082: Check status of SR uploaded updates during update installation
* fix review comments

Signed-off-by: Jisheng Xing <jisheng.xing@citrix.com>
2018-03-14 12:19:14 +00:00
Mihaela Stoica
f64fd58970 CA-285268: Patching Wizard improvement: Read metadata from the update file, instead of relying on the file name to match the update name in cfu
Signed-off-by: Mihaela Stoica <mihaela.stoica@citrix.com>
2018-03-14 12:12:18 +00:00
Joey
c9214af05f CA-284325: fix double sign bug (#1984)
* CA-284325: Fix 3rd party libs are not signed
* Modify description text

Signed-off-by: Ji Jiang <ji.jiang@citrix.com>
2018-03-13 15:55:30 +00:00
Mihaela Stoica
e13051ba23
Update DOTNET_BUILD_LOCATION_CTXSIGN 2018-03-12 10:49:14 +00:00
Konstantina Chremmou
2f6b6d3823 Create the manifest file at the end of the build when the output folder is in place (hence no folder creation is necessary).
Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-12 10:19:04 +00:00
Konstantina Chremmou
d69f2ddda3 Enforce treating warnings as errors in Debug mode too as it is going to save
us a lot of broken builds. Fixed bug where the HostPlanAction.CurrentHost was
always null (as the private field was never set).

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-09 11:22:26 +00:00
Konstantina Chremmou
ee648135f6 Since it is easy to forget calling the base class method at the beginning of the
PageLoaded override in derived classes, enforce it by wrapping the page specific
code in a new virtual method, which the derived classes can override and PageLoaded
can call after its own logic.

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-09 11:22:26 +00:00
Konstantina Chremmou
7a1b1a6dcc Since it is easy to forget calling the base class method at the end of the PageLeave
override in derived classes, enforce it by wrapping the page specific code in
a new virtual method, which the derived classes can override and PageLeave can
call before its own logic.

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-09 11:22:26 +00:00
Konstantina Chremmou
2b8bf70ee5 CA-272769: Call the base class method in the end of the PageLeave override, so the
WizardContentUpdater is invoked and information flows from the SelectInstallMethod
page to the following pages.

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-09 11:22:26 +00:00
Konstantina Chremmou
a8b831fab9 Simplified check as per code review.
Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-09 11:22:26 +00:00
Mihaela Stoica
0184470ea3
Merge pull request #1968 from kc284/master
CA-284125: Automated updates should prioritise a pending host restart to a mandatory xapi restart
2018-03-08 15:54:39 +00:00
Michael
a4aaeb1165 CA-272150: Optimize destination page of cross-pool-migrate wizard. (#1941)
* CA-272150: Optimize destination page of cross-pool-migrate wizard.

Signed-off-by: Michael Zhao <michael.zhao@citrix.com>
2018-03-08 13:22:38 +00:00
Konstantina Chremmou
9e3a9abfa0 Resolve host before querying its properties.
Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-08 11:34:00 +00:00
Konstantina Chremmou
34ec571fa1 Return null if the string to deserialize to a XenRef<T> is null. This can
happen for calls returning a XenRef<T> when the server is using the JsonRpc
v1.0 and we have an error, in which case the result is null. Similarly, return
DateTime.MinValue when the datetime string is null (or in general unparasable).

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-08 10:17:12 +00:00
Konstantina Chremmou
b3828ef452 Added parameter enableOnly defaulting to false to the RestartHostPlanAction
so as to be able to evacuate-reboot the host without bringing the VMs back.

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-07 17:50:51 +00:00
Mihaela Stoica
929ae78942 CA-284876: Process the VM parameter of the VM_FAILED_SHUTDOWN_ACKNOWLEDGMENT error on host evacuation
Signed-off-by: Mihaela Stoica <mihaela.stoica@citrix.com>
2018-03-07 11:28:57 +00:00
Konstantina Chremmou
4b6e826ed3 CA-284125: Prioritise a pending host restart over a mandatory toolstack restart.
For this purpose, the evacuate-reboot-bringbabiesback triplet was replaced by a
new RestartHostPlanAction, which allows fallback to toolstack restart if live
patching has succeeded. Also, created new abstract class HostPlanAction to
reduce code duplication.

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-06 15:12:04 +00:00
Konstantina Chremmou
de9b0c4d30 Revisited commit 3f2eed35a0 reverting Dictionary to
List in order to enforce the order of checks (the Dictionary is not guaranteed to
keep the order the items are added). Also, extra null check.

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-06 14:17:16 +00:00
Konstantina Chremmou
a22a9a41e3 A couple of small inefficiencies.
Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-06 14:17:16 +00:00
Konstantina Chremmou
7505bda9e3 Removed unused properties of UpdateProgressBackgroundWorker; store the number of
actions on creation instead of calculating it every time on access.

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-06 14:17:16 +00:00
Konstantina Chremmou
c5b0af533e Removed methods GetHostBootTime and GetHostAgentTime because they duplicated logic
in the Host extensions. Moved method TryResolveWithTimeout to the Connection class
where it is more relevant. Removed wrapper methods WaitForReboot and WaitForAgent
as they were not particularly useful.

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-06 14:17:16 +00:00
Konstantina Chremmou
ed4b131643 Removed unused code and old style custom delegates, and updated property notation.
Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-06 14:17:16 +00:00
Konstantina Chremmou
71e554cc39 Removed duplicate logic calculating VM groups from the WizardPages and moved it the Host class as extension methods.
Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-06 14:17:15 +00:00
Konstantina Chremmou
3171005d23 Removed redundant code in file.
Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-06 14:17:15 +00:00
serencorbett1
393f9d64b9 CA-284095: Fix sort-by creation date (#1966)
* CA-284095: Fix sort-by creation date

Signed-off-by: serenc <seren.corbett@citrix.com>
2018-03-06 13:07:22 +00:00
Kun Ma
f28322e5db CA-270999: Add registration to RestartManager
Signed-off-by: Kun Ma <kun.ma@citrix.com>
2018-03-06 09:36:05 +00:00
Konstantina Chremmou
058601f761 CA-279578: Update the Recheck/Resolve button state and error message visibility
alongside the wizard progress buttons. For this purpose, the separate UpdateControls
method was removed and the logic was moved in the EnableNext method. The OnPageUpdated
method that fires this is now called every time the checks start.

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-02 13:32:49 +00:00
Konstantina Chremmou
3f2eed35a0 Refactoring: use a dictionary to hold the list of generated checks; simplified calculation of progress percentage.
Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-03-02 13:32:49 +00:00
Mihaela Stoica
eaef678ca4
Merge pull request #1965 from MihaelaStoica/REQ-477
Merge master into REQ-477
2018-03-01 11:11:47 +00:00
Mihaela Stoica
be3a7b54d6 Add extra parameters to Cluster.pool_create
Signed-off-by: Mihaela Stoica <mihaela.stoica@citrix.com>
2018-02-28 16:42:30 +00:00
Konstantina Chremmou
ce8d7dde46 Try creating the parent tree if it doesn't exist.
Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-02-28 16:36:51 +00:00
Konstantina Chremmou
47523ce632 Renamed manifest files as Windows seem to single out 'manifest'.
Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-02-28 13:55:15 +00:00
Konstantina Chremmou
5529626ac5 CA-284234: Used patched version of Json.NET.
Also, fixed deserialization for errors on servers using JsonRpc v1.0.

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-02-28 11:05:29 +00:00
Mihaela Stoica
ff05fb698c Merge remote-tracking branch 'upstream/master' into REQ-477
Signed-off-by: Mihaela Stoica <mihaela.stoica@citrix.com>

# Conflicts:
#	XenModel/XenAPI/Auth.cs
#	XenModel/XenAPI/Blob.cs
#	XenModel/XenAPI/Bond.cs
#	XenModel/XenAPI/Console.cs
#	XenModel/XenAPI/Converters.cs
#	XenModel/XenAPI/Crashdump.cs
#	XenModel/XenAPI/DR_task.cs
#	XenModel/XenAPI/Event.cs
#	XenModel/XenAPI/Feature.cs
#	XenModel/XenAPI/GPU_group.cs
#	XenModel/XenAPI/Host.cs
#	XenModel/XenAPI/Host_cpu.cs
#	XenModel/XenAPI/Host_crashdump.cs
#	XenModel/XenAPI/Host_metrics.cs
#	XenModel/XenAPI/Host_patch.cs
#	XenModel/XenAPI/JsonRpcClient.cs
#	XenModel/XenAPI/LVHD.cs
#	XenModel/XenAPI/Maps.cs
#	XenModel/XenAPI/Message.cs
#	XenModel/XenAPI/Network.cs
#	XenModel/XenAPI/PBD.cs
#	XenModel/XenAPI/PCI.cs
#	XenModel/XenAPI/PGPU.cs
#	XenModel/XenAPI/PIF.cs
#	XenModel/XenAPI/PIF_metrics.cs
#	XenModel/XenAPI/PUSB.cs
#	XenModel/XenAPI/PVS_cache_storage.cs
#	XenModel/XenAPI/PVS_proxy.cs
#	XenModel/XenAPI/PVS_server.cs
#	XenModel/XenAPI/PVS_site.cs
#	XenModel/XenAPI/Pool.cs
#	XenModel/XenAPI/Pool_patch.cs
#	XenModel/XenAPI/Pool_update.cs
#	XenModel/XenAPI/Role.cs
#	XenModel/XenAPI/SDN_controller.cs
#	XenModel/XenAPI/SM.cs
#	XenModel/XenAPI/SR.cs
#	XenModel/XenAPI/Secret.cs
#	XenModel/XenAPI/Session.cs
#	XenModel/XenAPI/Subject.cs
#	XenModel/XenAPI/Task.cs
#	XenModel/XenAPI/Tunnel.cs
#	XenModel/XenAPI/USB_group.cs
#	XenModel/XenAPI/User.cs
#	XenModel/XenAPI/VBD.cs
#	XenModel/XenAPI/VBD_metrics.cs
#	XenModel/XenAPI/VDI.cs
#	XenModel/XenAPI/VGPU.cs
#	XenModel/XenAPI/VGPU_type.cs
#	XenModel/XenAPI/VIF.cs
#	XenModel/XenAPI/VIF_metrics.cs
#	XenModel/XenAPI/VLAN.cs
#	XenModel/XenAPI/VM.cs
#	XenModel/XenAPI/VMPP.cs
#	XenModel/XenAPI/VMSS.cs
#	XenModel/XenAPI/VM_appliance.cs
#	XenModel/XenAPI/VM_guest_metrics.cs
#	XenModel/XenAPI/VM_metrics.cs
#	XenModel/XenAPI/VTPM.cs
#	XenModel/XenAPI/VUSB.cs
#	XenModel/XenModel.csproj
2018-02-27 17:42:18 +00:00
Mihaela Stoica
9a8b55b9fd Update API bindings from the feature branch
Signed-off-by: Mihaela Stoica <mihaela.stoica@citrix.com>
2018-02-27 16:42:29 +00:00
Konstantina Chremmou
45f35ef099 CA-284233: New bindings to include a converter to serialize null values in string-string maps to empty strings.
Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-02-27 15:39:45 +00:00
serenc
c7ac86224a CA-282014: Patching wizard now deletes downloaded patch when wizard cancelled
Signed-off-by: serenc <seren.corbett@citrix.com>
2018-02-27 11:16:26 +00:00
Konstantina Chremmou
8207a25fc8 Reverted to use of the Marshalling methods, as the Hashtable values can often be null.
Also fixed regression within the Masrshalling methods to account for null
values, however I did not reinstate the checks for keys, because Hashtable
returns null if the key does not exist instead of throwing an exception.

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-02-26 15:48:29 +00:00
Konstantina Chremmou
4565eb584b Added option to also retrieve symbol files alongside the dlls.
Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-02-26 15:48:29 +00:00
serencorbett1
fccfc6b1ae CA-283656: Display Multipathing Capabilities of GFS2 SRs (#1949)
* CA-283656: Linked SM and SR
* CA-283656: Checks new SR_MULTIPATHABLE capability
* CA-283656: Changed properties into methods
* CA-283656: Change key

Signed-off-by: serenc <seren.corbett@citrix.com>
2018-02-26 13:25:39 +00:00
Konstantina Chremmou
9e43369ac1 Language level upgrade: removed params array creation.
Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-02-22 13:31:02 +00:00
Konstantina Chremmou
fb2defccbe CA-283697 part5: Create a new VBD and VM record, assign the necessary fields,
and only update the necessary fields from the OVF values; this is preferrable
to using the constructor from the Hashtable because the latter requires
unnecessary conversions to and from strings, and also fields missing from the
Hashtable are reset to null. Hardcoded strings are also error prone: the VBD
class does not have any field such as 'attachable' or 'vm_name_label' and the
fields 'storage-lock' and 'status-code' are in reality called 'storage_lock'
and 'status_code'.

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-02-22 13:31:02 +00:00
Konstantina Chremmou
1d54c96d4d CA-283697 part4: New set of API bindings which now expose:
- a new method to update an object from a Hashtable setting only the fields
  contained in the Hashtable.
- an improvement on the class constructor from Hashtable whereby the fields
  are initialised and only the ones contained in the Hashtable are set (this
  is also an improvement towards CA-97777).

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-02-22 13:31:02 +00:00
Konstantina Chremmou
5494436040 CA-283697 part3: Create a new VBD record and assign the necessary fields
instead of using the constructor from the Hashtable because this requires
unnecessary conversions to and from strings, and also fields missing from the
Hashtable are reset to null. Hardcoded strings are also error prone: the VBD
class does not have fields such as 'attachable' or 'vm_name_label'.

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-02-22 13:31:02 +00:00
Konstantina Chremmou
cdf9aec33b CA-283697 part2: Create a new VDI record and assign the necessary fields
instead of using the constructor from the Hashtable because this requires
unnecessary conversions to and from strings, and also fields missing from the
Hashtable are reset to null. Hardcoded strings are also error prone: the VDI
class has the field 'sharable', not 'shareable'.

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-02-22 13:31:02 +00:00
Konstantina Chremmou
edf968b27c CA-283697 part1: Create a new VIF record and assign the necessary fields,
instead of using the constructor from the Hashtable because this requires
unnecessary conversions to and from strings and also fields missing from the
Hashtable are reset to null.

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-02-22 13:31:02 +00:00
Konstantina Chremmou
b4956da8f1 Performance and workflow improvement:
- no need to register the XenObjects events with the ArchiveMaintainer since
what the handler does is not specific to this class; this can be done on the
Performance page where the events are also registered.
- set directly the ArchiveMaintainer's XenObject to the new value without
setting it intermediately to null as this causes a full data download event
if the object has not changed.

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
2018-02-22 10:18:18 +00:00