Re: [onap-discuss] [dcae][dcaegen2] Three Questions about DCAE 

2017-09-16 Thread CARPENTER, TOMMY J (TOMMY J)
See my explanation on #3 below thank you.

On Sep 16, 2017, at 1:52 PM, JI, LUSHENG (LUSHENG) 
> wrote:

Guangrong,

Please see inline for details.

Lusheng

 Original message 
From: fu.guangr...@zte.com.cn
Date: 9/16/17 3:59 AM (GMT-05:00)
To: "JI, LUSHENG (LUSHENG)" 
>
Cc: onap-discuss@lists.onap.org, 
peng.congc...@zte.com.cn, 
tian.shi...@zte.com.cn
Subject: [dcae][dcaegen2] Three Questions about DCAE


Hi Lusheng,


I've been trying to implement the basic integration of Holmes and DCAE, which 
is using the CBS to get the configuration information of other components. As 
the work went on, some questions arose:


1. There are two types of DMaaP topics: secure and unsecure. How to use the 
authentication information provided by DCAE while calling the DMaaP APIs? I do 
not see any APIs in terms of authentication in the DMaaP docs.

[lji]  DMaaP Message Routet actually supports 3 kinds of 
authentication/security mechasim: anonymous, API key, and AAF.  DCAE plans to 
use unauthenticated for R1.  I donot know if any component plans to use AAF.  
Using AAF requires additional provisioning steps and requires basic auth 
header.  The DMaaP project should have provided documentation for API.

2. When pulling data from DMaaP, the consumer group and the consumer ID are 
required (see below). Neither of them are embodied in the response message from 
the CBS above. How and where could we get those parameters?

[lji] These two parameters are under your control.   They together identify a 
subscriber to the Message Router.  DMaaP Message Router uses such info to 
decide when to advance message offset.  The MR guarantees message delivery to 
each group.  You may have multiple subscribers under the same group for the 
same topic as a load balancing measure, --each of them receives a subset of 
messages.  Different subscribers to the same topic, if each wishes to get all 
the messages, should use different group IDs.


3. If we want to get the CBS address, we have to use the value of the env 
variable CONSUL_HOST to compose the url and perform the query. What I 
understand is that the CONSUL_HOST is actually a hostname, which means we need 
a DNS to support the conversion from a hostname to the corresponding IP.

 BTW, there is a Python client library in ONAP that handles all of this for 
you. If you are not Python, you may still be able to look at the code and copy 
it into the language of choice: 
https://gerrit.onap.org/r/gitweb?p=dcaegen2/utils.git;a=tree;f=python-cbs-docker-client;h=5e362826689c84d46bec0dde63bfaf7b39f11bbc;hb=66613f4112b0e68f30430944b7d94e6ca14b1f62

OK here are the details.

Our DCAE deployment utilizes Designate. When our platform is spun, Designate 
(open stack DNS aaS) gets loaded with the resolution for CONSUL_HOST. So going 
to CONSUL_HOST:8500 gets you to Consul, as long as the DCAE as spun properly.

Then you need to do a standard service query to consul for the string 
“config_binding_service”. The string used to be dynamic, hence the ENV 
variable, but now CONFIG_BINDING  is just hardcoded to “config_binding_service” 
and the CBS always gets registered as that. Again see that python code.

The reason the CBS does not have a DNS name like Consul is because CBS is just 
a Docker container but Consul is a dedicated VM cluster.

In this case, do we have to set up a DNS inside each of the Holmes dockers in 
order that the coversion could be working when we make calls to the Consul?

I don’t really know what this means. If DCAE is spun properly into a proper 
Openstack, Designate handles the DNS.

Is the service information returned by the CBS (or Consul) in the form of ip 
addresses or hostnames?


Consul returns IP addresses. Using the CBS will resolve you dependencies to 
IP:Port.

[lji]  You do not need to do that.  The DNS mapping is configured via cloud's 
DNS service.  I am cc-ing Tommy for this question.  Since he developed CBS, his 
answer would be the most accurate.


Could you please kindly answer them for me?


Thanks.


Guangrong

___
onap-discuss mailing list
onap-discuss@lists.onap.org
https://lists.onap.org/mailman/listinfo/onap-discuss


Re: [onap-discuss] [dcae][dcaegen2] Three Questions about DCAE 

2017-09-16 Thread JI, LUSHENG (LUSHENG)
Guangrong,

Please see inline for details.

Lusheng

 Original message 
From: fu.guangr...@zte.com.cn
Date: 9/16/17 3:59 AM (GMT-05:00)
To: "JI, LUSHENG (LUSHENG)" 
Cc: onap-discuss@lists.onap.org, peng.congc...@zte.com.cn, 
tian.shi...@zte.com.cn
Subject: [dcae][dcaegen2] Three Questions about DCAE


Hi Lusheng,


I've been trying to implement the basic integration of Holmes and DCAE, which 
is using the CBS to get the configuration information of other components. As 
the work went on, some questions arose:


1. There are two types of DMaaP topics: secure and unsecure. How to use the 
authentication information provided by DCAE while calling the DMaaP APIs? I do 
not see any APIs in terms of authentication in the DMaaP docs.

[lji]  DMaaP Message Routet actually supports 3 kinds of 
authentication/security mechasim: anonymous, API key, and AAF.  DCAE plans to 
use unauthenticated for R1.  I donot know if any component plans to use AAF.  
Using AAF requires additional provisioning steps and requires basic auth 
header.  The DMaaP project should have provided documentation for API.

[cid:0047000102d7c6a436d66e031]

2. When pulling data from DMaaP, the consumer group and the consumer ID are 
required (see below). Neither of them are embodied in the response message from 
the CBS above. How and where could we get those parameters?

[cid:0047000102d7c6a436d66e032]

[lji] These two parameters are under your control.   They together identify a 
subscriber to the Message Router.  DMaaP Message Router uses such info to 
decide when to advance message offset.  The MR guarantees message delivery to 
each group.  You may have multiple subscribers under the same group for the 
same topic as a load balancing measure, --each of them receives a subset of 
messages.  Different subscribers to the same topic, if each wishes to get all 
the messages, should use different group IDs.


3. If we want to get the CBS address, we have to use the value of the env 
variable CONSUL_HOST to compose the url and perform the query. What I 
understand is that the CONSUL_HOST is actually a hostname, which means we need 
a DNS to support the conversion from a hostname to the corresponding IP. In 
this case, do we have to set up a DNS inside each of the Holmes dockers in 
order that the coversion could be working when we make calls to the Consul? Is 
the service information returned by the CBS (or Consul) in the form of ip 
addresses or hostnames?

[cid:0047000102d7c6a436d66e033]

[lji]  You do not need to do that.  The DNS mapping is configured via cloud's 
DNS service.  I am cc-ing Tommy for this question.  Since he developed CBS, his 
answer would be the most accurate.


Could you please kindly answer them for me?


Thanks.


Guangrong
___
onap-discuss mailing list
onap-discuss@lists.onap.org
https://lists.onap.org/mailman/listinfo/onap-discuss