def test_possible_configs(self):
     res = w_f.get_possible_job_config("Jar")
     sample_config_property = {
         'name': 'mapred.map.tasks',
         'value': '2',
         'description': 'The default number of map tasks per job.'
                        'Ignored when mapred.job.tracker is "local".  '
     }
     self.assertIn(sample_config_property, res['job_config']["configs"])
     res = w_f.get_possible_job_config("Hive")
     sample_config_property = {
         "description": "The serde used by FetchTask to serialize the "
                        "fetch output.",
         "name": "hive.fetch.output.serde",
         "value": "org.apache.hadoop.hive.serde2.DelimitedJSONSerDe"
     }
     self.assertIn(sample_config_property, res["job_config"]['configs'])
     res = w_f.get_possible_job_config("impossible_config")
     self.assertIsNone(res)
 def test_possible_configs(self):
     res = w_f.get_possible_job_config("Jar")
     sample_config_property = {
         'name':
         'mapred.map.tasks',
         'value':
         '2',
         'description':
         'The default number of map tasks per job.'
         'Ignored when mapred.job.tracker is "local".  '
     }
     self.assertIn(sample_config_property, res['job_config']["configs"])
     res = w_f.get_possible_job_config("Hive")
     sample_config_property = {
         "description": "The serde used by FetchTask to serialize the "
         "fetch output.",
         "name": "hive.fetch.output.serde",
         "value": "org.apache.hadoop.hive.serde2.DelimitedJSONSerDe"
     }
     self.assertIn(sample_config_property, res["job_config"]['configs'])
     res = w_f.get_possible_job_config("impossible_config")
     self.assertIsNone(res)
예제 #3
0
파일: api.py 프로젝트: hguemar/sahara
def get_job_config_hints(job_type):
    return w_f.get_possible_job_config(job_type)
예제 #4
0
파일: api.py 프로젝트: joelmathew/savanna
def get_job_config_hints(job_type):
    return w_f.get_possible_job_config(job_type)