Sha256: 4b0c2dce7bc76d4b3f882c71eb774bb953467b38c26f72861b208a1e79ba8c7f

Contents?: true

Size: 542 Bytes

Versions: 11

Compression:

Stored size: 542 Bytes

Contents

#!/usr/bin/env ruby
require 'optparse'
require 'ostruct'

exec('mandy-kill -h') unless ARGV.size >= 1


options = OpenStruct.new

OptionParser.new do |opts|
  opts.banner = "USAGE: mandy-kill job [options]"

  opts.on("-c", "--conf HADOOP_CONF", "Use this cluster xml config file.") do |config|
    options.config = config
  end
  
  opts.on_tail("-h", "--help", "Show this message") do
    puts opts
    exit
  end
end.parse!

job = ARGV[0]
config = options.config || 'cluster.xml'

`$HADOOP_HOME/bin/hadoop job -conf #{config} -kill #{job}`

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
mandy-0.5.9 bin/mandy-kill
mandy-0.5.8 bin/mandy-kill
mandy-0.5.7 bin/mandy-kill
mandy-0.5.6 bin/mandy-kill
mandy-0.5.5 bin/mandy-kill
mandy-0.5.3 bin/mandy-kill
mandy-0.5.2 bin/mandy-kill
mandy-0.5.1 bin/mandy-kill
mandy-0.5 bin/mandy-kill
mandy-0.4.996 bin/mandy-kill
mandy-0.4.995 bin/mandy-kill