Sha256: fa2173c795cba7793794f62038a2901001936ea568ac1914c404bf48f9a733cf

Contents?: true

Size: 437 Bytes

Versions: 1

Compression:

Stored size: 437 Bytes

Contents

module Mandy
  module DSL
    
    def self.included(klass)
      Mandy::Job.default = Mandy::Job.new('Untitled Job')
    end
    
    def set(key, value)
      Mandy::Job.default.settings[key.to_s] = value
    end
    
    def job_name(name)
      set "mapred.job.name", name.to_s
    end
    
    def map(&blk)
      Mandy::Job.default.map(&blk)
    end
    
    def reduce(&blk)
      Mandy::Job.default.reduce(&blk)
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
trafficbroker-mandy-0.1.1 lib/dsl.rb