aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lcm/v2/serializers.py35
1 files changed, 28 insertions, 7 deletions
diff --git a/lcm/v2/serializers.py b/lcm/v2/serializers.py
index 2f7ae333..eee7a9cb 100644
--- a/lcm/v2/serializers.py
+++ b/lcm/v2/serializers.py
@@ -122,6 +122,24 @@ class VimConstraintSerializer(serializers.Serializer):
)
+class LinkSerializer(serializers.Serializer):
+ href = serializers.CharField(
+ help_text="URI of the referenced resource.",
+ required=True
+ )
+
+
+class GrantRequestLinksSerializer(serializers.Serializer):
+ vnfLcmOpOcc = LinkSerializer(
+ help_text="Related VNF lifecycle management operation occurrence.",
+ required=True
+ )
+ vnfInstance = LinkSerializer(
+ help_text="Related VNF instance.",
+ required=True
+ )
+
+
class GrantRequestSerializer(serializers.Serializer):
vnfInstanceId = serializers.CharField(
help_text="Identifier of the VNF instance which this grant request is related to.",
@@ -184,6 +202,16 @@ class GrantRequestSerializer(serializers.Serializer):
help_text="Used by the VNFM to require that multiple resources are managed through the same VIM connection.",
many=True
)
+ additionalParams = serializers.DictField(
+ help_text="Additional parameters passed by the VNFM.",
+ child=serializers.CharField(help_text="KeyValue Pairs", allow_blank=True),
+ required=False,
+ allow_null=True
+ )
+ _links = GrantRequestLinksSerializer(
+ help_text="Links to resources related to this request.",
+ required=True
+ )
class VimConnectionInfoSerializer(serializers.Serializer):
@@ -524,13 +552,6 @@ class ExtManagedVirtualLinkDataSerializer(serializers.Serializer):
)
-class LinkSerializer(serializers.Serializer):
- href = serializers.CharField(
- help_text="URI of the referenced resource.",
- required=True
- )
-
-
class GrantLinksSerializer(serializers.Serializer):
self = LinkSerializer(
help_text="URI of this resource.",