Slide 1

Slide 1 text

Write ETL or ELT data processing jobs with bricolage. @inohiro at Cookpad Inc.
 RubyKaigi 2019 LT

Slide 2

Slide 2 text

self.introduce •@inohiro on Twitter and GitHub •Struggling over data business in Cookpad Inc.

Slide 3

Slide 3 text

ETL and ELT https://www.quora.com/Why-are-most-companies-moving-from-ETL-to-ELT SFG

Slide 4

Slide 4 text

bricolage •A batch job framework ‣ Designed to work with AWS services but works with PostgreSQL also ‣ For both ETL and ELT, especially ELT ‣ Written in Ruby https://github.com/bricolages/bricolage

Slide 5

Slide 5 text

Why bricolage •Simple and flexible ‣ Especially if you write SQL mainly •But we also can use Ruby

Slide 6

Slide 6 text

Job •Is written in SQL, Ruby, or even execs other scripts •Declined a job class ‣Help to write frequent patterns jobs ‣load, unload, insert, insert-delta, createview, exec, rebuild-drop, rebuild-rename, adhoc, … •You can define dependencies of jobs as jobnet(s)

Slide 7

Slide 7 text

Let’s see a rebuild-rename job

Slide 8

Slide 8 text

Rebuild a summary table with backup

Slide 9

Slide 9 text

What bricolage does Drop old and temporary tables
 that created previously Create new table and 
 insert summaries ✨ Swap new and old tables ♻

Slide 10

Slide 10 text

Good points for rubyists •Write transformation scripts in Ruby ‣ Use Bricolage::CommandLineApplication class •Define your own useful methods and use them with ERB

Slide 11

Slide 11 text

Thank you •Try to use bricolage •Cookpad is looking for data engineers. Let’s talk $