{
	"type": "object",
	"description": "This type represents a capacity threshold. It shall comply with the provisions defined in table 10.5.2.8-1.\n",
	"required": [
		"id",
		"objectInstanceId",
		"criteria",
		"callbackUri",
		"_links"
	],
	"properties": {
		"id": {
			"description": "An identifier with the intention of being globally unique.\n",
			"type": "string"
		},
		"objectInstanceId": {
			"description": "An identifier with the intention of being globally unique.\n",
			"type": "string"
		},
		"subObjectInstanceIds": {
			"description": "Identifiers of the sub-object instances of the measured object instance associate with this capacity threshold.\nIf this attribute is absent, measurements are taken for all sub-object instances of the measured object instance.\n",
			"type": "array",
			"items": {
				"description": "An identifier maintained by the VIM or other resource provider. It is expected to be unique within the VIM instance. Representation: string of variable length.\n",
				"type": "string"
			}
		},
		"criteria": {
			"type": "object",
			"description": "This type represents criteria that define a capacity threshold.\nIt shall comply with the provisions defined in table 10.5.3.3-1.\n",
			"required": [
				"capacityMetric",
				"thresholdType"
			],
			"properties": {
				"capacityMetric": {
					"description": "Defines the capacity metric for which the threshold applies.\n",
					"type": "object",
					"required": [
						"resourceType",
						"capacityMeasurementName",
						"capacityType"
					],
					"properties": {
						"resourceType": {
							"type": "string",
							"description": "The enumeration NfviCapacityResourceTypeEnumeration shall comply with the provisions in table 10.5.4.3-1.\n* VR_COMPUTE: For virtualised compute resource.\n* VR_NETWORK: For virtualised network resource.\n* VR_STORAGE: For virtualised storage resource.\n* HOST_COMPUTE: For host compute resource.\n",
							"enum": [
								"VR_COMPUTE",
								"VR_NETWORK",
								"VR_STORAGE",
								"HOST_COMPUTE"
							]
						},
						"capacityMeasurementName": {
							"description": "Name of the capacity measurement. Different resource types can have different associated capacity measurements,\ntypically associated to different sub-types of the resource type.\n",
							"type": "string"
						},
						"capacityType": {
							"description": "The type of capacity for the threshold.\nPermitted values:\n-\tTOTAL: for total capacity.\n-\tALLOCATED: for allocated/used capacity.\n-\tRESERVED: for reserved capacity.\n-\tAVAILABLE: for available capacity.\n",
							"type": "string",
							"enum": [
								"TOTAL",
								"ALLOCATED",
								"RESERVED",
								"AVAILABLE"
							]
						}
					}
				},
				"thresholdType": {
					"description": "Type of capacity threshold. This attribute determines which other attributes are present in the data structure.\nPermitted values:\n-\tSIMPLE: Single-valued static threshold.\nIn the present document, simple thresholds are defined. The definition of additional threshold types is left\nfor future specification.\n",
					"type": "string",
					"enum": [
						"SIMPLE"
					]
				},
				"simpleThresholdDetails": {
					"description": "Details of a simple threshold. Shall be present if thresholdType=\"SIMPLE\".\n",
					"type": "array",
					"items": {
						"type": "object",
						"required": [
							"thresholdValue",
							"hysteresis"
						],
						"properties": {
							"thresholdValue": {
								"description": "The threshold value. Shall be represented as a floating point number.\n",
								"type": "number"
							},
							"hysteresis": {
								"description": "The hysteresis of the threshold.\nShall be represented as a non-negative floating point number.\nA notification with crossing direction \"UP\" will be generated if the measured value reaches or\nexceeds \"thresholdValue\" + \"hysteresis\". A notification with crossing direction \"DOWN\" will be\ngenerated if the measured value reaches or undercuts \"thresholdValue\" - \"hysteresis\".\nThe hysteresis is defined to prevent storms of threshold crossing notifications.\nWhen processing a request to create a threshold, implementations should enforce a suitable minimum\nvalue for this attribute (e.g. override the value or reject the request).\n",
								"type": "number"
							}
						}
					}
				}
			}
		},
		"callbackUri": {
			"description": "String formatted according to IETF RFC 3986.\n",
			"type": "string",
			"format": "uri"
		},
		"_links": {
			"type": "object",
			"description": "Links for this resource.\n",
			"required": [
				"self"
			],
			"properties": {
				"self": {
					"description": "This type represents a link to a resource.\n",
					"type": "object",
					"required": [
						"href"
					],
					"properties": {
						"href": {
							"description": "URI of a resource referenced from a notification. Should be an absolute URI (i.e. a URI that contains {apiRoot}), however, may be a relative URI (i.e. a URI where the {apiRoot} part is omitted) if the {apiRoot} information is not available.\n",
							"type": "string",
							"format": "url"
						}
					}
				},
				"object": {
					"description": "This type represents a link to a resource.\n",
					"type": "object",
					"required": [
						"href"
					],
					"properties": {
						"href": {
							"description": "URI of a resource referenced from a notification. Should be an absolute URI (i.e. a URI that contains {apiRoot}), however, may be a relative URI (i.e. a URI where the {apiRoot} part is omitted) if the {apiRoot} information is not available.\n",
							"type": "string",
							"format": "url"
						}
					}
				}
			}
		}
	}
}