ambari-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dmytro Sen (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (AMBARI-17146) Implement config values trimming for deployment via blueprint
Date Thu, 09 Jun 2016 15:22:20 GMT

     [ https://issues.apache.org/jira/browse/AMBARI-17146?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Dmytro Sen updated AMBARI-17146:
--------------------------------
    Status: Patch Available  (was: Open)

> Implement config values trimming for deployment via blueprint
> -------------------------------------------------------------
>
>                 Key: AMBARI-17146
>                 URL: https://issues.apache.org/jira/browse/AMBARI-17146
>             Project: Ambari
>          Issue Type: Task
>    Affects Versions: 2.4.0
>            Reporter: Dmytro Sen
>            Assignee: Dmytro Sen
>            Priority: Critical
>             Fix For: 2.4.0
>
>         Attachments: AMBARI-17146_1.patch
>
>
> Implement config values trimming for deployment via blueprint as we do in UI
> {code}
>   trimProperty: function (property) {
>     var displayType = Em.get(property, 'displayType');
>     var value = Em.get(property, 'value');
>     var name = Em.get(property, 'name');
>     var rez;
>     switch (displayType) {
>       case 'directories':
>       case 'directory':
>         rez = value.replace(/,/g, ' ').trim().split(/\s+/g).join(',');
>         break;
>       case 'host':
>         rez = value.trim();
>         break;
>       case 'password':
>         break;
>       default:
>         if (name == 'javax.jdo.option.ConnectionURL' || name == 'oozie.service.JPAService.jdbc.url')
{
>           rez = value.trim();
>         }
>         rez = (typeof value == 'string') ? value.replace(/(\s+$)/g, '') : value;
>     }
>     return ((rez == '') || (rez == undefined)) ? value : rez;
>   },
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message