You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by dm...@apache.org on 2016/06/01 17:33:21 UTC

[1/2] ambari git commit: AMBARI-16272. Ambari Upgrade shouldn't automatically add stack configs. Fix script for setting default upgrade policy (dlysnichenko)

Repository: ambari
Updated Branches:
  refs/heads/branch-2.4 8e7103a86 -> 0875142da
  refs/heads/trunk 70aacc6db -> 4d660f8f9


AMBARI-16272. Ambari Upgrade shouldn't automatically add stack configs. Fix script for setting default upgrade policy (dlysnichenko)


Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/4d660f8f
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/4d660f8f
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/4d660f8f

Branch: refs/heads/trunk
Commit: 4d660f8f98ddc8f1ed969f3ff14d97492b26d8af
Parents: 70aacc6
Author: Lisnichenko Dmitro <dl...@hortonworks.com>
Authored: Wed Jun 1 20:32:18 2016 +0300
Committer: Lisnichenko Dmitro <dl...@hortonworks.com>
Committed: Wed Jun 1 20:32:18 2016 +0300

----------------------------------------------------------------------
 .../configurations-set-default-update-policy.sh | 31 +++++++++++++++++---
 1 file changed, 27 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/4d660f8f/ambari-server/src/main/resources/scripts/configurations-set-default-update-policy.sh
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/scripts/configurations-set-default-update-policy.sh b/ambari-server/src/main/resources/scripts/configurations-set-default-update-policy.sh
index b1111c0..930f778 100644
--- a/ambari-server/src/main/resources/scripts/configurations-set-default-update-policy.sh
+++ b/ambari-server/src/main/resources/scripts/configurations-set-default-update-policy.sh
@@ -1,15 +1,38 @@
 #!/usr/bin/env bash
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+
 
 for i in `find ../../../ -regex '.*/configuration.*/.*.xml'` ;
 do
   echo $i;
+
+  xmlstarlet ed --inplace -d "//on-ambari-upgrade" $i
+  xmlstarlet ed --inplace -d "//on-stack-upgrade" $i
+
   `xmlstarlet ed --inplace --subnode "/configuration/property" -t 'elem' -n "on-ambari-upgrade" $i`;
-  `xmlstarlet ed --inplace --subnode "/configuration/property/on-ambari-upgrade" -t 'attr' -n "add" -v "true" $i`;
-  `xmlstarlet ed --inplace --subnode "/configuration/property/on-ambari-upgrade" -t 'attr' -n "change" -v "false" $i`;
-  `xmlstarlet ed --inplace --subnode "/configuration/property/on-ambari-upgrade" -t 'attr' -n "delete" -v "false" $i`;
+  `xmlstarlet ed --inplace --subnode "/configuration/property/on-ambari-upgrade" -t 'attr' -n "add" -v "false" $i`;
+  `xmlstarlet ed --inplace --subnode "/configuration/property/on-ambari-upgrade" -t 'attr' -n "change" -v "true" $i`;
+  `xmlstarlet ed --inplace --subnode "/configuration/property/on-ambari-upgrade" -t 'attr' -n "delete" -v "true" $i`;
 
   `xmlstarlet ed --inplace --subnode "/configuration/property" -t 'elem' -n "on-stack-upgrade" $i`;
   `xmlstarlet ed --inplace --subnode "/configuration/property/on-stack-upgrade" -t 'attr' -n "add" -v "true" $i`;
-  `xmlstarlet ed --inplace --subnode "/configuration/property/on-stack-upgrade" -t 'attr' -n "change" -v "false" $i`;
+  `xmlstarlet ed --inplace --subnode "/configuration/property/on-stack-upgrade" -t 'attr' -n "change" -v "true" $i`;
   `xmlstarlet ed --inplace --subnode "/configuration/property/on-stack-upgrade" -t 'attr' -n "delete" -v "false" $i`;
 done


[2/2] ambari git commit: AMBARI-16272. Ambari Upgrade shouldn't automatically add stack configs. Fix script for setting default upgrade policy (dlysnichenko)

Posted by dm...@apache.org.
AMBARI-16272. Ambari Upgrade shouldn't automatically add stack configs. Fix script for setting default upgrade policy (dlysnichenko)


Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/0875142d
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/0875142d
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/0875142d

Branch: refs/heads/branch-2.4
Commit: 0875142da0b27f6a6e4b3159285af769b699ad3e
Parents: 8e7103a
Author: Lisnichenko Dmitro <dl...@hortonworks.com>
Authored: Wed Jun 1 20:32:18 2016 +0300
Committer: Lisnichenko Dmitro <dl...@hortonworks.com>
Committed: Wed Jun 1 20:33:05 2016 +0300

----------------------------------------------------------------------
 .../configurations-set-default-update-policy.sh  | 19 +++++++++++++++++++
 1 file changed, 19 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/0875142d/ambari-server/src/main/resources/scripts/configurations-set-default-update-policy.sh
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/scripts/configurations-set-default-update-policy.sh b/ambari-server/src/main/resources/scripts/configurations-set-default-update-policy.sh
index 6565299..930f778 100644
--- a/ambari-server/src/main/resources/scripts/configurations-set-default-update-policy.sh
+++ b/ambari-server/src/main/resources/scripts/configurations-set-default-update-policy.sh
@@ -1,4 +1,23 @@
 #!/usr/bin/env bash
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+
 
 for i in `find ../../../ -regex '.*/configuration.*/.*.xml'` ;
 do