aboutsummaryrefslogtreecommitdiffstats
path: root/python_moonutilities/python_moonutilities/exceptions.py
diff options
context:
space:
mode:
authorThomas Duval <thomas.duval@orange.com>2018-01-05 16:28:07 +0100
committerThomas Duval <thomas.duval@orange.com>2018-01-08 09:32:19 +0100
commit48857b80be18bb0985aab643f5c8c899194d636b (patch)
tree649feb37d8c2c0dd672aad4ce4a38365cd79f4dd /python_moonutilities/python_moonutilities/exceptions.py
parent646e77e86cd220f4be02110b16ce802d85c35b27 (diff)
prevent the mapping N*PDP <=> 1*Keystone_project
Change-Id: Ia43d7fb2a2c8054e9cf492395f2e3ef396d184cf
Diffstat (limited to 'python_moonutilities/python_moonutilities/exceptions.py')
-rw-r--r--python_moonutilities/python_moonutilities/exceptions.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/python_moonutilities/python_moonutilities/exceptions.py b/python_moonutilities/python_moonutilities/exceptions.py
index 5b9ff340..2d689287 100644
--- a/python_moonutilities/python_moonutilities/exceptions.py
+++ b/python_moonutilities/python_moonutilities/exceptions.py
@@ -504,6 +504,7 @@ class ConsulComponentNotFound(ConsulError):
title = 'Consul error'
logger = "WARNING"
+
class ConsulComponentContentError(ConsulError):
description = _("invalid content of component .")
code = 500
@@ -541,6 +542,13 @@ class PdpExisting(MoonError):
logger = "Error"
+class PdpKeystoneMappingConflict(MoonError):
+ description = _("A pdp is already mapped to that Keystone project.")
+ code = 409
+ title = 'Pdp Mapping Error'
+ logger = "Error"
+
+
class PolicyUnknown(MoonError):
description = _("The policy is unknown.")
code = 400