Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Distributed testing on Rails

Distributed testing on Rails

Kostas Karachalios

November 30, 2012
Tweet

Other Decks in Programming

Transcript

  1. FOR UNIQUENESS YOU ARE A PRETTY LITTLE SNOWFLAKE •Databases (MySQL,

    MongoDB, etc) •External services (Elastic) •Intelligently distribute specs to Hydras •Nothing works “out of the box” •We don’t want VMs into our developer machines
  2. FOR GREAT SPEED FROM 28 MINUTES TO 4 AND A

    HALF Workers Time Speed (ex/min) 1 28:37 294 2 17:03 493 3 12:07 694 4 10:18 817 5 8:51 951 6 7:24 1,137 7 6:24 1,314 8 5:46 1,460 9 5:23 1,565 10 4:59 1,688 11 4:40 1,803
  3. FOR GREAT SPEED FROM 28 MINUTES TO 4 AND A

    HALF 0 7.5 15 22.5 30 1 2 3 4 5 6 7 8 9 10 11 0 500 1,000 1,500 2,000 Time in minutes Examples per minute Time Speed
  4. FOR HINDSIGHT WEEKS OF TEST RESULTS AVAILABLE FOR REVIEW •We

    are approaching 5,000 builds of the master branch •Identify “Heisenspecs” •Generate statistics
  5. WHO IS JENKINS? KNOWS WHAT WENT BAD, COMPLAINS CONSTANTLY •Java

    web application •Monitors git for changes •Keeps track of builds •Can’t do proper distributed testing •Fires up Kowalski
  6. WHO IS KOWALSKI? BEHIND THE SCENES, GIVES COMMANDS •Splits spec

    files into chunks •Feeds them to the Hydras •Gathers the output •Reports to Jenkins
  7. WHO IS THE HYDRA? "DEMOCRATIZES" YOUR RESOURCES •A user in

    each developer’s machine •Local binaries for services (SQL, MongoDB, Elastic etc) •Reports to Kowalski •Limited to 1 CPU core