Skip to content

Instantly share code, notes, and snippets.

@Chandler
Last active December 30, 2015 03:08
Show Gist options
  • Save Chandler/7766963 to your computer and use it in GitHub Desktop.
Save Chandler/7766963 to your computer and use it in GitHub Desktop.
debug combine files
package com.chandler
import com.twitter.scalding._
import com.twitter.scalding.commons.source._
case class TestLzoSource(p : String) extends FixedPathSource(p) with LzoText
class WordCountJob(args : Args) extends Job(args) {
TestLzoSource(args("input"))
.flatMap('line -> 'word) { line : String => line.split("""\s+""") }
.groupBy('word) { _.size }
.write( Tsv( args("output") ) )
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment