[ 
https://issues.apache.org/jira/browse/AMBARI-20666?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15967725#comment-15967725
 ] 

Tim Thorpe commented on AMBARI-20666:
-------------------------------------

Manual testing including running the code in a script and running mvn clean 
test on ambari-server.

import re

user_and_groups = ",users, group1,group2,"
parts = re.split('\s', user_and_groups)
if len(parts) == 1:
  parts.append("")

users_list = parts[0].strip(",").split(",") if parts[0] else []
groups_list = parts[1].strip(",").split(",") if parts[1] else []

print users_list
print groups_list

> beginning or ending commas in dfs.cluster.administrators cause trouble for 
> starting services
> --------------------------------------------------------------------------------------------
>
>                 Key: AMBARI-20666
>                 URL: https://issues.apache.org/jira/browse/AMBARI-20666
>             Project: Ambari
>          Issue Type: Bug
>          Components: ambari-server
>    Affects Versions: trunk
>            Reporter: Tim Thorpe
>            Assignee: Tim Thorpe
>            Priority: Minor
>         Attachments: AMBARI-20666.patch
>
>
> In order to avoid issues with starting and stopping services, it would be 
> useful to trim any commas from the beginning or ending of the user and group 
> lists



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to