Skip to content

Instantly share code, notes, and snippets.

@erikbern
Created July 28, 2014 21:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save erikbern/8ddfbab33e1dae7014fe to your computer and use it in GitHub Desktop.
Save erikbern/8ddfbab33e1dae7014fe to your computer and use it in GitHub Desktop.
def tabCounter() = {
implicit def input = getInput()
input.map(_.split('\t').size).reduce(_ + _)
}
val task = LuigiTask().requires(MyTsvJob(buildId)).output(HdfsTarget("output")).do(tabCounter)
val otherTask = LuigiTask().requires(task).output(HdfsTarget("output-2")).do(somethingElse)
otherTask.run() // schedule task and otherTask
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment