diff --git a/lib/wukong/script/hadoop_command.rb b/lib/wukong/script/hadoop_command.rb index 919d0815..e810d117 100644 --- a/lib/wukong/script/hadoop_command.rb +++ b/lib/wukong/script/hadoop_command.rb @@ -54,13 +54,17 @@ def jobconf option # others # def execute_hadoop_workflow + + jar_path = File.join('contrib', 'streaming', 'hadoop-*streaming*.jar') + jar_path = File.join('mapred', jar_path) if options[:hadoop_home].include?("0.21.0") + # Input paths join by ',' input_paths = @input_paths.join(',') # # Use Settings[:hadoop_home] to set the path your config install. hadoop_commandline = [ - hadoop_runner, - "jar #{options[:hadoop_home]}/contrib/streaming/hadoop-*streaming*.jar", + hadoop_runner, + "jar #{File.join(options[:hadoop_home], jar_path)}", hadoop_jobconf_options, "-D mapred.job.name='#{job_name}'", hadoop_other_args,