Honolulu - Build/Run

This page describes how to get the Honolulu release version of A1-Policy functions up and running locally with two separate Near-RT RIC A1 simulator docker containers providing OSC_2.1.0 version of A1 interface.

All four components of these Non-RT RIC function run as docker containers and communicate via a private docker network. Details of the architecture can be found from Honolulu Release page.

  • Project Requirements

  • Build Code

    • Build Policy Management Service container

      • Configure A1 Policy Management Service

      • Build the code and create docker image

    • Build A1 Adapter for Controller

      • Build the code and create docker images

  • Run Controller with OSC A1 Adapter

  • Run Near-RT RIC A1 Simulator Docker Containers

  • Run A1 Policy Management Service Docker Container

    • A1 Policy Management Service Swagger API

  • Run OSC Non-RT RIC Control Panel Docker Container

    • Open OSC NONRTRIC / A1 Policy Control Panel UI

Project Requirements

  • Java 11 (make sure that JAVA_HOME environment variable points to correct Java version)

  • Maven 3.6

  • Docker and docker-compose (latest)

Build Code

Build A1 Policy Management Service container

  • Download the ccsdk/oran repo, honolulu branch: 

    $ git clone "https://gerrit.onap.org/r/ccsdk/oran" -b honolulu



Configure the A1 Policy Management Service

To support local test with two separate Near-RT RIC simulator instances:  

  • Copy the file oran/a1-policy-management/config/application_configuration.json  to the current directory and update it with the configuration below.

  • The controller hostname and port values come from and must match those defined in in the sdnc/oam repo oam/installation/src/main/yaml/docker-compose.yml (see the step "Build A1 Controller" further below). The port for http is 8181.

  • Any defined ric host names (in the name and baseUrl for each ric) must match the given docker container names in Near-RT RIC A1 simulator startup - port is always the simulator's internal port 8085 for http or 8185 for https (see the step "Build A1 Controller" further below).



application_configuration.json
{ "config": { "//description": "Application configuration", "controller": [ { "name": "controller1", "baseUrl": "http://sdnc_controller_container:8181", "userName": "admin", "password": "Kp8bJ4SXszM0WXlhak3eHlcse2gAw84vaoGGmJvUy2U" } ], "ric": [ { "name": "ric1", "baseUrl": "http://ric1:8085/", "controller": "controller1", "managedElementIds": [ "kista_1", "kista_2" ] }, { "name": "ric2", "baseUrl": "http://ric2:8085/", "controller": "controller1", "managedElementIds": [ "kista_3", "kista_4" ] }, { "name": "ric3", "baseUrl": "http://ric3:8085/", "controller": "controller1", "managedElementIds": [ "kista_1", "kista_2" ] }, { "name": "ric4", "baseUrl": "http://ric4:8085/", "controller": "controller1", "managedElementIds": [ "kista_1", "kista_2" ] } ] } }

Build the code and create docker image

To build docker image of the policy management service:

$ cd oran/a1-policy-management/ $ mvn clean install -Dmaven.test.skip=true

If the build is successful an image with following name and tag shall be built, use the command 'docker images' to view the newly built image in the local docker registry.

Build A1 Adapter for Controller

Build the code and create docker images

A1 Adapter is a feature developed within CCSDK which can then be installed in SDNC Karaf Server. To build & run the A1-enabled SDNC Controller, you need to build the ccsdk & sdnc repo's.

The Controller provides a Northbound Interface, to be used only by the A1 Policy Management Service, allowing it to pass messages over the A1 interface to Near-RealTime RICs in the RAN.

Use the downloaded repo 'ccsdk/oran' as in the previous step, "Build A1 Policy Management Service container"

After you build the A1 adapter artefacts, download below CCSDK/SDNC repos and build them in the following order.

Project

Repo

Gerrit Link

Command

Note

Project

Repo

Gerrit Link

Command

Note

CCSDK

ccsdk/parent

git clone "https://gerrit.onap.org/r/ccsdk/parent" -b honolulu

mvn clean install -Dmaven.test.skip=true

If the parent artefacts are not released you need to build this repo in order to build other ccsdk repos (Including ccsdk/oran/a1-adapter)

CCSDK

ccsdk/feature

git clone "https://gerrit.onap.org/r/ccsdk/features" -b honolulu

mvn clean install -Dmaven.test.skip=true



CCSDK

ccsdk/distribution

git clone "https://gerrit.onap.org/r/ccsdk/distribution" -b honolulu

mvn clean install -Dmaven.test.skip=true -Pdocker

Creates the CCSDK docker image

SDNC

sdnc/northbound

git clone "https://gerrit.onap.org/r/sdnc/northbound" -b honolulu

mvn clean install -Dmaven.test.skip=true



SDNC

sdnc/oam

git clone "https://gerrit.onap.org/r/sdnc/oam" -b honolulu

mvn clean install -Dmaven.test.skip=true -Pdocker

Creates the SDNC docker image. Make sure you refer the right docker image version in the pom file.(eg: you may need to update ccsdk.docker.version for onap/ccsdk-ansible-server-image from 1.0-STAGING-latest to 1.0-SNAPSHOT-latest)

If the builds are successful, images with following name and tag shall exist, use the command 'docker images' to view the newly built images in the local docker registry.

Run A1-enabled Controller

To view the A1 policy operations, you need to run the SDNC docker image. This image has few other docker image dependencies but not all are important for A1 policy testing. To bring up the sdnc container for A1 Policy Management testing a number of the not needed services can be removed from the docker compose file.

Edit the docker compose file, oam/installation/src/main/yaml/docker-compose.yaml and keep only sdnc, maria db and ansible images. The rest of the images are not necessary for A1 Policy testing. However if you want to change the DG and run your own DG, you may need to keep the Directed Graph image.

The SDNC image will take a while to install all the features into Karaf Server. You can check the logs of the server at /opt/opendaylight/data/log/karaf.log

The A1 Policy in ODL GUI can be accessed by this URL (it may take several minutes before the URL works)

http://localhost:8282/apidoc/explorer/index.html
Username/password: admin/Kp8bJ4SXszM0WXlhak3eHlcse2gAw84vaoGGmJvUy2U

Run OSC Near-RT-RIC/A1 Simulator Docker Containers

  • Start docker containers for each ric defined in oran/a1-policy-management/config/application_configuration.json in the step for "Configuration Policy Management Service" (in this example for ric1 and ric2) and providing A1 interface version OSC_2.1.0 with the following commands (use separate shells):



  • Create a policy type json to load into the A1 simulators (running version OSC.2.1.0)

    pt1.json



  • Put the example policy type into the started A1 simulator instances by running these curl commands (in this example to ric1 exposed to port 8085 and ric2 exposed to port 8086):



  • Create a policy type json to load into the A1 simulators (running version STD.2.0.0)

    std_qos2_0.0.1.json



  • Put the example policy type into the started A1 simulator instances by running these curl commands (in this example to ric3 exposed to port 8087 and ric4 exposed to port 8088):



Run ONAP A1 Policy Management Service Docker Container

  • Run docker container using this command once the A1-enabled Controller and simulators have been fully started and optionally set the logging level to trace (the curl command will not work until the container is fully up and running).
    The configuration, application_configuration.json, of the controller and rics must be mounted as a volume to the container.





  • Once the Policy Management Service is up and running, it establishes connections to all configured Near-RT RICs (ric1 and ric2) via the A1 Controller.

  • If the policy-agent-container is configured to log at trace level, the following logs entries should appear indicating that connection to the configured RICs has been established successfully via A1 Controller.



A1 Policy Management Service Swagger API

For troubleshooting/verification purposes you can view/access the policy-agent swagger API from url: http://localhost:8081/swagger-ui.html

Run OSC Non-RT RIC Control Panel Docker Container

Run docker container using this command: 

Open NONRTRIC / A1 Policy Control Panel UI

The Control Panel UI can be accessed by pointing the web-browser to this URL: 

http://localhost:8080/

Thee policy type loaded in the simulator should be visible in the table. Instances of the policy type can now be created, updated and deleted.