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


Ship it!




Ship It!

- Nate Cole


On Sept. 13, 2017, 3:15 p.m., Jonathan Hurley wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/62291/
> -----------------------------------------------------------
> 
> (Updated Sept. 13, 2017, 3:15 p.m.)
> 
> 
> Review request for Ambari, Nate Cole and Robert Levas.
> 
> 
> Bugs: AMBARI-21951
>     https://issues.apache.org/jira/browse/AMBARI-21951
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> STR:
> 
> - Install a cluster with Spark and Spark2
> - Remove Spark2
> - Change a Spark configuration
> - Run the Spark Service check
> - Attempt to perform an upgrade
> 
> The upgrade pre-checks will stop you saying something like: 
> {code}
> 02 Aug 2017 10:17:23,701  INFO [ambari-client-thread-28] 
> ServiceCheckValidityCheck:149 - Service SPARK latest config change is 
> 08-02-2017 09:45:16, latest service check executed at 12-31-1969 03:59:59
> {code}
> 
> The start time suggests a value of -1 in my cluster. The problem is that I 
> aborted my SPARK2 service check and then removed the service. However, the 
> pre-check seems to be matching on the name an incorrectly detecting the old 
> SPARK2 check as the one for SPARK:
> 
> {code}
>       boolean serviceCheckWasExecuted = false;
>       for (HostRoleCommandEntity command : latestTimestamps.values()) {
>         if (null !=  command.getCommandDetail() && 
> command.getCommandDetail().contains(serviceName)) {
> {code}
> 
> Because {{contains()}} is finding {{SPARK}} in {{SPARK2_SERVICE_CHECK}}, it's 
> incorrectly picking up the wrong values...
> 
> 
> Diffs
> -----
> 
>   
> ambari-server/src/main/java/org/apache/ambari/server/checks/ServiceCheckValidityCheck.java
>  2a8e23fd56 
>   
> ambari-server/src/main/java/org/apache/ambari/server/orm/dao/HostRoleCommandDAO.java
>  14c8443fee 
>   
> ambari-server/src/main/java/org/apache/ambari/server/orm/entities/HostRoleCommandEntity.java
>  7ac60a9dd4 
>   
> ambari-server/src/test/java/org/apache/ambari/server/checks/ServiceCheckValidityCheckTest.java
>  1ba0d70b57 
> 
> 
> Diff: https://reviews.apache.org/r/62291/diff/1/
> 
> 
> Testing
> -------
> 
> mvn clean test
> 
> 
> Thanks,
> 
> Jonathan Hurley
> 
>

Reply via email to