summaryrefslogtreecommitdiff
path: root/nova/exception.py
diff options
context:
space:
mode:
authorYongli He <yonglihe@intel.com>2021-03-11 07:26:31 +0000
committerYongli He <yongli.he@intel.com>2021-08-05 15:58:41 +0800
commit1f53176d2f4303b909ecad18cb0f027bfcd0b7ae (patch)
tree5f47aaf9ecc5712d30ad16005acbc57dd9f54955 /nova/exception.py
parente19fa1a1997c6d18d440dcdc5a0732b7e2467fa5 (diff)
downloadnova-1f53176d2f4303b909ecad18cb0f027bfcd0b7ae.tar.gz
smartnic support - reject server move and suspend
Server with ARQ in the port does not support move and suspend, reject these operations in API stage: - resize - shelve - live_migrate - evacuate - suspend - attach/detach a smartnic port Reject create server with smartnic in port if minimal compute service version less than 57 Reject create server with port which have a malformed device profile that request multi devices, like: { "resources:CUSTOM_ACCELERATOR_FPGA": "2", "trait:CUSTOM_INTEL_PAC_ARRIA10": "required", } Implements: blueprint sriov-smartnic-support Change-Id: Ia705a0341fb067e746a3b91ec4fc6d149bcaffb8
Diffstat (limited to 'nova/exception.py')
-rw-r--r--nova/exception.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/nova/exception.py b/nova/exception.py
index f5e393e5a6..7a20385492 100644
--- a/nova/exception.py
+++ b/nova/exception.py
@@ -159,6 +159,10 @@ class ForbiddenWithAccelerators(Forbidden):
msg_fmt = _("Forbidden with instances that have accelerators.")
+class ForbiddenPortsWithAccelerator(Forbidden):
+ msg_fmt = _("Forbidden with Ports that have accelerators.")
+
+
class AdminRequired(Forbidden):
msg_fmt = _("User does not have admin privileges")