Return-Path: X-Original-To: apmail-ambari-dev-archive@www.apache.org Delivered-To: apmail-ambari-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id AD78F18CE6 for ; Thu, 29 Oct 2015 22:24:46 +0000 (UTC) Received: (qmail 22187 invoked by uid 500); 29 Oct 2015 22:24:46 -0000 Delivered-To: apmail-ambari-dev-archive@ambari.apache.org Received: (qmail 22150 invoked by uid 500); 29 Oct 2015 22:24:46 -0000 Mailing-List: contact dev-help@ambari.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@ambari.apache.org Delivered-To: mailing list dev@ambari.apache.org Received: (qmail 22135 invoked by uid 99); 29 Oct 2015 22:24:46 -0000 Received: from reviews-vm.apache.org (HELO reviews.apache.org) (140.211.11.40) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 29 Oct 2015 22:24:46 +0000 Received: from reviews.apache.org (localhost [127.0.0.1]) by reviews.apache.org (Postfix) with ESMTP id 50EAD2A81EB; Thu, 29 Oct 2015 22:24:45 +0000 (UTC) Content-Type: multipart/alternative; boundary="===============6579815013606523412==" MIME-Version: 1.0 Subject: Re: Review Request 39481: Basic StackAdvisor support for blueprint (configurations) From: "Robert Levas" To: "Sumit Mohanty" , "Robert Nettleton" Cc: "Robert Levas" , "Oliver Szabo" , "Ambari" Date: Thu, 29 Oct 2015 22:24:45 -0000 Message-ID: <20151029222445.22461.55002@reviews.apache.org> X-ReviewBoard-URL: https://reviews.apache.org/ Auto-Submitted: auto-generated Sender: "Robert Levas" X-ReviewGroup: Ambari X-Auto-Response-Suppress: DR, RN, OOF, AutoReply X-ReviewRequest-URL: https://reviews.apache.org/r/39481/ X-Sender: "Robert Levas" References: <20151029171054.22461.27059@reviews.apache.org> In-Reply-To: <20151029171054.22461.27059@reviews.apache.org> Reply-To: "Robert Levas" X-ReviewRequest-Repository: ambari --===============6579815013606523412== MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/39481/#review104486 ----------------------------------------------------------- Ship it! Ship It! - Robert Levas On Oct. 29, 2015, 1:10 p.m., Oliver Szabo wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/39481/ > ----------------------------------------------------------- > > (Updated Oct. 29, 2015, 1:10 p.m.) > > > Review request for Ambari, Robert Nettleton and Sumit Mohanty. > > > Bugs: AMBARI-13487 > https://issues.apache.org/jira/browse/AMBARI-13487 > > > Repository: ambari > > > Description > ------- > > During update configuration for cluster creation, configurations are upgraded based on response of the StackAdvisor. > The advised configurations will be added to cluster topology, and used during BlueprintConfigurationProcessor#doUpdateForClusterCreate(). The advised configurations filtered out based on ConfigRecommendationStrategy, which can be set in the Cluster Creation Template, e.g.: > { > "blueprint" : "multi-node-conf-yarn", > "default_password" : "secret", > "config_recommendation_strategy" : "ONLY_STACK_DEFAULTS_APPLY", > "host_groups": [ > { > "hosts": [ > { "fqdn": "c6402.ambari.apache.org" } > ], > "name": "master", > "configurations" : [ ] > }, > { > "hosts": [ > { "fqdn": "c6403.ambari.apache.org" } > ], > "name": "slave_1", > "configurations" : [ ] > } > ], > "Clusters" : {"cluster_name":"cluster_name"} > } > Also tested with host count and predicate: > ... > "host_count" : .., > "host_predicate" : "...", > ... > I added the configuration modifications BEFORE the basic updates happen in BlueprintConfigurationProcessor. > As I see stackAdvisor not supports host group scoped configurations, so as my changes. I made a new AdvisedConfiguration which has a Map field for properties, this field can be a Configuration object in the future (if property attributes will be supported..because they are not supported too) > > question: is that the correct way to geather stack defaults in BlueprintConfigurationProcessor#doFilterStackDefaults() ? > > > Diffs > ----- > > ambari-server/src/main/java/org/apache/ambari/server/api/services/stackadvisor/StackAdvisorBlueprintProcessor.java PRE-CREATION > ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariServer.java 9044e37 > ambari-server/src/main/java/org/apache/ambari/server/controller/internal/BlueprintConfigurationProcessor.java d3d95bd > ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ClusterResourceProvider.java cd28aac > ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ProvisionClusterRequest.java 9716abe > ambari-server/src/main/java/org/apache/ambari/server/topology/AdvisedConfiguration.java PRE-CREATION > ambari-server/src/main/java/org/apache/ambari/server/topology/ClusterConfigurationRequest.java 1ebde17 > ambari-server/src/main/java/org/apache/ambari/server/topology/ClusterTopology.java 284a913 > ambari-server/src/main/java/org/apache/ambari/server/topology/ClusterTopologyImpl.java 5b716ae > ambari-server/src/main/java/org/apache/ambari/server/topology/ConfigRecommendationStrategy.java PRE-CREATION > ambari-server/src/main/java/org/apache/ambari/server/topology/TopologyManager.java 26d8c3e > ambari-server/src/test/java/org/apache/ambari/server/api/services/stackadvisor/StackAdvisorBlueprintProcessorTest.java PRE-CREATION > ambari-server/src/test/java/org/apache/ambari/server/controller/internal/BlueprintConfigurationProcessorTest.java 34b72b6 > ambari-server/src/test/java/org/apache/ambari/server/topology/TopologyManagerTest.java bd4f13d > > Diff: https://reviews.apache.org/r/39481/diff/ > > > Testing > ------- > > Unit tests passed: > [INFO] ------------------------------------------------------------------------ > [INFO] BUILD SUCCESS > [INFO] ------------------------------------------------------------------------ > [INFO] Total time: 01:30 h > [INFO] Finished at: 2015-10-20T16:23:54+00:00 > [INFO] Final Memory: 48M/687M > [INFO] ----------------------------------------------------------------------- > > Functional tests: Manually > (added "config_recommendation_strategy" field to the cluster creation template: tried 4 variations: field is missing, and set the field to NEVER_APPLY, ALWAYS_APPLY and ONLY_STACK_DEFAULTS_APPLY) > > > Thanks, > > Oliver Szabo > > --===============6579815013606523412==--