> On Sept. 1, 2017, 3:40 a.m., Attila Magyar wrote:
> > ambari-server/src/main/java/org/apache/ambari/server/serveraction/upgrades/PreconfigureKerberosAction.java
> > Lines 173 (patched)
> > <https://reviews.apache.org/r/62020/diff/1/?file=1808720#file1808720line173>
> >
> > unnecessary null check: cluster.getServices() never returns null
I never like making that assumption ("never returns null"). Today the
implementation happens to not return null, tommorow may be a different story.
> On Sept. 1, 2017, 3:40 a.m., Attila Magyar wrote:
> > ambari-server/src/main/java/org/apache/ambari/server/serveraction/upgrades/PreconfigureKerberosAction.java
> > Lines 370 (patched)
> > <https://reviews.apache.org/r/62020/diff/1/?file=1808720#file1808720line370>
> >
> > isn't this supposed to be !MapUtils.isEmpty ?
Nice catch.
- Robert
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/62020/#review184341
-----------------------------------------------------------
On Aug. 31, 2017, 1:55 p.m., Robert Levas wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/62020/
> -----------------------------------------------------------
>
> (Updated Aug. 31, 2017, 1:55 p.m.)
>
>
> Review request for Ambari, Attila Magyar, Balázs Bence Sári, Eugene
> Chekanskiy, Jonathan Hurley, Laszlo Puskas, Nate Cole, and Sebastian Toader.
>
>
> Bugs: AMBARI-21809
> https://issues.apache.org/jira/browse/AMBARI-21809
>
>
> Repository: ambari
>
>
> Description
> -------
>
> Pre-configure (certain) services during a stack upgrade to HDP 2.6, when
> Kerberos is enabled, to reduce number of core service restarts when services
> are added.
>
> Services to pre-configure include:
> * Knox
> * Beacon
>
> While upgrading the stack (EU or RU), processing the relevant Kerberos
> descriptor to find services marked to be _pre-configured_. When a tagged
> service is encountered, process it if it is not installed. Apply only
> configuration changes for existing configuration types. This will set at
> least the core-site changes related to proxyuser and auth-to-local rules
> properties. By doing this, if a tagged service is later installed, the
> settings will already be in place in the existing service configs and thus
> the existing services will not need to be restarted.
>
> Caveats:
> * Default values for the uninstalled, tagged, services will be assumed
> * The stack advisor will be used to suggest locations of components - used to
> build the clusterHostInfo structure that may be used to derive property
> values.
>
> Note: This processing is to occur when upgrading the stack from HDP 2.5 to
> HDP 2.6.
>
>
> Diffs
> -----
>
>
> ambari-server/src/main/java/org/apache/ambari/server/controller/DeleteIdentityHandler.java
> 978b329d35
>
> ambari-server/src/main/java/org/apache/ambari/server/controller/KerberosHelper.java
> 9bdb377cf7
>
> ambari-server/src/main/java/org/apache/ambari/server/controller/KerberosHelperImpl.java
> d86433f880
>
> ambari-server/src/main/java/org/apache/ambari/server/serveraction/kerberos/PrepareDisableKerberosServerAction.java
> 178d129dc8
>
> ambari-server/src/main/java/org/apache/ambari/server/serveraction/kerberos/PrepareEnableKerberosServerAction.java
> da83a74aca
>
> ambari-server/src/main/java/org/apache/ambari/server/serveraction/kerberos/PrepareKerberosIdentitiesServerAction.java
> 581067f939
>
> ambari-server/src/main/java/org/apache/ambari/server/serveraction/upgrades/PreconfigureKerberosAction.java
> PRE-CREATION
>
> ambari-server/src/main/resources/stacks/HDP/2.5/upgrades/nonrolling-upgrade-2.6.xml
> 492c308275
> ambari-server/src/main/resources/stacks/HDP/2.5/upgrades/upgrade-2.6.xml
> 995a1d3fd9
>
> ambari-server/src/test/java/org/apache/ambari/server/serveraction/upgrades/PreconfigureKerberosActionTest.java
> PRE-CREATION
> ambari-server/src/test/resources/PreconfigureActionTest_cluster_config.json
> PRE-CREATION
>
> ambari-server/src/test/resources/PreconfigureActionTest_kerberos_descriptor_stack.json
> PRE-CREATION
>
> ambari-server/src/test/resources/PreconfigureActionTest_kerberos_descriptor_stack_preconfigure.json
> PRE-CREATION
>
>
> Diff: https://reviews.apache.org/r/62020/diff/1/
>
>
> Testing
> -------
>
> Manually tested
>
> # Local test results:
> ```
> Tests run: 4861, Failures: 0, Errors: 0, Skipped: 37
> ```
>
> # Jenkins test results: PENDING
>
>
> Thanks,
>
> Robert Levas
>
>