----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/61744/#review183453 -----------------------------------------------------------
ambari-server/src/main/java/org/apache/ambari/server/controller/KerberosHelperImpl.java Lines 296 (patched) <https://reviews.apache.org/r/61744/#comment259459> If the returned host list is not meant to be modified later than return an immutable Set. (you can use https://google.github.io/guava/releases/19.0/api/docs/com/google/common/collect/ImmutableSet.html) ambari-server/src/main/java/org/apache/ambari/server/controller/KerberosHelperImpl.java Lines 314-327 (patched) <https://reviews.apache.org/r/61744/#comment259463> Since trunk is already java8 worth checking if this method can be implemented in a simpler way using lambdas. ambari-server/src/main/java/org/apache/ambari/server/controller/KerberosHelperImpl.java Lines 323 (patched) <https://reviews.apache.org/r/61744/#comment259460> Why not adding ```Set.emptySet()``` instead of ```null```? That would save using null checks laster in the code. ambari-server/src/main/java/org/apache/ambari/server/controller/KerberosHelperImpl.java Lines 327 (patched) <https://reviews.apache.org/r/61744/#comment259461> If the retruned map is not meant to be modified by caller than return an immutable Map of immutable Set. - Sebastian Toader On Aug. 21, 2017, 6:31 p.m., Eugene Chekanskiy wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/61744/ > ----------------------------------------------------------- > > (Updated Aug. 21, 2017, 6:31 p.m.) > > > Review request for Ambari, Robert Levas and Sebastian Toader. > > > Bugs: AMBARI-21757 > https://issues.apache.org/jira/browse/AMBARI-21757 > > > Repository: ambari > > > Description > ------- > > regenerateKeytab request now can accept host list and components list to > regenerate keytabs for. > > Example: > 'http://lc6401.ambari.apache.org:8080/api/v1/clusters/cl1?regenerate_keytabs=all&Kerberos/hosts=lc6401.ambari.apache.org&Kerberos/components=HDFS:NAMENODE;DATANODE,YARN:RESOURCEMANAGER' > > > Diffs > ----- > > > ambari-server/src/main/java/org/apache/ambari/server/api/resources/ClusterResourceDefinition.java > f689841 > > ambari-server/src/main/java/org/apache/ambari/server/controller/KerberosHelper.java > 3819863 > > ambari-server/src/main/java/org/apache/ambari/server/controller/KerberosHelperImpl.java > 6c6c439 > > ambari-server/src/test/java/org/apache/ambari/server/controller/KerberosHelperTest.java > b220999 > > > Diff: https://reviews.apache.org/r/61744/diff/2/ > > > Testing > ------- > > mvn clean test. manual tests on deployed cluster. > > > Thanks, > > Eugene Chekanskiy > >
