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

Jonathan Hurley updated AMBARI-18403:
-------------------------------------
    Description: 
AMBARI-18366 introduced a pattern to match in when converting properties to 
YAML which looks for Maps of Maps. Example:

{noformat}
foo : 
  bar : 
    [baz]
  foobar :
    [biz]
{noformat}

However, this does not take into account non-word characters such as dashes. 
The regex should be revised to look for specific markers for the 
map-within-a-map, allowing for non-space characters as keys. The following 
should pass:

{noformat}
storm-cluster  :  
  hosts:
    [c6401.ambari.apache.org, c6402.ambari.apache.org, 
c6403-master.ambari.apache.org]
  groups:
    [hadoop, hadoop-secure]
{noformat}


  was:
AMBARI-18366 introduced a pattern to match in when converting properties to 
YAML which looks for Maps of Maps. Example:

{noformat}
foo : 
  bar : 
    [baz]
  foobar :
    [biz]
{noformat}

However, this does not take into account non-word characters such as dashes. 
The regex should be revised to look for specific markers for the 
map-within-a-map, allowing for non-space characters as keys.


> YAML Maps Can Include Dashes and Other Non-Word Characters
> ----------------------------------------------------------
>
>                 Key: AMBARI-18403
>                 URL: https://issues.apache.org/jira/browse/AMBARI-18403
>             Project: Ambari
>          Issue Type: Bug
>          Components: ambari-server
>    Affects Versions: 2.5.0
>            Reporter: Jonathan Hurley
>            Assignee: Jonathan Hurley
>            Priority: Critical
>             Fix For: 2.5.0
>
>
> AMBARI-18366 introduced a pattern to match in when converting properties to 
> YAML which looks for Maps of Maps. Example:
> {noformat}
> foo : 
>   bar : 
>     [baz]
>   foobar :
>     [biz]
> {noformat}
> However, this does not take into account non-word characters such as dashes. 
> The regex should be revised to look for specific markers for the 
> map-within-a-map, allowing for non-space characters as keys. The following 
> should pass:
> {noformat}
> storm-cluster  :  
>   hosts:
>     [c6401.ambari.apache.org, c6402.ambari.apache.org, 
> c6403-master.ambari.apache.org]
>   groups:
>     [hadoop, hadoop-secure]
> {noformat}



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

Reply via email to