This directory contains a Helm chart for the minimal robot container
and Kubernetes job.
-USING THE CHART
-To install the chart (which creates and runs a single Kubernetes job),
-first copy the packaged Common-Template chart (from
-https://gerrit.o-ran-sc.org/r/it/dep.git) into
-ric_robot_suite/helm/nanobot/charts. Then, edit
-ric_robot_suite/helm/nanobot/values.yaml to reflect your
-environment and desired tests and run
+Before executing the nanobot test please do the following procedures
+Deploy E2sim:
+============
+
+1. Deploy RIC platform
+
+2. kubectl rollout restart deployment --namespace ricplt deployment-ricplt-e2mgr deployment-ricplt-e2term-alpha (The e2mgr and e2term need to be restarted; this is due to some issues with health check; I don’t know whether it has been resolved by that team)
+
+3. clone sim/e2-interface
+
+4. In the root directory of e2sim: Follow directions in README to produce the deb files
+
+5. Since the deb files are not yet pushed to package cloud, we need to copy them
+
+6. cp e2sim*deb ../e2sm_examples/kpm_e2sm
+
+7. cd ../e2sm_examples/kpm_e2sm
+
+8. Edit the Dockerfile at the bottom to have IP address of service-ricplt-e2term-sctp-alpha service
+
+9. docker build .
+
+10. docker tag <tag just built> e2simul:0.0.2
+
+11. Once deployed, kubectl logs will show:
-Deploy E2sim using helm install by entering inside the path
-/test/ric_benchmarking/E2-interface/e2sim/e2sm_examples/kpm_e2sm/helm/
+An E2 Setup Request from E2 Simulator to E2 Term
+An E2 Setup Response from E2 Term to E2 Simulator
-$ helm install --name <name of deployment> --namespace <namespace>
+Deploy Bouncer Xapp in common way:
+==================================
-Update E2sim PLMID, GNBID to values.yaml(.Values.ric.robot.environment.gNodeB)
+Follow the link to deploy xapps
+https://wiki.o-ran-sc.org/display/IAT/AD+xApp+Flows
-Deploy bouncer xapp using xapp onboarder steps(as mentioned below 2 steps)
+1.Preparing an xApp for onboarding:
-Copy the config-file.json schema file in to the vm where you are deploying and make URL
-$ echo '{"config-file.json_url": "http://<RIC Server IP>/config-file.json" }' > onboard.<xappname>.url
+echo '{"config-file.json_url": "https://gerrit.o-ran-sc.org/r/gitweb?p=ric-app/ts.git;a=blob_plain;f=xapp-descriptor/config.json;hb=HEAD" }' > onboard.ts.url
-Onboard the xapp using below command
-$ curl --location --request POST "http://<RIC Server IP>:32080/onboard/api/v1/onboard/download" --header 'Content-Type: application/json' --data-binary "@./onboard.<xappname>.url"
-Provide the xapp name which will be available in config-file.json in to values.yaml (.Values.ric.robot.environment.xapp)
+2. Onboarding xApps:
+Invoke the API calls into the xApp On-boarder, providing it the locations of the xApp descripters.
+curl --location --request POST "http://$(hostname):32080/onboard/api/v1/onboard/download" --header 'Content-Type: application/json' --data-binary "@./onboard.ts.url"
+
+3. Checking the on-boarded charts:
+curl --location --request GET "http://$(hostname):32080/onboard/api/v1/charts"
+
+4. Deploying Xapp:
+curl --location --request POST "http://$(hostname):32080/appmgr/ric/v1/xapps" --header 'Content-Type: application/json' --data-raw '{"xappName": "trafficxapp"}'
+
+Deploy KPIMONXapp:
+==================
+currently KPIMON deployment must be done in the following way:
+
+https://wiki.o-ran-sc.org/display/IAT/Traffic+Steering+Flows
+
+
+1. clone scp/ric-app/kpimon (note it is different than the ric-app/kpimon repo)
+2. docker build .
+3. docker tag <image tag just created> nexus3.o-ran-sc.org:10002/ric-app-kpimon:1.0.0
+4 .curl -X POST --data-binary @xappkpimon-0.2.0.tgz http://<vm-name>:32080/helmrepo/api/charts (Push hand-crafted helm chart to appmgr chart museum)
+
+Once Xapp deployed
+
+1.Checkout the it/test repo
+2.Modify Values.yaml based on your Xapp deployment name, Xapp name and E2sim deployment with PLMID, GNBID update.
+ric_robot_suite/helm/nanobot/values.yaml.
+3.Add testsuites name based on our testing.
+Note: Only one xapp to E2sim test is possible.
+
+Follow the below steps for nanobot testing.
+USING THE CHART
+To install the chart (which creates and runs a single Kubernetes job),
+first copy the packaged Common-Template chart (from
+https://gerrit.o-ran-sc.org/r/it/dep.git) into
+ric_robot_suite/helm/nanobot/charts. Then, edit
+ric_robot_suite/helm/nanobot/values.yaml to reflect your
+environment and desired tests and run
-Deploy nanobot using below helm install
$ helm install [--values <override-file> ] --namespace <namespace> nanobot
... in the ric_robot_suite/helm directory, where <override-file>
ric_robot_suite/docker/nanobot/Dockerfile; see
ric_robot_suite/docker/nanobot/README for information about the
image.
+
--- /dev/null
+# Copyright (c) 2019 AT&T Intellectual Property.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+*** Settings ***
+Documentation Executes the End To End Test cases
+...
+Resource /robot/resources/appmgr_interface.robot
+Resource /robot/resources/negative_appmgr_tests.robot
+Resource /robot/resources/e2mgr_interface.robot
+Resource /robot//resources/dashboard_interface.robot
+Resource /robot/resources/global_properties.robot
+Resource /robot/resources/ric/ric_utils.robot
+Resource /robot/resources/e2term_interface.robot
+
+Library Collections
+Library OperatingSystem
+Library RequestsLibrary
+Library KubernetesEntity ricplt
+Library SDLWrapper False
+Library String
+
+*** Variables ***
+${TEST_XAPPNAME} ${GLOBAL_TEST_XAPP}
+${TEST_NODE_B_NAME} ${GLOBAL_TEST_NODEB_NAME}
+${TEST_NODE_B_IP} ${GLOBAL_TEST_NODEB_ADDRESS}
+${TEST_NODE_B_PORT} ${GLOBAL_TEST_NODEB_PORT}
+#${ricxapp_POD_NAME} ${GLOBAL_XAPP_NAMESPACE}-${GLOBAL_XAPP}
+${TEST_XAPP_ONBOARDER} ${GLOBAL_TEST_XAPP_ONBOARDER}
+
+*** Keywords ***
+Keyword Check subreq
+ [Arguments] ${linematch}
+ ${result_subreq} = Set variable 1
+ Set Global Variable ${result_subreq}
+ ${messages} = Split String ${linematch} ,
+ Log To Console ${messages}
+ ${ts} = Get From List ${messages} 0
+ Log To Console ${ts}
+ ${timestamp1} = Split String ${ts} :
+ ${timestampval1} = Get From List ${timestamp1} 1
+ Log To Console ${timestampval1}
+ Set Global Variable ${timestampval1}
+
+Keyword Check No subreq
+ ${aaa} = Set Variable 1
+
+
+Keyword Check subres
+ [Arguments] ${linematch}
+ ${result_subres} = Set variable 1
+ Set Global Variable ${result_subres}
+ ${messages1} = Split String ${linematch} ,
+ Log To Console ${messages1}
+ ${ts1} = Get From List ${messages1} 0
+ Log To Console ${ts1}
+ ${timestamp2} = Split String ${ts1} :
+ ${timestampval2} = Get From List ${timestamp2} 1
+ Log To Console ${timestampval2}
+ Set Global Variable ${timestampval2}
+
+Keyword Check No subres
+ ${aaa} = Set Variable 1
+
+
+Keyword Check IndMessage
+ [Arguments] ${linematch}
+ ${result_Ind1} = Set Variable 1
+ Set Global Variable ${result_Ind1}
+ ${messages} = Split String ${linematch} :
+ Log To Console ${messages}
+ ${timestampval_ind1} = Get From List ${messages} 1
+ Log To Console ${timestampval_ind1}
+ Set Global Variable ${timestampval_ind1}
+ Append To List ${IndMessgList} ${timestampval_ind1}
+
+Keyword Check No IndMsg
+ ${aaa} = Set Variable 1
+
+Keyword Check ControlMsg
+ [Arguments] ${linematch}
+ ${result_ctrl1} = Set Variable 1
+ Set Global Variable ${result_ctrl1}
+ ${messages1} = Split String ${linematch} :
+ Log To Console ${messages1}
+ ${timestampval_ctrl1} = Get From List ${messages1} 1
+ Log To Console ${timestampval_ctrl1}
+ Set Global Variable ${timestampval_ctrl1}
+ Append To List ${ContMessgList} ${timestampval_ctrl1}
+
+Keyword Check No CtrlMsg
+ ${aaa} = Set Variable 1
+
+
+*** Test Cases ***
+Test XApp Manager Health
+ [Tags] etetests xapptests
+ Run AppMgr Health Check
+
+
+Ensure RIC Xapp Onboarder is deployed and available
+ [Tags] etetests xapptests
+ ${controllerName} = Set Variable ${GLOBAL_TEST_XAPP_ONBOARDER}
+ ${cType} ${name} = Split String ${controllerName} |
+ Log To Console ${cType}
+ ${ctrl} = Run Keyword ${cType} ${name}
+ Should Be Equal ${ctrl.status.replicas} ${ctrl.status.ready_replicas}
+
+
+Get All NodeBs Via E2Mgr
+ [Tags] e2mgrtest etetests e2setup x2setup
+ ${log} = Run E2Mgr Get All NodeBs Request
+ FOR ${item} IN @{log.json()}
+ Log To Console ${item}
+ ${json}= Set variable ${item['globalNbId']["plmnId"]}
+ Should Be Equal ${json} ${GLOBAL_PLMNID}
+ END
+
+Get All E2T Via E2Mgr
+ [Tags] e2mgrtests etetests e2setup x2setup
+ ${log} = Run E2Mgr Get All E2T Request
+ Log To Console ${log}
+
+Get NodeB Request Via E2Mgr
+ [Tags] e2mgrtests etetests e2setup x2setup
+ Run E2Mgr Get NodeB Request ${GLOBAL_GNBID}
+
+
+RetriveLog From XAPP
+ [Tags] etetests xapptests intrusive
+ ${podname} = Run Keyword RetrievePodsForDeployment ${GLOBAL_XAPPKPIMON_DEPLOYMENT} namespace=${GLOBAL_XAPP_NAMESPACE}
+ Log To Console ${podname}
+ ${ric_xapp_pod1} = Set Variable ${podname[0]}
+ Log To Console ${ric_xapp_pod1}
+ ${log1} = Run keyword RetrieveLogForPod ${ric_xapp_pod1} namespace=${GLOBAL_XAPP_NAMESPACE}
+ ${stringLog} Convert To String ${log1}
+ Set Global Variable ${stringLog}
+ Set Global Variable ${log1}
+
+Verifying Subscription Request From Xapp
+ [Tags] etetests xapptests
+ #Sleep 90000
+ Log To Console "Sending Subscription Message from Xapp"
+ Should Match Regexp ${stringLog} The RMR message to be sent is 12010
+
+Verifying Subscription Response From E2sim
+ [Tags] etetests xapptests
+ Log To Console "Received Subscription Message from RAN"
+ Should Match Regexp ${stringLog} Received message type: 12011
+
+Verifying Ric Indication on Xapp
+ [Tags] etetests xapptests
+ #Sleep 20000
+ Log To Console "Received Indication Message from RAN"
+ Should Match Regexp ${stringLog} Received message type: 12050
+
+Verifying ueid from dbass by using sdl
+ [Tags] etetests xapptests
+ Log To Console "Verifying Healthcheck of dbass"
+ ${log} = Run Keyword healthcheck
+ Log To Console ${log}
+ Log To Console "Received ueid from dbass from sdl"
+ ${Allueid} = Run Keyword find and get kpimon {TS-UE-metrics} false
+ Log To Console ${Allueid}
+ Log To Console "############ printing the ueid's ###########"
+ Log To Console ${Allueid.keys()}
+ ${ueid_check} = Set Variable 0
+ ${ueid} = Set Variable ${None}
+ FOR ${key} IN @{Allueid.keys()}
+ ${ueid_check} = Set Variable 1
+ ${ueid} = Run Keyword get kpimon ${key} false
+ Log To Console ${key}
+ Log To Console "--------------ueid---------------"
+ Log To Console ${ueid}
+
+ END
+ Should Not Be Equal ${ueid} ${None}
+ Should Match ${ueid_check} 1
+
+Verifying cellid from dbass by using sdl
+ [Tags] etetests xapptests
+ Log To Console "Verifying Healthcheck of dbass"
+ ${log} = Run Keyword healthcheck
+ Log To Console ${log}
+ Log To Console "Received cellid from dbass from sdl"
+ ${Allcellid} = Run Keyword find and get kpimon {TS-cell-metrics} false
+ Log To Console ${Allcellid}
+ Log To Console "############ printing the cellid's ###########"
+ Log To Console ${Allcellid.keys()}
+ ${cellid_check} = Set Variable 0
+ ${cellid} = Set Variable ${None}
+ FOR ${key} IN @{Allcellid.keys()}
+ ${cellid_check} = Set Variable 1
+ ${cellid} = Run Keyword get kpimon ${key} false
+ Log To Console ${key}
+ Log To Console "--------------cellid---------------"
+ Log To Console ${cellid}
+ END
+ Should Not Be Equal ${cellid} ${None}
+ Should Match ${cellid_check} 1