ambari-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Denys Buzhor (JIRA)" <j...@apache.org>
Subject [jira] [Created] (AMBARI-4606) Selecting Storm during install breaks configs (with App.supports.appTimelineServer turned on)
Date Tue, 11 Feb 2014 16:27:22 GMT
Denys Buzhor created AMBARI-4606:
------------------------------------

             Summary: Selecting Storm during install breaks configs (with App.supports.appTimelineServer
turned on)
                 Key: AMBARI-4606
                 URL: https://issues.apache.org/jira/browse/AMBARI-4606
             Project: Ambari
          Issue Type: Task
          Components: client
    Affects Versions: 1.5.0
            Reporter: Denys Buzhor
            Assignee: Denys Buzhor
             Fix For: 1.5.0


During install I selected Storm service (had jobs and timeline server flags turned on). Coming
into the configurations page I hit an exception in {{app/utils/config.js}} file's {{#tweakDynamicDefaults()}}
function. Specifically at line 
{code}
if (typeof(config == "string") && config.defaultValue.indexOf("{firstHost}") >=
0) 
{code}
where {{config.defaultValue}} was type boolean instead of type 'string'.

There are 2 problems here:
1. AMBARI-4287 introduced a change where global configs with default value  of string 'true'
or 'false' are converted to booleans. 
{code}
 if (configData.displayType === 'checkbox') {
        configData.value = configData.defaultValue = configData.value === 'true'; // convert
{String} value to {Boolean}
      }
{code}
We should make sure that all usages of {{config.defaultValue}} account for this change in
behavior. Would be best to stay on 'string'.

2. Where the exception is thrown, the logic of the if() statement is incorrect and should
be changed to
{code}
if (typeof(config.defaultValue) == "string" && config.defaultValue.indexOf("{firstHost}")
>= 0) 
{code}



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

Mime
View raw message