Sha256: 2abc52daa2a4e46b016ea3cb916f89da8431e8a33c5aa27afb8ba9a64c15dc72

Contents?: true

Size: 388 Bytes

Versions: 1

Compression:

Stored size: 388 Bytes

Contents

#!/usr/bin/env ruby -E ASCII-8BIT
require 'rubygems'
require 'wukong/script'
$: << File.dirname(__FILE__)
require 'logline'

class ApacheLogParser < Wukong::Streamer::LineStreamer

  # create a Logline object from each record and serialize it flat to disk
  def process line
    yield Logline.parse(line)
  end
end

Wukong.run( ApacheLogParser, nil, :sort_fields => 7 ) if $0 == __FILE__

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
wukong-3.0.0.pre old/examples/server_logs/apache_log_parser.rb