> On July 5, 2017, 6:12 p.m., Sriharsha Chintalapani wrote:
> > ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/kafka.py
> > Lines 117 (patched)
> > <https://reviews.apache.org/r/60249/diff/5/?file=1769273#file1769273line117>
> >
> >     how are we co-relating the host and the all_racks array here?
> >     Are we expecting the hosts to be sorted and all_racks to match with 
> > all_racks index to pick the config.
> >     This might break if the user later adds another broker.

Yes, the expectation is that array indices are the same. This approach is what 
HDFS stack uses as well: 
https://github.com/apache/ambari/blob/79cca1c7184f1661236971dac70d85a83fab6c11/ambari-server/src/main/resources/stacks/HDP/2.0.6/hooks/before-START/templates/topology_mappings.data.j2


> On July 5, 2017, 6:12 p.m., Sriharsha Chintalapani wrote:
> > ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/kafka.py
> > Lines 121 (patched)
> > <https://reviews.apache.org/r/60249/diff/5/?file=1769273#file1769273line121>
> >
> >     This will add the broker.rack to all the versions. Can we make sure we 
> > only add this 0.10.x onwards

Yes, we are trying to see if the 0.10.x stack from Ambari trunk can be 
backported to branch-2.5, this will limit the scope of the rack configuration 
to only 0.10.x onwards.


- Ambud


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60249/#review179667
-----------------------------------------------------------


On July 5, 2017, 6:14 p.m., Ambud Sharma wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60249/
> -----------------------------------------------------------
> 
> (Updated July 5, 2017, 6:14 p.m.)
> 
> 
> Review request for Ambari, Alejandro Fernandez and Sriharsha Chintalapani.
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> Ambari rack awareness for Kafka. 
> https://issues.apache.org/jira/browse/AMBARI-21234
> 
> As an operations person it would be nice to manage Kafka rack awareness via 
> Ambari. Ambari allows node rack information to be configured and this 
> information can then be pulled in the Kafka stack and populated in the 
> server.properties file for Kafka.
> Design:
> This stack change uses the /clusterHostInfo/all_hosts and 
> /clusterHostInfo/all_racks paths and materializes them to a variable. Then it 
> uses linear search to find this node in the list of all hosts and it's 
> corresponding rack id. This information is then stored in a variable called 
> rack and which is materialized during the configure method of the broker 
> scripts.
> This stack change relies on the node rack information stored in Ambari 
> therefore will enable both Ambari UI and Blueprints to be used for setting up 
> Kafka broker rack information.
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/resources/common-services/KAFKA/0.8.1/metainfo.xml 
> d322adc47b 
>   
> ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/kafka.py
>  1327090aa7 
>   
> ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/params.py
>  c36a10ff28 
> 
> 
> Diff: https://reviews.apache.org/r/60249/diff/5/
> 
> 
> Testing
> -------
> 
> Manually deployed Kafka cluster and verified the broker.rack property is 
> correctly populated.
> 
> 
> Thanks,
> 
> Ambud Sharma
> 
>

Reply via email to