Uploaded image for project: 'Configuration Persistence Service'
  1. Configuration Persistence Service
  2. CPS-1006

Extend CPS PATCH API to allow update of leaves for multiple data nodes

XMLWordPrintable

      Not able to update list-nodes using PATCH API

      Issue:
       Patch api cannot change more than one data in single api

      Steps to reproduce:

      1. Data space name : E2EDemo*
      curl --location --user cpsuser:cpsr0cks! -H "Accept: application/json" -H "Content-Type: application/json" --request POST 'http://localhost:8883/cps/api/v1/dataspaces?dataspace-name=E2EDemo'

      2. schema set: ran-network*
      curl --location --user cpsuser:cpsr0cks! --request POST 'http://localhost:8883/cps/api/v1/dataspaces/E2EDemo/schema-sets' --form 'file=@"ran-network.zip"' --form 'schema-set-name="ran-network"'

      3. anchor name: ran-network-anchor*
      curl --location --user cpsuser:cpsr0cks! --request POST 'http://localhost:8883/cps/api/v1/dataspaces/E2EDemo/anchors?schema-set-name=ran-network&anchor-name=ran-network-anchor'

      4. Initial data*
      curl -H "Authorization: Basic Y3BzdXNlcjpjcHNyMGNrcyE=" --request PUT 'http://localhost:8883/cps/api/v1/dataspaces/E2EDemo/anchors/ran-network-anchor/nodes' \
      --header 'Content-Type: application/json' -d @ran-network-data.txt

      5. API Tried*

      curl -g -H "Authorization: Basic Y3BzdXNlcjpjcHNyMGNrcyE=" -H "Content-Type: application/json" --request PATCH 'http://localhost:8883/cps/api/v1/dataspaces/E2EDemo/anchors/ran-network-anchor/nodes?xpath=/ran-network/NearRTRIC[@idNearRTRIC=%2711%27]/attributes/pLMNInfoList[@mcc=%2739%27%20and%20@mnc=%2700%27]/sNSSAIList[@sNssai=%27010%27]' -d'{"configData":[

      {"configParameter":"uLThptPerSlice","configValue":13}

      ,{"configParameter":"dLThptPerSlice","configValue":13}]}'

      6. Response received*

      {"pLMNInfoList":[{"mcc":"39","mnc":"00","sNSSAIList":[{"sNssai":"010","status":"ACTIVE","configData":[

      {"configValue":100,"configParameter":"maxNumberOfConns"}

      ,{"configValue":13,"configParameter":"uLThptPerSlice"},{"configValue":26880000,"configParameter":"dLThptPerSlice"}]}]}]}

      7. Expected change

      {"pLMNInfoList":[{"mcc":"39","mnc":"00","sNSSAIList":[{"sNssai":"010","status":"ACTIVE","configData":[

      {"configValue":100,"configParameter":"maxNumberOfConns"}

      ,{"configValue":13,"configParameter":"uLThptPerSlice"},{"configValue":13,"configParameter":"dLThptPerSlice"}]}]}]}

       

       

      {"pLMNInfoList":[{"mcc":"39","mnc":"00","sNSSAIList":[{"sNssai":"010","status":"ACTIVE","configData":[

      {"configValue":100,"configParameter":"maxNumberOfConns"}

      ,{"configValue":24000000,"configParameter":"uLThptPerSlice"},{"configValue":26880000,"configParameter":"dLThptPerSlice"}]}]}]}

      In the above path, patch api needs to change uLThptPerSlice and dLThptPerSlice values in the config data using single api. But at a time only one value is getting changed. 

       

       

       

            arpitsingh Arpit Singh
            denilson.l65 denilson.l65
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: