Ezhilarasi | b651ae3 | 2019-03-25 15:53:07 +0530 | [diff] [blame] | 1 | .. This work is licensed under a Creative Commons Attribution 4.0 International License. |
| 2 | .. http://creativecommons. |
| 3 | .. Copyright (C) 2019 IBM. |
| 4 | |
| 5 | Blueprints Processor |
| 6 | ==================== |
| 7 | |
| 8 | .. toctree:: |
| 9 | :maxdepth: 1 |
| 10 | :titlesonly: |
| 11 | |
| 12 | Micro service to Manage Controller Blueprint Models, such as Resource Dictionary, Service Models, Velocity Templates etc, which will serve service for Controller Design Studio and Controller runtimes. |
| 13 | |
Ezhilarasi | a27d27e | 2019-04-16 16:28:47 +0530 | [diff] [blame] | 14 | This microservice is used to deploy Controller Blueprint Archive file in Run time database. This also helps to test the Valid Blueprint. |
| 15 | |
Ezhilarasi | b651ae3 | 2019-03-25 15:53:07 +0530 | [diff] [blame] | 16 | Architecture: |
Ezhilarasi | de33f3c | 2019-07-05 13:29:54 +0530 | [diff] [blame] | 17 | ------------- |
Ezhilarasi | b651ae3 | 2019-03-25 15:53:07 +0530 | [diff] [blame] | 18 | |
| 19 | |image0| |
| 20 | |
| 21 | .. |image0| image:: images/blueprintprocessor.jpg |
| 22 | :height: 600px |
Ezhilarasi | a27d27e | 2019-04-16 16:28:47 +0530 | [diff] [blame] | 23 | :width: 800px |
| 24 | |
| 25 | Running Blueprints Processor Microservice Locally: |
Ezhilarasi | de33f3c | 2019-07-05 13:29:54 +0530 | [diff] [blame] | 26 | -------------------------------------------------- |
Ezhilarasi | a27d27e | 2019-04-16 16:28:47 +0530 | [diff] [blame] | 27 | |
| 28 | The purpose of this page is to show how to run the Blueprints Processor microservice locally, using the docker-compose.yaml file provided in the project. |
| 29 | |
| 30 | Check out the CDS' code: |
| 31 | |
| 32 | Check out the latest code from Gerrit: https://gerrit.onap.org/r/#/admin/projects/ccsdk/cds |
| 33 | |
| 34 | Build CDS locally: |
| 35 | In the checked out directory, type |
| 36 | |
| 37 | mvn clean install -DskipTests=true -Dmaven.test.skip=true -Dmaven.javadoc.skip=true -Dadditionalparam=-Xdoclint:none |
| 38 | |
| 39 | Create the needed Docker images: |
| 40 | |
| 41 | The Blueprints Processor microservice project has a module, called distribution, that provides a docker-compose.yaml file that can be used to spin up Docker containers to run this microservice. |
| 42 | |
| 43 | The first step is to create any custom image needed, by building the distribution module. From the CDS home directory (where the code was checked out), navigate to the module: |
| 44 | |
| 45 | cd ms/blueprintsprocessor/distribution/ |
| 46 | Build it using the Maven profile called Docker: |
| 47 | |
| 48 | mvn clean install -Pdocker |
| 49 | |
| 50 | Start Docker containers using docker-composer: |
Ezhilarasi | de33f3c | 2019-07-05 13:29:54 +0530 | [diff] [blame] | 51 | ---------------------------------------------- |
Ezhilarasi | a27d27e | 2019-04-16 16:28:47 +0530 | [diff] [blame] | 52 | |
| 53 | Navigate to the docker-compose file in the distribution module: |
| 54 | |
| 55 | cd src/main/dc/ |
| 56 | |
| 57 | From there, start the containers: |
| 58 | |
| 59 | docker-compose up -d |
| 60 | This will spin the Docker containers declared inside the docker-compose.yaml file in the background. |
| 61 | |
| 62 | |
| 63 | To verify the logs generated by docker-composer, type: |
| 64 | |
| 65 | docker-compose logs -f |
| 66 | |
| 67 | |
| 68 | Testing the environment: |
Ezhilarasi | de33f3c | 2019-07-05 13:29:54 +0530 | [diff] [blame] | 69 | ------------------------ |
Ezhilarasi | a27d27e | 2019-04-16 16:28:47 +0530 | [diff] [blame] | 70 | |
| 71 | Point your browser to http://localhost:8000/api/v1/execution-service/ping (please note that the port is 8000, not 8080) |
| 72 | |
| 73 | To authenticate, use ccsdkapps / ccsdkapps as login / password. |