Slide 1

Slide 1 text

Travis CI I hear you like Pull Requests

Slide 2

Slide 2 text

For the code is dark and full of errors. Game Of Thrones Home Box Office Inc. A Time Warner Company

Slide 3

Slide 3 text

Konstantin Haase Open Source Developer github.com/rkh @konstantinhaase

Slide 4

Slide 4 text

No content

Slide 5

Slide 5 text

Maintainer of Sinatra Rack, Rubinius, Travis CI

Slide 6

Slide 6 text

“Second to K&R, the most lagom technical book I’ve read.” Peter Cooper (Ruby Inside) Discount Code: AUTHD 50% off ebook ($6.50) 40% off print

Slide 7

Slide 7 text

No content

Slide 8

Slide 8 text

GitHub Oh My God

Slide 9

Slide 9 text

No content

Slide 10

Slide 10 text

No content

Slide 11

Slide 11 text

No content

Slide 12

Slide 12 text

No content

Slide 13

Slide 13 text

No content

Slide 14

Slide 14 text

No content

Slide 15

Slide 15 text

Time release branches master develop hot xes feature branches Feature for future release Tag 1.0 Major feature for next release From this point on, “next release” means the release after 1.0 Severe bug xed for production: hot x 0.2 Bug xes from rel. branch may be continuously merged back into develop Tag 0.1 Tag 0.2 Incorporate bug x in develop Only bug xes! Start of release branch for 1.0 Author: Vincent Driessen Original blog post: http://nvie.com/archives/323 License: Creative Commons

Slide 16

Slide 16 text

No content

Slide 17

Slide 17 text

No content

Slide 18

Slide 18 text

No content

Slide 19

Slide 19 text

No content

Slide 20

Slide 20 text

No content

Slide 21

Slide 21 text

No content

Slide 22

Slide 22 text

No content

Slide 23

Slide 23 text

One does not simply merge a Pull Request! The Lord of the Rings New Line Cinema A Time Warner Company

Slide 24

Slide 24 text

No content

Slide 25

Slide 25 text

No content

Slide 26

Slide 26 text

No content

Slide 27

Slide 27 text

No content

Slide 28

Slide 28 text

No content

Slide 29

Slide 29 text

No content

Slide 30

Slide 30 text

No content

Slide 31

Slide 31 text

ravis CI

Slide 32

Slide 32 text

No content

Slide 33

Slide 33 text

CIaaS aka the “one click CI system”

Slide 34

Slide 34 text

No content

Slide 35

Slide 35 text

No content

Slide 36

Slide 36 text

No content

Slide 37

Slide 37 text

No content

Slide 38

Slide 38 text

No content

Slide 39

Slide 39 text

No content

Slide 40

Slide 40 text

No content

Slide 41

Slide 41 text

No content

Slide 42

Slide 42 text

No content

Slide 43

Slide 43 text

No content

Slide 44

Slide 44 text

No content

Slide 45

Slide 45 text

No content

Slide 46

Slide 46 text

No content

Slide 47

Slide 47 text

No content

Slide 48

Slide 48 text

No content

Slide 49

Slide 49 text

No content

Slide 50

Slide 50 text

Three different JVMs, GCC & clang, Six Erlang versions, Clojure, Go, Groovy, Three Node.js versions, Haskell, Four Perl versions, Four Python versions plus PyPy, Two PHP versions, Ten (!) different Ruby versions/implementations, Two Scala versions, anything that runs on Linux GUI and Browser Testing (headless X11, Firefox and Chrome), with PhantomJS, Selenium, etc. MySQL, PostgreSQL, MongoDB, CouchDB, Redis, Riak, RabbitMQ, Memcached, Cassandra, Neo4J, ElasticSearch, Kestrel, SQLite, full root access, custom build steps, 3rd-party PPAs Notifications per Email, IRC, GitHub, Campfire, HipChat, Flowdock, Pusher, Web hook more than 15 Programming Languages with multiple implementations

Slide 51

Slide 51 text

more than 2,250,000 Test Suits 25,000 Open Source Projects more than 17,000 Test Suits, 1,000 Private Projects

Slide 52

Slide 52 text

more than 2,250,000 Test Suits 25,000 Open Source Projects for free

Slide 53

Slide 53 text

100% Open Source

Slide 54

Slide 54 text

“What Github did for sharing code, Travis CI will do for testing code. The value of this service cannot be overstated. Travis CI is a paradigm shift. The world will be a better place when every open-source developer is running their test suite on Travis CI.” Brian Ford Lead Developer, Rubinius Engine Yard

Slide 55

Slide 55 text

No content

Slide 56

Slide 56 text

← Home Travis - an experimental, distributed CI server on Heroku We had the I18n gem tested on runcoderun, a great service for open source projects to run continous integration on the web, and this was working very well for us. Unfortunately runcoderun was taken down. So I figured it should be easy to setup a few apps on Heroku and have them run the I18n test suite on different stacks (i.e. Ruby configurations on Heroku). It turns out it is not, apparently. Or I'm just too stupid to do it. Anyway I though I'd write things down so maybe someone else can pick this experiment up and push it a few steps farther. The current state is that Travis can automatically set up a single ci server and 3 ci runners on Heroku. The server app takes the ping from github and pings the 3 runners. Each of the runners forks and immediately returns from the parent (forking) process while the child process runs the build command and posts the result back to the server. The server stores the result and displays it on the builds index page. Everything's cool except that the runner does not work properly on neither aspen-mri-186 (i.e. Ruby 1.8.6) nor bamboo-mri-191 (i.e. Ruby 1.9.1). It seems to work fine on the bamboo-ree-187 stack though and I will leave it running for a while so we can see how it works out over a few commits to the I18n repository. 2010-06-16

Slide 57

Slide 57 text

← Home Travis - a distributed build server tool for the Ruby community So, I’ve started playing with the idea of a distributed build server tool once again in last year’s December … and Travisis what I came up with. Status quo ■ Travis is currently running on http://travis.heroku.com and already notifies me about builds that pass or fail when someone pushes to those repositories I’ve registered for testing purposes. ■ The builds run on a virtual server that Julian Fischer has very kindly granted for this experiment. ■ The frontend is implemented using Backbone.js. ■ Build output and status information is “tailed” from the workers to the frontend (i.e. browsers) using websockets via Pusher. It is also pushed back to application (running on Heroku) using a standard REST API. All of these building blocks might change in the future, but here’s an overview of how they currently work together. And here’s a short screencast (the UI has changed a bit in the meanwhile but you’ll get the idea): 1:20 quick demo screencast. 2011-02-05

Slide 58

Slide 58 text

5,000 10,000 15,000 20,000 25,000 30,000 2010-12 2011-03 2011-06 2011-09 2011-12 2012-03 2012-06 2012-09 Active Projects Open Source Private

Slide 59

Slide 59 text

50,000 100,000 150,000 200,000 250,000 300,000 2011-03 2011-05 2011-07 2011-09 2011-11 2012-01 2012-03 2012-05 2012-07 2012-09 Test Suit Executions per Month Open Source Private

Slide 60

Slide 60 text

Java (1112) 5% Python (2413) 10% PHP (3319) 13% JavaScript (3837) 16% Ruby (11752) 48% Ruby (11752) JavaScript (3837) PHP (3319) Python (2413) Java (1112) Erlang (371) C (362) Clojure (333) Haskell (310) Perl (232) Scala (201) Go (134) C++ (132) Other (60) Groovy (34) Open Source Projects by Language 2012-10-26

Slide 61

Slide 61 text

2012-10-26 Python (43) 4% PHP (83) 9% JavaScript (47) 5% Ruby (742) 77% Ruby (742) JavaScript (47) PHP (83) Python (43) Java (17) Erlang (9) C (1) Clojure (12) Haskell (3) Scala (1) Private Projects by Language

Slide 62

Slide 62 text

Ruby C++ Scala Perl Erlang PHP Java Python Haskell Groovy C JavaScript Clojure Other Go 72.7% 75% 83% 66.7% 65.1% 64.7% 61.4% 44.4% 58.9% 90.3% 88.3% 87.7% 87.3% 85.4% 85.3% 79% 79% 78% 76.3% 76.3% 74.1% 74.1% 70.5% 61.2% Success Rate by Language 2012-10-26 Open Source Private

Slide 63

Slide 63 text

20,000 40,000 60,000 80,000 100,000 120,000 11-10 11-12 12-02 12-04 12-06 12-08 12-10 GitHub Events for Open Source Push Pull Request

Slide 64

Slide 64 text

20,000 40,000 60,000 80,000 100,000 120,000 12-04 12-06 12-08 12-10 GitHub Events for Private Projects Push Pull Request

Slide 65

Slide 65 text

scalability is not optional

Slide 66

Slide 66 text

No content

Slide 67

Slide 67 text

ci

Slide 68

Slide 68 text

ci travis-ci.org

Slide 69

Slide 69 text

ci travis-ci.org

Slide 70

Slide 70 text

ci travis-ci.org web next.travis-ci.org

Slide 71

Slide 71 text

ci travis-ci.org web next.travis-ci.org api api.travis-ci.org

Slide 72

Slide 72 text

ci travis-ci.org web next.travis-ci.org api api.travis-ci.org

Slide 73

Slide 73 text

ci web api

Slide 74

Slide 74 text

ci web api postgres

Slide 75

Slide 75 text

ci web api postgres hub

Slide 76

Slide 76 text

ci web api postgres hub AMQP/Redis

Slide 77

Slide 77 text

ci web api postgres hub AMQP/Redis listener

Slide 78

Slide 78 text

ci web api postgres hub AMQP/Redis listener

Slide 79

Slide 79 text

ci web api postgres hub AMQP/Redis listener worker Virtual Machine Virtual Machine Virtual Machine

Slide 80

Slide 80 text

ci web api postgres hub AMQP/Redis listener worker Virtual Machine Virtual Machine Virtual Machine admin

Slide 81

Slide 81 text

ci web api postgres hub AMQP/Redis listener log writer Pusher worker Virtual Machine Virtual Machine Virtual Machine admin

Slide 82

Slide 82 text

ci web api postgres hub AMQP/Redis listener status notifier log writer Pusher worker Virtual Machine Virtual Machine Virtual Machine admin

Slide 83

Slide 83 text

ci web api postgres hub AMQP/Redis listener status notifier log writer Pusher worker Virtual Machine Virtual Machine Virtual Machine enqueue admin

Slide 84

Slide 84 text

ci web api postgres hub AMQP/Redis listener status notifier log writer Pusher worker Virtual Machine Virtual Machine Virtual Machine enqueue gate- keeper admin

Slide 85

Slide 85 text

ci web api postgres hub AMQP/Redis listener status notifier log writer Pusher worker Virtual Machine Virtual Machine Virtual Machine enqueue gate- keeper tasks admin

Slide 86

Slide 86 text

ci web api postgres hub AMQP/Redis listener status notifier log writer Pusher worker Virtual Machine Virtual Machine Virtual Machine cli enqueue gate- keeper tasks admin

Slide 87

Slide 87 text

ci web api postgres hub AMQP/Redis listener status notifier log writer Pusher worker Virtual Machine Virtual Machine Virtual Machine cli enqueue gate- keeper tasks admin billing

Slide 88

Slide 88 text

No content

Slide 89

Slide 89 text

553

Slide 90

Slide 90 text

No content

Slide 91

Slide 91 text

No content

Slide 92

Slide 92 text

No content

Slide 93

Slide 93 text

No content

Slide 94

Slide 94 text

“When you don't create things, you become defined by your tastes rather than ability. Your tastes only narrow and exclude people. So create.” why the lucky stiff Ruby Art Project by Jonathan G.

Slide 95

Slide 95 text

No content

Slide 96

Slide 96 text

Thanks [email protected] @konstantinhaase github.com/rkh