-
Notifications
You must be signed in to change notification settings - Fork 844
Tuning #430
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
Closed
Tuning #430
Changes from all commits
Commits
Show all changes
22 commits
Select commit
Hold shift + click to select a range
e44bc93
unified architecture changes
pralabhkumar 5a1f63b
Ipso configuration changes for Unified Architecture
pralabhkumar 44f5d8c
Added Documentation ; Added is_suggested_param_set ; Added logic for …
pralabhkumar 10d5c15
Changed to get tuning type from DB instead of Azkaban : Changed to wo…
pralabhkumar 27c0411
New Spark HBT algorithm for specific suggestion
mkumar1984 a877484
Renamed TuningType to ParamGenerator , Generalized ParameterGenerateM…
pralabhkumar 909b24c
Added Unit Test cases , Changes specific to IPSO
pralabhkumar e2f0097
Unit test cases for Fitness Manager for HBT
pralabhkumar 030b036
Unit test cases for Paramgenerator HBT . Documentation added for entity
pralabhkumar d93a2c9
Changed logging to debug from info , optimization and indenetation ch…
pralabhkumar 21ea0ef
Changed logic to have algorithm selection based on version
pralabhkumar c29f969
Adding Spark Job Specific Configuration Input Output
mkumar1984 d3cc99f
Changing spark input configuration for version 1 api
mkumar1984 1905c2a
Code changes to handle multiple jobs in Spark
pralabhkumar c519f89
Changing log status to debug
pralabhkumar b8f2ccc
Updated HBT parameter generation for Spark
mkumar1984 f126f9a
Documentation/Javadoc added
pralabhkumar 4ae3c0a
Handling scenario where no param generator implementation for algorit…
pralabhkumar 62c8734
Removing spark heuristics specific changes to separate commit
mkumar1984 2eaee21
Removing spark heuristics specific changes to separate commit
mkumar1984 e523afe
Changed Boolean to boolean
pralabhkumar 2eb5e7e
Made fitness calculation, tuning type specific
pralabhkumar File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
84 changes: 84 additions & 0 deletions
84
app/com/linkedin/drelephant/mapreduce/heuristics/ConfigurationHeuristic.java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,84 @@ | ||
| /* | ||
| * Copyright 2016 LinkedIn Corp. | ||
| * | ||
| * Licensed 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. | ||
| */ | ||
|
|
||
| package com.linkedin.drelephant.mapreduce.heuristics; | ||
|
|
||
| import com.linkedin.drelephant.analysis.Heuristic; | ||
| import com.linkedin.drelephant.analysis.HeuristicResult; | ||
| import com.linkedin.drelephant.analysis.Severity; | ||
| import com.linkedin.drelephant.configurations.heuristic.HeuristicConfigurationData; | ||
| import com.linkedin.drelephant.mapreduce.data.MapReduceApplicationData; | ||
| import static com.linkedin.drelephant.mapreduce.heuristics.CommonConstantsHeuristic.ParameterKeys.*; | ||
| import org.apache.log4j.Logger; | ||
|
|
||
| /** | ||
| * This heuristics is to collect memory data / properties / counter values about jobs | ||
| * previous execution | ||
| */ | ||
| public class ConfigurationHeuristic implements Heuristic<MapReduceApplicationData> { | ||
| private static final Logger logger = Logger.getLogger(ConfigurationHeuristic.class); | ||
|
|
||
| private HeuristicConfigurationData _heuristicConfData; | ||
|
|
||
| public ConfigurationHeuristic(HeuristicConfigurationData heuristicConfData) { | ||
| this._heuristicConfData = heuristicConfData; | ||
| } | ||
|
|
||
| @Override | ||
| public HeuristicConfigurationData getHeuristicConfData() { | ||
| return _heuristicConfData; | ||
| } | ||
|
|
||
| @Override | ||
| public HeuristicResult apply(MapReduceApplicationData data) { | ||
| if (!data.getSucceeded()) { | ||
| return null; | ||
| } | ||
| String mapperMemory = data.getConf().getProperty(MAPPER_MEMORY_HADOOP_CONF.getValue()); | ||
| String mapperHeap = data.getConf().getProperty(MAPPER_HEAP_HADOOP_CONF.getValue()); | ||
| if (mapperHeap == null) { | ||
| mapperHeap = data.getConf().getProperty(CHILD_HEAP_SIZE_HADOOP_CONF.getValue()); | ||
| } | ||
| String sortBuffer = data.getConf().getProperty(SORT_BUFFER_HADOOP_CONF.getValue()); | ||
| String sortFactor = data.getConf().getProperty(SORT_FACTOR_HADOOP_CONF.getValue()); | ||
| String sortSplill = data.getConf().getProperty(SORT_SPILL_HADOOP_CONF.getValue()); | ||
| String reducerMemory = data.getConf().getProperty(REDUCER_MEMORY_HADOOP_CONF.getValue()); | ||
| String reducerHeap = data.getConf().getProperty(REDUCER_HEAP_HADOOP_CONF.getValue()); | ||
| if (reducerHeap == null) { | ||
| reducerHeap = data.getConf().getProperty(CHILD_HEAP_SIZE_HADOOP_CONF.getValue()); | ||
| } | ||
| String splitSize = data.getConf().getProperty(SPLIT_SIZE_HADOOP_CONF.getValue()); | ||
| String pigSplitSize = data.getConf().getProperty(PIG_SPLIT_SIZE_HADOOP_CONF.getValue()); | ||
| HeuristicResult result = | ||
| new HeuristicResult(_heuristicConfData.getClassName(), _heuristicConfData.getHeuristicName(), Severity.LOW, 0); | ||
|
|
||
| result.addResultDetail(MAPPER_MEMORY_HEURISTICS_CONF.getValue(), mapperMemory); | ||
| result.addResultDetail(MAPPER_HEAP_HEURISTICS_CONF.getValue(), mapperHeap.replaceAll("\\s+", "\n")); | ||
| result.addResultDetail(REDUCER_MEMORY_HEURISTICS_CONF.getValue(), reducerMemory); | ||
| result.addResultDetail(REDUCER_HEAP_HEURISTICS_CONF.getValue(), reducerHeap.replaceAll("\\s+", "\n")); | ||
| result.addResultDetail(SORT_BUFFER_HEURISTICS_CONF.getValue(), sortBuffer); | ||
| result.addResultDetail(SORT_FACTOR_HEURISTICS_CONF.getValue(), sortFactor); | ||
| result.addResultDetail(SORT_SPILL_HEURISTICS_CONF.getValue(), sortSplill); | ||
| if (splitSize != null) { | ||
| result.addResultDetail(SPLIT_SIZE_HEURISTICS_CONF.getValue(), splitSize); | ||
| } | ||
| if (pigSplitSize != null) { | ||
| result.addResultDetail(PIG_MAX_SPLIT_SIZE_HEURISTICS_CONF.getValue(), pigSplitSize); | ||
| } | ||
|
|
||
| return result; | ||
| } | ||
| } | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.