Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


Table of Contents


DCAE Platform support dynamic topic/feed provisioning through usage for DMaap plugin which interfaces with Dmaap-DBCL component to carry out this request and provision AAF based topic/feed; once the provisioning is completed, the corresponding configuration are returned back for MS (as configuration in consul)

...

<list all the test blueprint along with small description on what the scope of each blueprints)

All test blueprint should be uploaded into into https://git.onap.org/dcaegen2/platform/blueprints/tree/blueprints/reference_templates

Currently available DMaap plugin test blueprints arewe have the following blueprints:

  • test_mr_pubsub_extra.yaml
  • test_mr_pubsub.yaml
  • test_mr_multipub.yaml
  • test_mr_multisub.yaml
  • test_dr_pubsub.yaml
  • test_dr_mr.yaml

In the following discussion we assume that you already download these test scripts into directory /blueprints/blueprints/ directory on the test VM. (We loaded the blueprints manually in our test.)

Test Setup

<env dependencies; and pre-requisite for testing + any data load (e.g location details + consul load)>

Pre-requisite for running the test blueprints:

1) Add the dmaap kv following key/value into consul
{
    with "dmaap-plugin" :
    as the key.

Note: This step might not be needed, in particular "protocol" : "http"  can cause a problem with dmaap-bc connection. Default configuration will be added into consul upon Cloudify Container deployment.
{
    "dmaap" :
    {
        "username": "whatever",
        "password": "whatever",
        "owner" : "dcaeorch",
        "protocol" : "http"
    }
}
2) Add ) (With the help of DBCL owner) add location san-francisco into DMaap DBCL if the location is not in there yet.


Deployment Steps

<steps for running blueprint listed earlier >

For each of the test blueprints, run the following commands:

  • cfy install -b <blueprint

...

  • -id> -d <deployment

...

  • -id> <blueprint_name>

...

where <blueprint-id> and <deployment-id> can be any string choose by the user.

During deployment, Monitor the output of deployment for error messages.

After the blueprint is successfully deployed, check the DMaap DBCL url to verify the configuration. (Detailed commands are described later.)

After validation, uninstall the blueprint with the following command:

  • cfy uninstall <deployment_

...

  • id>

Recheck the DMaap DBCL url to verify that the previous configuration is deleted from DMaap DBCL.

Notice: since most of the blueprints reuse the same topic name(s) and feed name, please uninstall the current blueprint before testing the next one.


For example, the screen output of deploying/verifying test_mr_pubsub_extra.yaml is as follows:

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# cfy install -b test0 -d test0 -i dmaap_inputs.yaml test_mr_pubsub_extra.yaml

Uploading blueprint test_mr_pubsub_extra.yaml...

test_mr_pubsub_ex... yaml |#################################################################################################| 100.0%

Blueprint uploaded. The blueprint's id is test0

Creating new deployment from blueprint test0...

Deployment created. The deployment's id is test0

Executing workflow install on deployment test0 [timeout=900 seconds]

Deployment environment creation is pending...

2019-05-10 23:09 20:53:0754.512 252 CFY <test0> Starting 'create_deployment_environment' workflow execution

2019-05-10 23:09 20:53:0854.088 881 CFY <test0> Installing deployment plugins

2019-05-10 23:09 20:53:0854.088 881 CFY <test0> Sending task 'cloudify_agent.operations.install_plugins'

2019-05-10 23:09 20:53:0854.088 881 CFY <test0> Task started 'cloudify_agent.operations.install_plugins'

2019-05-10 23:09 20:53:0855.742 568 LOG <test0> INFO: Installing plugin: k8s

2019-05-10 23:09 20:53:0856.742 181 LOG <test0> INFO: Using existing installation of managed plugin: 99e0f852-a688-4ecf-b606-37df263f6fa0 [package_name: k8splugin, package_version: 1.4.13, supported_platform: linux_x86_64, distribution: centos, distribution_release: core]

2019-05-10 23:09 20:53:0856.742 181 LOG <test0> INFO: Installing plugin: dmaapplugin

2019-05-10 23:09 20:53:0957.987 576 LOG <test0> INFO: Using existing installation of managed plugin: d8abab9c-2e52-4caa-a9fe-d74bf24609ad [package_name: dmaap, package_version: 1.3.2, supported_platform: any]

2019-05-10 23:09 20:53:0957.987 576 CFY <test0> Task succeeded 'cloudify_agent.operations.install_plugins'

2019-05-10 23:09 20:53:0957.987 576 CFY <test0> Skipping starting deployment policy engine core - no policies defined

2019-05-10 23:09 20:53:0957.987 576 CFY <test0> Creating deployment work directory

2019-05-10 23:09 20:53:0957.987 576 CFY <test0> 'create_deployment_environment' workflow execution succeeded

2019-05-09 2010 23:5310:1501.444 752 CFY <test0> Starting 'install' workflow execution

2019-05-09 2010 23:5310:1703.083 571 CFY <test0> [topic00topic01_incvxjxjti5i] Creating node instance

2019-05-09 2010 23:5310:1704.718 268 CFY <test0> [topic01topic00_34hei2ehyrmr] Creating node instance

2019-05-09 2010 23:5310:1704.718 268 CFY <test0> [topic00topic01_incvxjxjti5i.create] Sending task 'dmaapplugin.mr_lifecycle.create_topic'

2019-05-09 2010 23:5310:1804.396 268 CFY <test0> [topic01topic00_34hei2ehyrmr.create] Sending task 'dmaapplugin.mr_lifecycle.create_topic'

2019-05-09 2010 23:5310:1905.322 961 LOG <test0> [topic00topic01_incvxjxjti5i.create] INFO: Attempting to create topic name topic00topic01_name

2019-05-09 2010 23:5310:1906.826 612 LOG <test0> [topic00topic01_incvxjxjti5i.create] INFO: Posting to URL: http://dmaap-bc:8080/webapi/topics with body: {'txenable': False, 'globalMrURLowner': u'message-routerdcaeorch', 'replicationCase ': u'REPLICATION_EDGE_TO_CENTRAL_TO_GLOBAL', 'topicDescription': 'No description provided', 'ownertopicName': u'dcaeorchtopic01_name', 'topicNametxenable': u'topic00'False}

2019-05-09 2010 23:5310:1906.826 612 LOG <test0> [topic01topic00_34hei2ehyrmr.create] INFO: Attempting to create topic name topic01topic00_name

2019-05-09 2010 23:5310:1906.826 612 LOG <test0> [topic01topic00_34hei2ehyrmr.create] INFO: Posting to URL: http://dmaap-bc:8080/webapi/topics with body: {'owner': u'dcaeorch', 'topicDescription': 'No description provided', 'topicName': u'topic01topic00_name', 'replicationCase': u'REPLICATION_EDGE_TO_CENTRAL', 'txenable': False}
txenable': False}

2019-05-09 2010 23:5310:2108.331 715 CFY <test0> [topic01topic00_34hei2ehyrmr.create] Task succeeded 'dmaapplugin.mr_lifecycle.create_topic'

2019-05-09 2010 23:5310:2109.965 321 CFY <test0> [topic00topic01_incvxjxjti5i.create] Task succeeded 'dmaapplugin.mr_lifecycle.create_topic'

2019-05-09 2010 23:5310:2109.965 321 CFY <test0> [topic01topic00_34hei2ehyrmr] Node instance created

2019-05-09 2010 23:5310:2109.965 321 CFY <test0> [topic00topic01_incvxjxjti5i] Node instance created

2019-05-09 2010 23:5310:2209.648 960 CFY <test0> [topic01topic00_34hei2ehyrmr] Configuring node instance: nothing to do

2019-05-09 2010 23:5310:2209.648 960 CFY <test0> [topic00topic01_incvxjxjti5i] Configuring node instance: nothing to do

2019-05-09 2010 23:5310:2209.648 960 CFY <test0> [topic01topic00_34hei2ehyrmr] Starting node instance: nothing to do

2019-05-09 2010 23:5310:2210.648 570 CFY <test0> [topic00topic01_incvxjxjti5i] Starting node instance: nothing to do

2019-05-09 2010 23:5310:2310.375 570 CFY <test0> [topic01topic00_34hei2ehyrmr] Node instance started

2019-05-09 2010 23:5310:2310.995 570 CFY <test0> [topic00topic01_incvxjxjti5i] Node instance started

2019-05-09 2010 23:5310:2411.700 241 CFY <test0> [client00web_server_cowri2cqf9i4] Creating node instance

2019-05-09 2010 23:5310:2511.368 925 CFY <test0> [client00web_server_cowri2cqf9i4.create] Sending task 'k8splugin.create_for_components_with_streams'

2019-05-09 2010 23:5310:2916.247 273 LOG <test0> [client00web_server_cowri2cqf9i4.create] INFO: Done setting up: sc972b27b7f5d4835976efbe93316e253Added config for s61b2002abe554457a78050174c431719-nginx-web

2019-05-09 2010 23:5310:2816.560 784 LOG <test0> [client00web_server_cowri2cqf9i4.create] INFO: Added config for sc972b27b7f5d4835976efbe93316e253Done setting up: s61b2002abe554457a78050174c431719-nginx-web

2019-05-09 2010 23:5310:2917.247 527 CFY <test0> [client00web_server_cowri2cqf9i4.create] Task succeeded 'k8splugin.create_for_components_with_streams'

2019-05-09 2010 23:5310:2918.857 146 CFY <test0> [client00web_cowri2server_cqf9i4] Node instance created

2019-05-09 2010 23:5310:2918.857 146 CFY <test0> [client00web_server_cowri2cqf9i4] Pre-configuring relationships

2019-05-09 2010 23:5310:2918.857 146 CFY <test0> [preconfigure] Sending task 'dmaapplugin.mr_relationships.add_mr_publisher'

2019-05-09 2010 23:5310:3220.143 266 LOG <test0> [preconfigure] INFO: Posting to URL: http://dmaap-bc:8080/webapi/mr_clients with body: {'action': ['view', 'pub'], 'clientRole': u'org.onap.dcae.pnfPublisher', 'fqtn': u'org.onap.dmaap.mr.topic00', 'dcaeLocationName': u'san-francisco'}
2019-05-09 20:53:31.518 LOG <test0> [Attempting to add web_server as publisher to topic org.onap.dmaap.mr.topic00_name

2019-05-10 23:10:20.266 LOG <test0> [preconfigure] INFO: Attempting to add client00 web_server as publisher to topic org.onap.dmaap.mr.topic00_name

2019-05-09 2010 23:5310:3220.143 788 LOG <test0> [preconfigure] INFO: Added publisher id 1557435211391 1557529820110 to feed org.onap.dmaap.mr.topic00_name at san-francisco

2019-05-09 2010 23:5310:3220.777 788 CFY <test0> [preconfigure] Task succeeded 'dmaapplugin.mr_relationships.add_mr_publisher'

2019-05-09 2010 23:5310:3221.777 470 CFY <test0> [preconfigure] Sending task 'dmaapplugin.mr_relationships.add_mr_subscriber'

2019-05-09 2010 23:5310:3323.963 467 LOG <test0> [preconfigure] INFO: Attempting to add client00 web_server as subscriber to topic org.onap.dmaap.mr.topic01_name

2019-05-09 2010 23:5310:3424.601 004 LOG <test0> [preconfigure] INFO: Posting to URL: http://dmaap-bc:8080/webapi/mr_clients with body: {'action': ['view', 'sub'], 'clientRole': u'org.onap.dcae.pnfSubscriber', 'fqtn': u'org.onap.dmaap.mr.topic01_name', 'dcaeLocationName': u'san-francisco'}

2019-05-09 2010 23:5310:3424.601 004 LOG <test0> [preconfigure] INFO: Added subscriber id 1557435213810 1557529823378 to feed org.onap.dmaap.mr.topic01_name at san-francisco

2019-05-09 2010 23:5310:3524.180 658 CFY <test0> [preconfigure] Task succeeded 'dmaapplugin.mr_relationships.add_mr_subscriber'

2019-05-09 2010 23:5310:3524.180 658 CFY <test0> [client00web_server_cowri2cqf9i4] Relationships pre-configured

2019-05-09 2010 23:5310:3525.802 402 CFY <test0> [client00web_server_cowri2cqf9i4] Configuring node instance: nothing to do

2019-05-09 2010 23:5310:3525.802 402 CFY <test0> [client00web_server_cowri2cqf9i4] Starting node instance

2019-05-09 2010 23:5310:3525.802 998 CFY <test0> [client00web_server_cowri2cqf9i4.start] Sending task 'k8splugin.create_and_start_container_for_components_with_streams'

2019-05-09 2010 23:5310:3727.229 038 LOG <test0> [client00web_server_cowri2cqf9i4.start] INFO: Starting k8s deployment for sc972b27b7f5d4835976efbe93316e253s61b2002abe554457a78050174c431719-nginx-web, image: nginx, env: {'CONSUL_HOST': u'consul-server.onap', 'SERVICE_TAGS': 'test0', 'CONFIG_BINDING_SERVICE': 'config-binding-service'}, kwargs: {'readiness': {u'endpoint': u'/', u'type': u'http'}, 'labels': {'cfydeployment': u'test0', 'cfynodeinstance': u'client00web_server_cowri2cqf9i4', 'cfynode': u'client00web_server'}, 'tls_info': {}, 'envs': {'SERVICE_TAGS': 'test0'}, 'liveness': {}, 'resource_config': {}, 'volumes': [], 'log_info': {}, 'ports': [u'80:0'], 'k8s_location': u'central'}

2019-05-09 2010 23:5310:3727.732 542 LOG <test0> [client00web_server_cowri2cqf9i4.start] INFO: Passing k8sconfig: {'tls': {u'cert_path': u'/opt/tls/shared', u'image': u'nexus3.onap.org:10001/onap/org.onap.dcaegen2.deployments.tls-init-container:1.0.3'}, 'filebeat': {u'config_map': u'dcae-filebeat-configmap', u'config_path': u'/usr/share/filebeat/filebeat.yml', u'log_path': u'/var/log/onap', u'image': u'docker.elastic.co/beats/filebeat:5.5.0', u'data_path': u'/usr/share/filebeat/data', u'config_subpath': u'filebeat.yml'}, 'consul_dns_name': u'consul-server.onap', 'image_pull_secrets': [u'onap-docker-registry-key'], 'namespace': u'onap', 'consul_host': 'consul-server:8500', 'default_k8s_location': u'central'}

2019-05-09 2010 23:5310:3828.354 181 LOG <test0> [client00web_server_cowri2cqf9i4.start] INFO: k8s deployment initiated successfully for sc972b27b7f5d4835976efbe93316e253s61b2002abe554457a78050174c431719-nginx-web: {'services': ['sc972b27b7f5d4835976efbe93316e253s61b2002abe554457a78050174c431719-nginx-web'], 'namespace': u'onap', 'location': u'central', 'deployment': 'dep-sc972b27b7f5d4835976efbe93316e253s61b2002abe554457a78050174c431719-nginx-web'}

2019-05-09 2010 23:5310:3828.354 181 LOG <test0> [client00web_server_cowri2cqf9i4.start] INFO: Waiting up to 1800 secs for sc972b27b7f5d4835976efbe93316e253s61b2002abe554457a78050174c431719-nginx-web to become ready

2019-05-09 2010 23:5410:3655.905 773 LOG <test0> [client00web_server_cowri2cqf9i4.start] INFO: k8s deployment is ready for: sc972b27b7f5d4835976efbe93316e253Done starting: s61b2002abe554457a78050174c431719-nginx-web

2019-05-09 2010 23:5410:3755.429 251 LOG <test0> [client00web_server_cowri2cqf9i4.start] INFO: Done starting: sc972b27b7f5d4835976efbe93316e253k8s deployment is ready for: s61b2002abe554457a78050174c431719-nginx-web

2019-05-09 2010 23:5410:3856.176 506 CFY <test0> [client00web_server_cowri2cqf9i4.start] Task succeeded 'k8splugin.create_and_start_container_for_components_with_streams'

2019-05-09 2010 23:5410:3857.176 058 CFY <test0> [client00web_server_cowri2cqf9i4] Node instance started

2019-05-09 2010 23:5410:3857.792 058 CFY <test0> 'install' workflow execution succeeded

Finished executing workflow install on deployment test0

* Run 'cfy events list -e 99a9d61a7a4e25eb-e62ccf1e-4e834d91-ae3e9004-baa20a8eea3960e4ecdff536' to retrieve the execution's events/logs

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# curl http://dmaap-bc:8080/webapi/topics/"org.onap.dmaap.mr.topic00_name" | python -mjson.tool

% Total Total   % Received % Xferd Average Speed Speed   Time   Time     Time Time Time Current

Dload Upload Total Spent                                  Dload Upload   Total   Spent   Left Speed

100 738 100 738 0 0 27245 0 100   715 100   715   0     0 36634     0 --:--:-- --:--:-- --:--:-- 2838437631

{

   "clients": [

       {

           "action": [

               "view",

               "pub"

           ],

           "clientRole": "org.onap.dcae.pnfPublisher",

           "dcaeLocationName": "san-francisco",

           "fqtn": "org.onap.dmaap.mr.topic00_name",

           "lastMod": "2019-05-09T2010T23:5310:3120.39111",

           "mrClientId": "15574352113911557529820110",

           "status": "VALID",

           "topicURL": "http://message-router:3904/events/org.onap.dmaap.mr.topic00_name"

       }

   ],

   "fqtn": "org.onap.dmaap.mr.topic00_name","globalMrURL": "message-router",
"

   "lastMod": "2019-05-09T2010T23:5310:1906.247078",

   "owner": "dcaeorch",

   "partitionCount": "2",

   "publisherRole": "org.onap.dmaap.mr.topic00_name.publisher",

   "replicationCase": "REPLICATION_EDGE_TO_CENTRAL_TO_GLOBALNONE",

   "replicationCount": "1",

   "status": "VALID",

   "subscriberRole": "org.onap.dmaap.mr.topic00_name.subscriber",

   "topicDescription": "No description provided",

   "topicName": "topic00_name",

   "type": "topic"

}

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# curl http://dmaap-bc:8080/webapi/topics/"org.onap.dmaap.mr.topic01_name" | python -mjson.tool

% Total Total   % Received % Xferd Average Speed Speed   Time   Time     Time Time Time Current

Dload Upload Total Spent                                  Dload Upload   Total   Spent   Left Speed

100 697 100 697 0 0 47062 0 100   717 100   717   0     0 43184     0 --:--:-- --:--:-- --:--:-- 4978544812

{

   "clients": [

       {

           "action": [

               "view",

               "sub"

           ],

           "clientRole": "org.onap.dcae.pnfSubscriber",

           "dcaeLocationName": "san-francisco",

           "fqtn": "org.onap.dmaap.mr.topic01_name",

           "lastMod": "2019-05-09T2010T23:5310:3323.81378",

           "mrClientId": "15574352138101557529823378",

           "status": "VALID",

           "topicURL": "http://message-router:3904/events/org.onap.dmaap.mr.topic01_name"

       }

   ],

   "fqtn": "org.onap.dmaap.mr.topic01_name",

   "lastMod": "2019-05-09T2010T23:5310:1905.448877",

   "owner": "dcaeorch",

   "partitionCount": "2",

   "publisherRole": "org.onap.dmaap.mr.topic01_name.publisher",

   "replicationCase": "REPLICATION_EDGE_TO_CENTRALNONE",

   "replicationCount": "1",

   "status": "VALID",

   "subscriberRole": "org.onap.dmaap.mr.topic01_name.subscriber",

   "topicDescription": "No description provided",

   "topicName": "topic01_name",

   "type": "topic"

}

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# curl http://dmaap-bc:8080/webapi/mr_clients/15574352113911557529820110 | python -mjson.tool

% Total Total   % Received % Xferd Average Speed Time Time Speed   Time   Time     Time Current

Dload Upload Total Spent                                  Dload Upload   Total   Spent   Left Speed

100 311 100 311 0 0 4675 0 100   320 100   320   0     0   9200     0 --:--:-- --:--:-- --:--:-- 471211428

{

   "action": [

       "view",

       "pub"

   ],

   "clientRole": "org.onap.dcae.pnfPublisher",

   "dcaeLocationName": "san-francisco",

   "fqtn": "org.onap.dmaap.mr.topic00_name",

   "lastMod": "2019-05-09T2010T23:5310:3120.39111",

   "mrClientId": "15574352113911557529820110",

   "status": "VALID",

   "topicURL": "http://message-router:3904/events/org.onap.dmaap.mr.topic00_name",

   "type": "mr_Client"

}

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# curl http://dmaap-bc:8080/webapi/mr_clients/15574352138101557529823378 | python -mjson.tool

% Total Total   % Received % Xferd Average Speed Speed   Time   Time     Time Time Time Current

Dload Upload Total Spent                                  Dload Upload   Total   Spent   Left Speed

100 311 100 311 0 0 9155 0 100   322 100   322   0     0   7471     0 --:--:-- --:--:-- --:--:-- 94247666

{

   "action": [

      "view",

       "sub"

   ],

   "clientRole": "org.onap.dcae.pnfSubscriber",

   "dcaeLocationName": "san-francisco",

   "fqtn": "org.onap.dmaap.mr.topic01_name",

   "lastMod": "2019-05-09T2010T23:5310:3323.81378",

   "mrClientId": "15574352138101557529823378",

   "status": "VALID",

   "topicURL": "http://message-router:3904/events/org.onap.dmaap.mr.topic01_name",

   "type": "mr_Client"

}

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# cfy uninstall test0
Executing workflow uninstall on deployment test0 [timeout=900 seconds]
2019-05-09 21:19:31.746 CFY <test0> Starting 'uninstall' workflow execution
2019-05-09 21:19:33.549 CFY <test0> [client00_cowri2] Stopping node instance
2019-05-09 21:19:34.227 CFY <test0> [client00_cowri2.stop] Sending task 'k8splugin.stop_and_remove_container'
2019-05-09 21:19:39.435 CFY <test0> [client00_cowri2.stop] Task succeeded 'k8splugin.stop_and_remove_container'
2019-05-09 21:19:40.087 CFY <test0> [client00_cowri2] Stopped node instance
2019-05-09 21:19:40.087 CFY <test0> [client00_cowri2] Unlinking relationships
2019-05-09 21:19:40.768 CFY <test0> [unlink] Sending task 'dmaapplugin.mr_relationships.delete_mr_client'
2019-05-09 21:19:41.896 LOG <test0> [unlink] INFO: Attempting to delete client 1557435213810
2019-05-09 21:19:42.399 LOG <test0> [unlink] INFO: Deleting URL: http://dmaap-bc:8080/webapi/mr_clients/1557435213810
2019-05-09 21:19:42.399 LOG <test0> [unlink] INFO: Deleted client 1557435213810
2019-05-09 21:19:42.946 CFY <test0> [unlink] Task succeeded 'dmaapplugin.mr_relationships.delete_mr_client'
2019-05-09 21:19:42.946 CFY <test0> [unlink] Sending task 'dmaapplugin.mr_relationships.delete_mr_client'
2019-05-09 21:19:44.465 LOG <test0> [unlink] INFO: Attempting to delete client 1557435211391
2019-05-09 21:19:45.183 LOG <test0> [unlink] INFO: Deleting URL: http://dmaap-bc:8080/webapi/mr_clients/1557435211391
2019-05-09 21:19:45.183 LOG <test0> [unlink] INFO: Deleted client 1557435211391
2019-05-09 21:19:45.771 CFY <test0> [unlink] Task succeeded 'dmaapplugin.mr_relationships.delete_mr_client'
2019-05-09 21:19:45.771 CFY <test0> [client00_cowri2] Relationships unlinked
2019-05-09 21:19:45.771 CFY <test0> [client00_cowri2/opt/consul/bin/consul kv export | grep key

               "key": "dcae-dashboard",

               "key": "dcae-hv-ves-collector",

               "key": "dcae-prh",

               "key": "dcae-snmptrap-collector",

               "key": "dcae-tca-analytics",

               "key": "dcae-ves-collector",

               "key": "deployment_handler",

               "key": "dmaap-plugin",

               "key": "holmes-engine-mgmt",

               "key": "holmes-rule-mgmt",

               "key": "k8s-plugin",

               "key": "s61b2002abe554457a78050174c431719-nginx-web",

               "key": "s61b2002abe554457a78050174c431719-nginx-web:dmaap",

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# /opt/consul/bin/consul kv get s61b2002abe554457a78050174c431719-nginx-web:dmaap | python -mjson.tool

{

   "topic00": {

       "client_id": "1557529820110",

       "client_role": "org.onap.dcae.pnfPublisher",

       "location": "san-francisco",

       "topic_url": "http://message-router:3904/events/org.onap.dmaap.mr.topic00_name"

   },

   "topic01": {

       "client_id": "1557529823378",

       "client_role": "org.onap.dcae.pnfSubscriber",

       "location": "san-francisco",

       "topic_url": "http://message-router:3904/events/org.onap.dmaap.mr.topic01_name"

   }

}

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# cfy uninstall test0

Executing workflow uninstall on deployment test0 [timeout=900 seconds]

2019-05-10 23:14:49.904 CFY <test0> Starting 'uninstall' workflow execution

2019-05-10 23:14:52.322 CFY <test0> [web_server_cqf9i4] Stopping node instance

2019-05-10 23:14:53.438 CFY <test0> [web_server_cqf9i4.stop] Sending task 'k8splugin.stop_and_remove_container'

2019-05-10 23:15:01.207 CFY <test0> [web_server_cqf9i4.stop] Task succeeded 'k8splugin.stop_and_remove_container'

2019-05-10 23:15:01.921 CFY <test0> [web_server_cqf9i4] Stopped node instance

2019-05-10 23:15:02.464 CFY <test0> [web_server_cqf9i4] Unlinking relationships

2019-05-10 23:15:02.464 CFY <test0> [unlink] Sending task 'dmaapplugin.mr_relationships.delete_mr_client'

2019-05-10 23:15:06.207 LOG <test0> [unlink] INFO: Deleting URL: http://dmaap-bc:8080/webapi/mr_clients/1557529823378

2019-05-10 23:15:05.464 LOG <test0> [unlink] INFO: Attempting to delete client 1557529823378

2019-05-10 23:15:06.207 LOG <test0> [unlink] INFO: Deleted client 1557529823378

2019-05-10 23:15:06.207 CFY <test0> [unlink] Task succeeded 'dmaapplugin.mr_relationships.delete_mr_client'

2019-05-10 23:15:06.867 CFY <test0> [unlink] Sending task 'dmaapplugin.mr_relationships.delete_mr_client'

2019-05-10 23:15:07.929 LOG <test0> [unlink] INFO: Attempting to delete client 1557529820110

2019-05-10 23:15:08.469 LOG <test0> [unlink] INFO: Deleting URL: http://dmaap-bc:8080/webapi/mr_clients/1557529820110

2019-05-10 23:15:08.469 LOG <test0> [unlink] INFO: Deleted client 1557529820110

2019-05-10 23:15:09.102 CFY <test0> [unlink] Task succeeded 'dmaapplugin.mr_relationships.delete_mr_client'

2019-05-10 23:15:09.102 CFY <test0> [web_server_cqf9i4] Relationships unlinked

2019-05-10 23:15:09.645 CFY <test0> [web_server_cqf9i4] Deleting node instance

2019-05-10 23:15:09.645 CFY <test0> [web_server_cqf9i4.delete] Sending task 'k8splugin.cleanup_discovery'

2019-05-10 23:15:12.474 CFY <test0> [web_server_cqf9i4.delete] Task succeeded 'k8splugin.cleanup_discovery'

2019-05-10 23:15:13.113 CFY <test0> [web_server_cqf9i4] Deleted node instance

2019-05-10 23:15:13.773 CFY <test0> [topic01_xjti5i] Stopping node instance

2019-05-10 23:15:14.311 CFY <test0> [topic00_ehyrmr] Stopping node instance

2019-05-10 23:15:15.004 CFY <test0> [topic01_xjti5i] Stopped node instance: nothing to do

2019-05-10 23:15:15.004 CFY <test0> [topic00_ehyrmr] Stopped node instance: nothing to do

2019-05-10 23:15:15.623 CFY <test0> [topic01_xjti5i] Unlinking relationships

2019-05-10 23:15:16.196 CFY <test0> [topic00_ehyrmr] Unlinking relationships

2019-05-10 23:15:16.196 CFY <test0> [topic01_xjti5i] Relationships unlinked

2019-05-10 23:15:16.807 CFY <test0> [topic01_xjti5i] Deleting node instance

2019-05-10 23:15:17.481 CFY <test0> [topic00_ehyrmr] Relationships unlinked

2019-05-10 23:15:17.481 CFY <test0> [topic01_xjti5i.delete] Sending task 'dmaapplugin.mr_lifecycle.delete_topic'

2019-05-10 23:15:18.122 CFY <test0> [topic00_ehyrmr] Deleting node instance

2019-05-09 2110 23:1915:4618.505 122 CFY <test0> [client00topic00_cowri2ehyrmr.delete] Sending task 'k8splugin.cleanup_discoverydmaapplugin.mr_lifecycle.delete_topic'

2019-05-09 2110 23:15:19:48.010 CFY 570 LOG <test0> [client00topic01_cowri2xjti5i.delete] Task succeeded 'k8splugin.cleanup_discovery'INFO: Attempting to delete topic org.onap.dmaap.mr.topic01_name

2019-05-09 2110 23:1915:4820.659 CFY <test0> [client00_cowri2] Deleted node instance084 LOG <test0> [topic01_xjti5i.delete] INFO: Deleting URL: http://dmaap-bc:8080/webapi/topics/org.onap.dmaap.mr.topic01_name

2019-05-09 2110 23:1915:4920.224 616 CFY <test0> [topic00topic01_incvxj] Stopping node instancexjti5i.delete] Task succeeded 'dmaapplugin.mr_lifecycle.delete_topic'

2019-05-09 2110 23:1915:4920.224 616 CFY <test0> [topic01_34hei2xjti5i] Stopping Deleted node instance

2019-05-09 2110 23:1915:4921.224 CFY <test0> [topic01_34hei2] Stopped node instance: nothing to do133 LOG <test0> [topic00_ehyrmr.delete] INFO: Attempting to delete topic org.onap.dmaap.mr.topic00_name

2019-05-09 2110 23:1915:4921.904 CFY 133 LOG <test0> [topic00_incvxj] Stopped node instance: nothing to doehyrmr.delete] INFO: Deleting URL: http://dmaap-bc:8080/webapi/topics/org.onap.dmaap.mr.topic00_name

2019-05-09 2110 23:1915:4921.904 849 CFY <test0> [topic01topic00_34hei2] Unlinking relationshipsehyrmr.delete] Task succeeded 'dmaapplugin.mr_lifecycle.delete_topic'

2019-05-09 2110 23:1915:5022.454 628 CFY <test0> [topic00_incvxj] Unlinking relationshipsehyrmr] Deleted node instance

2019-05-09 2110 23:1915:5023.454 CFY <test0> [topic01_34hei2] Relationships unlinked
2019-05-09 21:19:50.454 CFY <test0> [topic00_incvxj] Relationships unlinked
2019-05-09 21:19:51.111 CFY <test0> [topic01_34hei2] Deleting node instance
2019-05-09 21:19:51.111 CFY <test0> [topic00_incvxj] Deleting node instance
2019-05-09 21:19:51.111 CFY <test0> [topic01_34hei2.delete] Sending task 'dmaapplugin.mr_lifecycle.delete_topic'
2019-05-09 21:19:51.690 CFY <test0> [topic00_incvxj.delete] Sending task 'dmaapplugin.mr_lifecycle.delete_topic'
2019-05-09 21:19:54.373 LOG <test0> [topic01_34hei2.delete] INFO: Deleting URL: 263 CFY <test0> 'uninstall' workflow execution succeeded

Finished executing workflow uninstall on deployment test0

* Run 'cfy events list -e 352271ca-ed0d-4823-9ebf-b2fd827f1e83' to retrieve the execution's events/logs

Deleting deployment test0...

Deployment deleted

Deleting blueprint test0...

An error occurred on the server: 400: Can't delete blueprint test0 - There exist deployments for this blueprint; Deployments ids: test0

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# cfy blueprints delete test0

Deleting blueprint test0...

Blueprint deleted

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# curl http://dmaap-bc:8080/webapi/topics/"org.onap.dmaap.mr.topic01
2019-05-09 21:19:53.839 LOG <test0> [topic01_34hei2.delete] INFO: Attempting to delete topic .mr.topic00_name" | python -mjson.tool

% Total   % Received % Xferd Average Speed   Time   Time     Time Current

                                 Dload Upload   Total   Spent   Left Speed

100   97 100   97   0     0 10192     0 --:--:-- --:--:-- --:--:-- 10777

{

   "code": 404,

   "fields": "fqtn",

   "message": "topic with fqtn org.onap.dmaap.mr.topic01
2019-05-09 21:19:54.373 LOG <test0> [topic00_incvxj.delete] INFO: Deleting URL: topic00_name not found"

}

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# curl http://dmaap-bc:8080/webapi/topics/"org.onap.dmaap.mr.topic00
2019-05-09 21:19:54.373 LOG <test0> [topic00_incvxj.delete] INFO: Attempting to delete topic org.onap.dmaap.mr.topic00
2019-05-09 21:19:55.023 CFY <test0> [topic00_incvxj.delete] Task succeeded 'dmaapplugin.mr_lifecycle.delete_topic'
2019-05-09 21:19:55.023 CFY <test0> [topic00_incvxj] Deleted node instance
2019-05-09 21:19:55.023 CFY <test0> [topic01_34hei2.delete] Task succeeded 'dmaapplugin.mr_lifecycle.delete_topic'
2019-05-09 21:19:55.700 CFY <test0> [topic01_34hei2] Deleted node instance
2019-05-09 21:19:56.265 CFY <test0> 'uninstall' workflow execution succeeded
Finished executing workflow uninstall on deployment test0
* Run 'cfy events list -e c64fff98-4277-4f07-8905-284c50c61f1c' to retrieve the execution's events/logs
Deleting deployment test0...
Deployment deleted
Deleting blueprint test0...
An error occurred on the server: 400: Can't delete blueprint test0 - There exist deployments for this blueprint; Deployments ids: test0
[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# cfy blueprints delete test0
Deleting blueprint test0...
Blueprint deletedtopic01_name" | python -mjson.tool

% Total   % Received % Xferd Average Speed   Time   Time     Time Current

                                 Dload Upload   Total   Spent   Left Speed

100   97 100   97   0     0   6631     0 --:--:-- --:--:-- --:--:-- 6928

{

   "code": 404,

   "fields": "fqtn",

   "message": "topic with fqtn org.onap.dmaap.mr.topic01_name not found"

}

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# curl http://dmaap-bc:8080/webapi/mr_clients/1557529820110 | python -mjson.tool

% Total   % Received % Xferd Average Speed   Time   Time     Time Current

                                Dload Upload   Total   Spent   Left Speed

100   81 100   81   0     0   9157     0 --:--:-- --:--:-- --:--:-- 10125

{

   "code": 404,

   "fields": "mrClientId",

   "message": "mrClientId 1557529820110 not found"

}

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# curl http://dmaap-bc:8080/webapi/topics/org.onap.dmaap.mr.topic00mr_clients/1557529823378 | python -mjson.tool

% Total Total   % Received % Xferd Average Speed Time Time Speed   Time   Time     Time Current

Dload Upload Total Spent                                  Dload Upload   Total   Spent   Left Speed

100 92 100 92 0 0 842 0 100   81 100   81   0     0   1762     0 --:--:-- --:--:-- --:--:-- 8443240

{

   "code": 404,

   "fields": "fqtnmrClientId",

   "message": "topic with fqtn org.onap.dmaap.mr.topic00 mrClientId 1557529823378 not found"

}

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# curl http: /opt/dmaap-bc:8080/webapi/topics/org.onap.dmaap.mr.topic001| python -mjson.tool
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 93 100 93 0 0 540 0 --:--:-- --:--:-- --:--:-- 540
{
"code": 404,
"fields": "fqtn",
"message": "topic with fqtn org.onap.dmaap.mr.topic001 not found"
}consul/bin/consul kv export | grep key

               "key": "dcae-dashboard",

               "key": "dcae-hv-ves-collector",

               "key": "dcae-prh",

               "key": "dcae-snmptrap-collector",

               "key": "dcae-tca-analytics",

               "key": "dcae-ves-collector",

               "key": "deployment_handler",

               "key": "dmaap-plugin",

               "key": "holmes-engine-mgmt",

               "key": "holmes-rule-mgmt",

               "key": "k8s-plugin",

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# blueprints]#

The screen output for all the blueprints are available in the attached file. <link to be added later>


Validation

<expected logs + consul entry + curl commands/postman + any other steps for verification from MS standpoint>

After deploying a blueprint, we run curl commands to query DMaap DBCL configuration. For example, after deploying test_mr_pubsub.yaml, we can check whether topic00 is created in DBCL:

curl http://dmaap-bc:8080/webapi/mr_clients/1557435211391 | python -mjson.tool
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 81 100 81 0 0 4404 0 --:--:-- --:--:-- --:--:-- 4500
{
"code": 404,
"fields": "mrClientId",
"message": "mrClientId 1557435211391 not found"
}
topics/"org.onap.dmaap.mr.topic00_name" | python -mjson.tool

The return value of the query command is:

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# curl http://dmaap-bc:8080/webapi/topics/"org.onap.dmaap.mr_clients/1557435213810.topic00_name" | python -mjson.tool

% Total Total   % Received % Xferd Average Speed Time Time Speed   Time   Time     Time Current

Dload Upload Total Spent                                  Dload Upload   Total   Spent   Left Speed

100 81 100 81 0 0 1889 0 100   715 100   715   0     0 36634     0 --:--:-- --:--:-- --:--:-- --:--:-- --:--:-- 1928
{
"code": 404,
"fields": "mrClientId",
"message": "mrClientId 1557435213810 not found"
}
[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]#

Examples of deploy/un-deploy commands, the curl commands for checking DMaap DBCL configuration, and screen output for all the blueprints are available in the attached file. <link?>

Validation

<expected logs + consul entry + curl commands/postman + any other steps for verification from MS standpoint>

After deploying a blueprint, we run curl commands to query DMaap DBCL configuration. For example, after deploying test_mr_pubsub.yaml, we can check whether topic00 is created in DBCL:

curl http://dmaap-bc:8080/webapi/topics/37631

{

   "clients": [

       {

           "action": [

               "view",

               "pub"

           ],

           "clientRole": "org.onap.dcae.pnfPublisher",

           "dcaeLocationName": "san-francisco",

           "fqtn": "org.onap.dmaap.mr.topic00_name",

           "lastMod": "2019-05-10T23:10:20.11",

           "mrClientId": "1557529820110",

           "status": "VALID",

           "topicURL": "http://message-router:3904/events/org.onap.dmaap.mr.topic00_name"

       }

   ],

   "fqtn": "org.onap.dmaap.mr.topic00_name",

   "lastMod": "2019-05-10T23:10:06.078",

   "owner": "dcaeorch",

   "partitionCount": "2",

   "publisherRole": "org.onap.dmaap.mr.topic00_name.publisher",

   "replicationCase": "REPLICATION_NONE",

   "replicationCount": "1",

   "status": "VALID",

   "subscriberRole": "org.onap.dmaap.mr.topic00 | python -mjson.tool

...

.topic00_name.subscriber",

   "topicDescription": "No description provided",

   "topicName": "topic00_name",

   "type": "topic"

}

The output contains the client ID associated with the topic ("mrClientId": "1557529820110"). We use the client ID to check the client creation in DBCL:

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# curl http://dmaap-bc:8080/webapi/topics/org.onap.dmaap.mr.topic00mr_clients/1557529820110 | python -mjson.tool

% Total Total   % Received % Xferd Average Speed Speed   Time   Time     Time Time Time CurrentDload Upload Total Spent

                                 Dload Upload   Total   Spent   Left Speed

100 738 100 738 0 0 27245 0 100   320 100   320   0     0   9200     0 --:--:-- --:--:-- --:--:-- 2838411428

{"clients": [
{

   "action": [

       "view",

       "pub"

   ],

   "clientRole": "org.onap.dcae.pnfPublisher",

   "dcaeLocationName": "san-francisco",

   "fqtn": "org.onap.dmaap.mr.topic00_name",

   "lastMod": "2019-05-09T2010T23:5310:3120.39111",

   "mrClientId": "15574352113911557529820110",

   "status": "VALID",

   "topicURL": "http://message-router:3904/events/org.onap.dmaap.mr.topic00_name"
}
],

   "fqtntype": "org.onap.dmaap.mr.topic00",
"globalMrURL": "message-router",
"lastMod": "2019-05-09T20:53:19.247",
"owner": "dcaeorch",
"partitionCount": "2",
"publisherRole": "org.onap.dmaap.mr.topic00.publisher",
"replicationCase": "REPLICATION_EDGE_TO_CENTRAL_TO_GLOBAL",
"replicationCount": "1",
"status": "VALID",
"subscriberRole": "org.onap.dmaap.mr.topic00.subscriber",
"topicDescription": "No description provided",
"topicName": "topic00",
"type": "topic"
}

The output contains the client ID associated with the topic ("mrClientId": "1557435211391"). We use the client ID to check the client creation in DBCL:

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# curl http://dmaap-bc:8080/webapi/mr_clients/1557435211391 | python -mjson.tool
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 311 100 311 0 0 4675 0 --:--:-- --:--:-- --:--:-- 4712
{
"action": [
"view",
"pub"
],
"clientRolemr_Client"

}

Similarly we can verify the creation of topic01 and its client.

The consul kv should contain the service's information.

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# /opt/consul/bin/consul kv export | grep key

               "key": "dcae-dashboard",

               "key": "dcae-hv-ves-collector",

               "key": "dcae-prh",

               "key": "dcae-snmptrap-collector",

               "key": "dcae-tca-analytics",

               "key": "dcae-ves-collector",

               "key": "deployment_handler",

               "key": "dmaap-plugin",

               "key": "holmes-engine-mgmt",

               "key": "holmes-rule-mgmt",

               "key": "k8s-plugin",

               "key": "s61b2002abe554457a78050174c431719-nginx-web",

               "key": "s61b2002abe554457a78050174c431719-nginx-web:dmaap",

The detailed dmaap information of the new service is available in the value of key s61b2002abe554457a78050174c431719-nginx-web:dmaap:

[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# /opt/consul/bin/consul kv get s61b2002abe554457a78050174c431719-nginx-web:dmaap | python -mjson.tool

{

   "topic00": {

       "client_id": "1557529820110",

       "client_role": "org.onap.dcae.pnfPublisher",

       "dcaeLocationNamelocation": "san-francisco",

"fqtn": "       "topic_url": "http://message-router:3904/events/org.onap.dmaap.mr.topic00_name"

   },

   "lastModtopic01": "2019-05-09T20:53:31.391{

       "client_id": "1557529823378",

       "mrClientIdclient_role": "1557435211391org.onap.dcae.pnfSubscriber",

       "statuslocation": "VALIDsan-francisco",

       "topicURLtopic_url": "http://message-router:3904/events/org.onap.dmaap.mr.topic00",
"type": "mr_Clienttopic01_name"

   }

...

}

After validation we undeploy the blueprints with command "cfy uninstall test0". Then we rerun the validation to make sure that the newly create topics and their clients are deleted from DMaap DBCL and consul.