-
Notifications
You must be signed in to change notification settings - Fork 6
NetSlice Instance API description
In the previous Network Slice Manager (SONATA 4.0) the command to instantiate a Network SLice (based on a NST) had the following structure:
curl -i -H "Content-Type:application/json" -X POST -d'{"name": "_nsi-name_", "description": "_nsi-description_", "nstId": "_nstID_"}' http://{base_url}:5998/api/nsilcm/v1/nsi
Due to the evolution and necessity of an asynchronous communication with the Gatekeepr component, the current way to request an instantiation is with the following command, going through the Gatekeeper as described in this link:
http int-sp-ath.5gtango.eu:32002/api/v3/requests nst_id=<uuid_of_an_existing_NST> name="<nsi-name>" request_type=CREATE_SLICE description="<nsi-description>"
RESPONSE EXAMPLE
The response might take some time (depending on the Network Services deployment time), but if it goes well, it has to return a HTTP.value of 201 and the payload contains the created NSI object:
{
"5qiValue": 3,
"created_at": "2019-05-09T10:00:08.925+00:00",
"datacenter": "88888888-2222-3333-4444-888888888888",
"description": "description",
"errorLog": "",
"instantiateTime": "2019-05-09T10:00:07.791341",
"name": "9may_1",
"nsi-status": "INSTANTIATED",
"nsr-list": [
{
"isinstantiated": false,
"isshared": false,
"nsrId": "81cad6c2-86ee-40db-8291-63646c3a2474",
"nsrName": "9may_1-Service_subnet_1-1",
"requestId": "",
"sla-name": "None",
"sla-ref": "None",
"subnet-nsdId-ref": "f5100cbb-1c3b-466e-8b0d-5d30311a6b2c",
"subnet-ref": "Service_subnet_1",
"vimAccountId": "88888888-2222-3333-4444-888888888888",
"vld": [
{
"vld-ref": "mgmt"
},
{
"vld-ref": "slice_input"
}
],
"working-status": "INSTANTIATED"
},
{
"isinstantiated": false,
"isshared": true,
"nsrId": "767dfa91-a741-4bd2-a140-2470f24e1d94",
"nsrName": "9may_1-Service_subnet_2-2",
"requestId": "",
"sla-name": "None",
"sla-ref": "None",
"subnet-nsdId-ref": "f5100cbb-1c3b-466e-8b0d-5d30311a6b2c",
"subnet-ref": "Service_subnet_2",
"vimAccountId": "88888888-2222-3333-4444-888888888888",
"vld": [
{
"vld-ref": "mgmt"
}
],
"working-status": "INSTANTIATED"
},
{
"isinstantiated": false,
"isshared": false,
"nsrId": "e312e96b-9971-47ad-ad91-bf94ecee9e51",
"nsrName": "9may_1-Service_subnet_3-3",
"requestId": "",
"sla-name": "None",
"sla-ref": "None",
"subnet-nsdId-ref": "f5100cbb-1c3b-466e-8b0d-5d30311a6b2c",
"subnet-ref": "Service_subnet_3",
"vimAccountId": "88888888-2222-3333-4444-888888888888",
"vld": [
{
"vld-ref": "mgmt"
},
{
"vld-ref": "slice_output"
}
],
"working-status": "INSTANTIATED"
}
],
"nst-name": "NST_3_dummy",
"nst-ref": "ba731abc-8b59-4cb8-9002-50af0e36619f",
"nst-version": "3.0",
"scaleTime": "",
"sliceCallback": "http://tng-gtk-sp:5000/requests/24bac550-6463-445a-be26-db1af02ce9b5/on-change",
"terminateTime": "",
"updateTime": "2019-05-09T10:30:19.991860",
"updated_at": "2019-05-09T10:00:08.925+00:00",
"uuid": "653251c4-f0c6-4317-9620-7b641debd286",
"vendor": "5GTango",
"vldr-list": [
{
"id": "mgmt",
"mgmt-network": true,
"name": "mgmt",
"ns-conn-point-ref": [
{
"Service_subnet_1": "mgmt"
},
{
"Service_subnet_2": "mgmt"
},
{
"Service_subnet_3": "mgmt"
}
],
"shared-nsrs-list": [],
"type": "E-LAN",
"vim-net-id": "9may_1.mgmt.net.3ba6c084-8ce6-4d00-9c53-272152b8c78f",
"vimAccountId": "88888888-2222-3333-4444-888888888888",
"vld-status": "ACTIVE"
},
{
"id": "slice_input",
"name": "slice_input",
"ns-conn-point-ref": [
{
"Service_subnet_1": "input"
}
],
"shared-nsrs-list": [],
"type": "E-LAN",
"vim-net-id": "9may_1.slice_input.net.766970e3-b107-491f-b6bc-19d1c7924a27",
"vimAccountId": "88888888-2222-3333-4444-888888888888",
"vld-status": "ACTIVE"
},
{
"id": "slice_output",
"mgmt-network": true,
"name": "slice_output",
"ns-conn-point-ref": [
{
"Service_subnet_3": "output"
}
],
"shared-nsrs-list": [],
"type": "E-LAN",
"vim-net-id": "9may_1.slice_output.net.e0bc74bb-eab0-4ce6-9abe-bc4c43e5ebfd",
"vimAccountId": "88888888-2222-3333-4444-888888888888",
"vld-status": "ACTIVE"
}
]
}
The following command allows you to get the latest information of all existing Network Slice Instantiations.
curl -i -H "Content-Type: application/json" -X GET http://{base_url}:5998/api/nsilcm/v1/nsi
RESPONSE EXAMPLE
The response has to return a HTTP.value of 200 and the payload contains a list of the NSI objects:
[
{
"5qiValue": 3,
"nst-name": "NST_3_Example1",
"datacenter": "88888888-2222-3333-4444-888888888888",
"description": "description",
"errorLog": "",
"instantiateTime": "2019-05-09T12:09:07.492629",
"name": "NSI_Example_1",
"nsi-status": "READY",
"nsr-list": [
...
},
{
"5qiValue": 3,
"nst-name": "NST_Example2",
"datacenter": "88888888-2222-3333-4444-888888888888",
"description": "description",
"errorLog": "",
"instantiateTime": "2019-05-09T12:08:04.914987",
"name": "NSI_Example_2",
"nsi-status": "INSTANTIATING",
"nsr-list": [
...
}
]
The following command allows you to get the latest information of a specific Network Slice Instantiation selected with its "uuid - {nsiId}".
curl -i -H "Accept: application/json" -H "Content-Type: application/json" -X GET http://{base_url}:5998/api/nsilcm/v1/nsi/{nsiId}
RESPONSE EXAMPLE
The response has to return a HTTP.value of 200 and the payload contains the NSI object:
{
"5qiValue": 3,
"created_at": "2019-05-09T10:00:08.925+00:00",
"datacenter": "88888888-2222-3333-4444-888888888888",
"description": "description",
"errorLog": "",
"instantiateTime": "2019-05-09T10:00:07.791341",
"name": "9may_1",
"nsi-status": "INSTANTIATED",
"nsr-list": [
...
}
As it happenede with the instantiation procedure, the command to terminate a NSI evolved due to the asynchronous communication with the Gatekeeper:
While the old command look liked the following:
curl -i -H "Content-Type:application/json" -X POST -d '{"terminateTime": "_time_"}' http://{base_url}:5998/api/nsilcm/v1/nsi/<nsiId>/terminate
The current command is the following:
http pre-int-sp-ath.5gtango.eu:32002/api/v3/requests instance_uuid=<nsi_uuid> request_type=TERMINATE_SLICE
RESPONSE EXAMPLE
The response has to return a HTTP.value of 204 and the payload is empty.
AUTHOR'S NOTE
In the old command had a value called terminateTime that should allow to define when the user want to terminate a NSI (either instnatly "terminateTime": "0", or at a specific moment "terminateTime":"2025-07-11T10:55:30.560Z"). Currently it predefined to terminate always at the same moment when the request is done.