You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 4 Next »



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)


Overview

<Brief write on how plugin is invoked and internal of plugin work flow)

The dmaap-plugin is invoked via k8s plugin or docker plugin. There are several test blueprints that you can run to test the DMaap-plugin in ONAP environment. 

Dmaap Plugin Dependencies

<components and configuration required for this plugin in ONAP DCAE eg Consul, Cloudify, Dmaap-DBCL, DMAAP)

Running the dmaap-plugin depends on the setup of Consul, Cloudify, Dmaap-DBCL, and AAF in ONAP environment. In the following discussion we assume that the Consul, Cloudify, DMaap-DBCL and AAF are already set up.

Blueprints

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

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

Currently we 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 /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 following dmaap kv into consul
{
    "dmaap" :
    {
        "username": "whatever",
        "password": "whatever",
        "owner" : "dcaeorch",
        "protocol" : "http"
    }
}
2) Add location san-francisco into DMaap DBCL


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 test_mr_pubsub_extra.yaml
Uploading blueprint test_mr_pubsub_extra.yaml...
test_mr_pubsub_ex... |################################################| 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-09 20:53:07.512 CFY <test0> Starting 'create_deployment_environment' workflow execution
2019-05-09 20:53:08.088 CFY <test0> Installing deployment plugins
2019-05-09 20:53:08.088 CFY <test0> Sending task 'cloudify_agent.operations.install_plugins'
2019-05-09 20:53:08.088 CFY <test0> Task started 'cloudify_agent.operations.install_plugins'
2019-05-09 20:53:08.742 LOG <test0> INFO: Installing plugin: k8s
2019-05-09 20:53:08.742 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-09 20:53:08.742 LOG <test0> INFO: Installing plugin: dmaapplugin
2019-05-09 20:53:09.987 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-09 20:53:09.987 CFY <test0> Task succeeded 'cloudify_agent.operations.install_plugins'
2019-05-09 20:53:09.987 CFY <test0> Skipping starting deployment policy engine core - no policies defined
2019-05-09 20:53:09.987 CFY <test0> Creating deployment work directory
2019-05-09 20:53:09.987 CFY <test0> 'create_deployment_environment' workflow execution succeeded
2019-05-09 20:53:15.444 CFY <test0> Starting 'install' workflow execution
2019-05-09 20:53:17.083 CFY <test0> [topic00_incvxj] Creating node instance
2019-05-09 20:53:17.718 CFY <test0> [topic01_34hei2] Creating node instance
2019-05-09 20:53:17.718 CFY <test0> [topic00_incvxj.create] Sending task 'dmaapplugin.mr_lifecycle.create_topic'
2019-05-09 20:53:18.396 CFY <test0> [topic01_34hei2.create] Sending task 'dmaapplugin.mr_lifecycle.create_topic'
2019-05-09 20:53:19.322 LOG <test0> [topic00_incvxj.create] INFO: Attempting to create topic name topic00
2019-05-09 20:53:19.826 LOG <test0> [topic00_incvxj.create] INFO: Posting to URL: http://dmaap-bc:8080/webapi/topics with body: {'txenable': False, 'globalMrURL': u'message-router', 'replicationCase': u'REPLICATION_EDGE_TO_CENTRAL_TO_GLOBAL', 'topicDescription': 'No description provided', 'owner': u'dcaeorch', 'topicName': u'topic00'}
2019-05-09 20:53:19.826 LOG <test0> [topic01_34hei2.create] INFO: Attempting to create topic name topic01
2019-05-09 20:53:19.826 LOG <test0> [topic01_34hei2.create] INFO: Posting to URL: http://dmaap-bc:8080/webapi/topics with body: {'owner': u'dcaeorch', 'topicDescription': 'No description provided', 'topicName': u'topic01', 'replicationCase': u'REPLICATION_EDGE_TO_CENTRAL', 'txenable': False}
2019-05-09 20:53:21.331 CFY <test0> [topic01_34hei2.create] Task succeeded 'dmaapplugin.mr_lifecycle.create_topic'
2019-05-09 20:53:21.965 CFY <test0> [topic00_incvxj.create] Task succeeded 'dmaapplugin.mr_lifecycle.create_topic'
2019-05-09 20:53:21.965 CFY <test0> [topic01_34hei2] Node instance created
2019-05-09 20:53:21.965 CFY <test0> [topic00_incvxj] Node instance created
2019-05-09 20:53:22.648 CFY <test0> [topic01_34hei2] Configuring node instance: nothing to do
2019-05-09 20:53:22.648 CFY <test0> [topic00_incvxj] Configuring node instance: nothing to do
2019-05-09 20:53:22.648 CFY <test0> [topic01_34hei2] Starting node instance: nothing to do
2019-05-09 20:53:22.648 CFY <test0> [topic00_incvxj] Starting node instance: nothing to do
2019-05-09 20:53:23.375 CFY <test0> [topic01_34hei2] Node instance started
2019-05-09 20:53:23.995 CFY <test0> [topic00_incvxj] Node instance started
2019-05-09 20:53:24.700 CFY <test0> [client00_cowri2] Creating node instance
2019-05-09 20:53:25.368 CFY <test0> [client00_cowri2.create] Sending task 'k8splugin.create_for_components_with_streams'
2019-05-09 20:53:29.247 LOG <test0> [client00_cowri2.create] INFO: Done setting up: sc972b27b7f5d4835976efbe93316e253-nginx-web
2019-05-09 20:53:28.560 LOG <test0> [client00_cowri2.create] INFO: Added config for sc972b27b7f5d4835976efbe93316e253-nginx-web
2019-05-09 20:53:29.247 CFY <test0> [client00_cowri2.create] Task succeeded 'k8splugin.create_for_components_with_streams'
2019-05-09 20:53:29.857 CFY <test0> [client00_cowri2] Node instance created
2019-05-09 20:53:29.857 CFY <test0> [client00_cowri2] Pre-configuring relationships
2019-05-09 20:53:29.857 CFY <test0> [preconfigure] Sending task 'dmaapplugin.mr_relationships.add_mr_publisher'
2019-05-09 20:53:32.143 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> [preconfigure] INFO: Attempting to add client00 as publisher to topic org.onap.dmaap.mr.topic00
2019-05-09 20:53:32.143 LOG <test0> [preconfigure] INFO: Added publisher id 1557435211391 to feed org.onap.dmaap.mr.topic00 at san-francisco
2019-05-09 20:53:32.777 CFY <test0> [preconfigure] Task succeeded 'dmaapplugin.mr_relationships.add_mr_publisher'
2019-05-09 20:53:32.777 CFY <test0> [preconfigure] Sending task 'dmaapplugin.mr_relationships.add_mr_subscriber'
2019-05-09 20:53:33.963 LOG <test0> [preconfigure] INFO: Attempting to add client00 as subscriber to topic org.onap.dmaap.mr.topic01
2019-05-09 20:53:34.601 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', 'dcaeLocationName': u'san-francisco'}
2019-05-09 20:53:34.601 LOG <test0> [preconfigure] INFO: Added subscriber id 1557435213810 to feed org.onap.dmaap.mr.topic01 at san-francisco
2019-05-09 20:53:35.180 CFY <test0> [preconfigure] Task succeeded 'dmaapplugin.mr_relationships.add_mr_subscriber'
2019-05-09 20:53:35.180 CFY <test0> [client00_cowri2] Relationships pre-configured
2019-05-09 20:53:35.802 CFY <test0> [client00_cowri2] Configuring node instance: nothing to do
2019-05-09 20:53:35.802 CFY <test0> [client00_cowri2] Starting node instance
2019-05-09 20:53:35.802 CFY <test0> [client00_cowri2.start] Sending task 'k8splugin.create_and_start_container_for_components_with_streams'
2019-05-09 20:53:37.229 LOG <test0> [client00_cowri2.start] INFO: Starting k8s deployment for sc972b27b7f5d4835976efbe93316e253-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'client00_cowri2', 'cfynode': u'client00'}, 'tls_info': {}, 'envs': {'SERVICE_TAGS': 'test0'}, 'liveness': {}, 'resource_config': {}, 'volumes': [], 'log_info': {}, 'ports': [u'80:0'], 'k8s_location': u'central'}
2019-05-09 20:53:37.732 LOG <test0> [client00_cowri2.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 20:53:38.354 LOG <test0> [client00_cowri2.start] INFO: k8s deployment initiated successfully for sc972b27b7f5d4835976efbe93316e253-nginx-web: {'services': ['sc972b27b7f5d4835976efbe93316e253-nginx-web'], 'namespace': u'onap', 'location': u'central', 'deployment': 'dep-sc972b27b7f5d4835976efbe93316e253-nginx-web'}
2019-05-09 20:53:38.354 LOG <test0> [client00_cowri2.start] INFO: Waiting up to 1800 secs for sc972b27b7f5d4835976efbe93316e253-nginx-web to become ready
2019-05-09 20:54:36.905 LOG <test0> [client00_cowri2.start] INFO: k8s deployment is ready for: sc972b27b7f5d4835976efbe93316e253-nginx-web
2019-05-09 20:54:37.429 LOG <test0> [client00_cowri2.start] INFO: Done starting: sc972b27b7f5d4835976efbe93316e253-nginx-web
2019-05-09 20:54:38.176 CFY <test0> [client00_cowri2.start] Task succeeded 'k8splugin.create_and_start_container_for_components_with_streams'
2019-05-09 20:54:38.176 CFY <test0> [client00_cowri2] Node instance started
2019-05-09 20:54:38.792 CFY <test0> 'install' workflow execution succeeded
Finished executing workflow install on deployment test0
* Run 'cfy events list -e 99a9d61a-e62c-4e83-ae3e-baa20a8eea39' 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 | python -mjson.tool
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 738 100 738 0 0 27245 0 --:--:-- --:--:-- --:--:-- 28384
{
"clients": [
{
"action": [
"view",
"pub"
],
"clientRole": "org.onap.dcae.pnfPublisher",
"dcaeLocationName": "san-francisco",
"fqtn": "org.onap.dmaap.mr.topic00",
"lastMod": "2019-05-09T20:53:31.391",
"mrClientId": "1557435211391",
"status": "VALID",
"topicURL": "http://message-router:3904/events/org.onap.dmaap.mr.topic00"
}
],
"fqtn": "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"
}
[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# curl http://dmaap-bc:8080/webapi/topics/org.onap.dmaap.mr.topic01 | python -mjson.tool
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 697 100 697 0 0 47062 0 --:--:-- --:--:-- --:--:-- 49785
{
"clients": [
{
"action": [
"view",
"sub"
],
"clientRole": "org.onap.dcae.pnfSubscriber",
"dcaeLocationName": "san-francisco",
"fqtn": "org.onap.dmaap.mr.topic01",
"lastMod": "2019-05-09T20:53:33.81",
"mrClientId": "1557435213810",
"status": "VALID",
"topicURL": "http://message-router:3904/events/org.onap.dmaap.mr.topic01"
}
],
"fqtn": "org.onap.dmaap.mr.topic01",
"lastMod": "2019-05-09T20:53:19.448",
"owner": "dcaeorch",
"partitionCount": "2",
"publisherRole": "org.onap.dmaap.mr.topic01.publisher",
"replicationCase": "REPLICATION_EDGE_TO_CENTRAL",
"replicationCount": "1",
"status": "VALID",
"subscriberRole": "org.onap.dmaap.mr.topic01.subscriber",
"topicDescription": "No description provided",
"topicName": "topic01",
"type": "topic"
}
[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"
],
"clientRole": "org.onap.dcae.pnfPublisher",
"dcaeLocationName": "san-francisco",
"fqtn": "org.onap.dmaap.mr.topic00",
"lastMod": "2019-05-09T20:53:31.391",
"mrClientId": "1557435211391",
"status": "VALID",
"topicURL": "http://message-router:3904/events/org.onap.dmaap.mr.topic00",
"type": "mr_Client"
}
[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# curl http://dmaap-bc:8080/webapi/mr_clients/1557435213810 | python -mjson.tool
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 311 100 311 0 0 9155 0 --:--:-- --:--:-- --:--:-- 9424
{
"action": [
"view",
"sub"
],
"clientRole": "org.onap.dcae.pnfSubscriber",
"dcaeLocationName": "san-francisco",
"fqtn": "org.onap.dmaap.mr.topic01",
"lastMod": "2019-05-09T20:53:33.81",
"mrClientId": "1557435213810",
"status": "VALID",
"topicURL": "http://message-router:3904/events/org.onap.dmaap.mr.topic01",
"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] Deleting node instance
2019-05-09 21:19:46.505 CFY <test0> [client00_cowri2.delete] Sending task 'k8splugin.cleanup_discovery'
2019-05-09 21:19:48.010 CFY <test0> [client00_cowri2.delete] Task succeeded 'k8splugin.cleanup_discovery'
2019-05-09 21:19:48.659 CFY <test0> [client00_cowri2] Deleted node instance
2019-05-09 21:19:49.224 CFY <test0> [topic00_incvxj] Stopping node instance
2019-05-09 21:19:49.224 CFY <test0> [topic01_34hei2] Stopping node instance
2019-05-09 21:19:49.224 CFY <test0> [topic01_34hei2] Stopped node instance: nothing to do
2019-05-09 21:19:49.904 CFY <test0> [topic00_incvxj] Stopped node instance: nothing to do
2019-05-09 21:19:49.904 CFY <test0> [topic01_34hei2] Unlinking relationships
2019-05-09 21:19:50.454 CFY <test0> [topic00_incvxj] Unlinking relationships
2019-05-09 21:19:50.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: 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 org.onap.dmaap.mr.topic01
2019-05-09 21:19:54.373 LOG <test0> [topic00_incvxj.delete] INFO: Deleting URL: 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 deleted
[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# curl http://dmaap-bc:8080/webapi/topics/org.onap.dmaap.mr.topic00 | python -mjson.tool
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 92 100 92 0 0 842 0 --:--:-- --:--:-- --:--:-- 844
{
"code": 404,
"fields": "fqtn",
"message": "topic with fqtn org.onap.dmaap.mr.topic00 not found"
}
[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# curl http://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"
}
[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 81 100 81 0 0 4404 0 --:--:-- --:--:-- --:--:-- 4500
{
"code": 404,
"fields": "mrClientId",
"message": "mrClientId 1557435211391 not found"
}
[root@dev-dcaegen2-dcae-bootstrap-55cb5596b7-phdct blueprints]# curl http://dmaap-bc:8080/webapi/mr_clients/1557435213810 | python -mjson.tool
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 81 100 81 0 0 1889 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 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/topics/org.onap.dmaap.mr.topic00 | 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.topic00 | python -mjson.tool
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 738 100 738 0 0 27245 0 --:--:-- --:--:-- --:--:-- 28384
{
"clients": [
{
"action": [
"view",
"pub"
],
"clientRole": "org.onap.dcae.pnfPublisher",
"dcaeLocationName": "san-francisco",
"fqtn": "org.onap.dmaap.mr.topic00",
"lastMod": "2019-05-09T20:53:31.391",
"mrClientId": "1557435211391",
"status": "VALID",
"topicURL": "http://message-router:3904/events/org.onap.dmaap.mr.topic00"
}
],
"fqtn": "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"
],
"clientRole": "org.onap.dcae.pnfPublisher",
"dcaeLocationName": "san-francisco",
"fqtn": "org.onap.dmaap.mr.topic00",
"lastMod": "2019-05-09T20:53:31.391",
"mrClientId": "1557435211391",
"status": "VALID",
"topicURL": "http://message-router:3904/events/org.onap.dmaap.mr.topic00",
"type": "mr_Client"
}

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

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.


  • No labels