You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »

JSON schema is used to describe the attributes and values in the xApp descriptor JSON file. The xApp onboarding process verifies the types and values of the xApp parameters in the descriptor. If mismatches are found, xApp onboarding will return failure.

It is the xApp developers' responsibility to provide the correct schema JSON file that defines all the fields in the xApp descriptor.

Structure

The schema file includes the following required sections.

  • xapp_name: xapp_name is a string variable. properties are as follows.

        		"xapp_name": {
        			"$id": "#/properties/xapp_name",
        			"type": "string",
        			"title": "The xApp Name",
        			"default": "xapp",
        			"examples": [
        				"example_xapp"	
        			]
        		},
  • version: version is a string variable that follows the semantic versioning syntax.

        		"version": {
        			"$id": "#/properties/version",
        			"type": "string",
        			"title": "The xApp version",
        			"default": "1.0.0",
        			"examples": [
        				"1.0.0"	
        			],
        			"pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$"
        		},
  • containers: containers is a list of container objects that includes name of the container, container image name, registry, tag, entry command  and container http and rmr service ports. It has a structure of

    "containers": [
        {
            "name": "example_container_1",
            "image": {
                "registry": "example_image_registry_1",
                "name": "example_image_name_1",
                "tag": "example_image_tag_1"
            },
            "command": "example_command_1",
    		"ports":{
    			"http": 8080,
    			"rmr_data": 4560,
    			"rmr_route": 4561
    		}
        },
        {
            "name": "example_container_2",
            "image": {
                "registry": "example_image_registry_2",
                "name": "example_image_name_2",
                "tag": "example_image_tag_2"
            },
            "command": "example_command_2",
    		"ports":{
    			"http": 8080,
    			"rmr_data": 4560,
    			"rmr_route": 4561
    		}
        }
    ]
  • No labels