Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Jenkins Evolutions - JEEConf 2012
Search
Anton Arhipov
May 31, 2012
Programming
0
74
Jenkins Evolutions - JEEConf 2012
Anton Arhipov
May 31, 2012
Tweet
Share
More Decks by Anton Arhipov
See All by Anton Arhipov
Everybody is a Marketer
antonarhipov
0
67
Idiomatic Kotlin, v2023.05
antonarhipov
0
92
Kotlin DSL in under an hour, DevoxxUK 2023
antonarhipov
0
86
Idiomatic Kotlin - KotlinConf Global, Vietnam
antonarhipov
1
72
Kotlin_for_server-side_application_development.pdf
antonarhipov
0
73
Idiomatic Kotlin - IntelliJ IDEA Conf 2022
antonarhipov
0
420
The Lesser-Known Kotlin Features
antonarhipov
0
460
JavaZone 2022 - Building Kotlin DSL
antonarhipov
1
160
SpringIO 2022 - Spring extensions for Kotlin
antonarhipov
0
82
Other Decks in Programming
See All in Programming
dbtのドメイン分割による データ基盤の改善とDigdagとの連携
sakama
0
360
PostmanでAPIの動作確認が楽になった話
h455h1
0
170
#phpcon_odawara オープン・クローズドなテストフィクスチャを求めて / open closed test fixtures
77web
3
230
Goのエラースタックトレースの歴史と今後
sonatard
9
1.5k
Polars入門
daikikatsuragawa
1
100
雑に思考を整理する技術と効能
konifar
60
29k
Amazon SQSコンシューマー疎結合への旅 - 出張! #DevelopersIO IT技術ブログの中の人が語る勉強会 #3
quiver
0
270
What We Can Learn From OSS
inouehi
0
420
コーンフレークから始める モデリング会話入門
ogurotakayuki
0
380
Node.js v22 で変わること
yosuke_furukawa
PRO
9
3.5k
Git Lint
bkuhlmann
4
750
GitHub Actionsで泣かないためにやっておきたい設定 / Recommended GHA settings to avoid crying
pinkumohikan
3
540
Featured
See All Featured
Navigating Team Friction
lara
178
13k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
14
1.5k
Building Adaptive Systems
keathley
31
1.9k
What's new in Ruby 2.0
geeforr
337
31k
Ruby is Unlike a Banana
tanoku
96
10k
Rebuilding a faster, lazier Slack
samanthasiow
73
8.2k
How to train your dragon (web standard)
notwaldorf
73
5.2k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
60
14k
10 Git Anti Patterns You Should be Aware of
lemiorhan
648
58k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
6
1.5k
Thoughts on Productivity
jonyablonski
58
3.8k
Art, The Web, and Tiny UX
lynnandtonic
289
19k
Transcript
Jenkins Evolu-ons Anton Arhipov ZeroTurnaround JRebel
@antonarhipov h/p://arhipov.blogspot.com
Why Evolu-ons?
Why Evolu-ons? test automa-on
Why Evolu-ons? con-nuous integra-on
Why Evolu-ons? con-nuous deployment
Why Evolu-ons? cron on steroids
Agenda ! Background ! Stories • Func-onal
tests • Servlet tests • Scaling ! Random stuff
Background -‐ 2008 ! First installa-on ! Clicked
“Run” when wanted to test stuff
Background 2012 ! 54 215 324 jobs
! 2 5 8 dedicated machines ! Amazon ~7000 instance-‐hour per month ! 3 in house plugin developed ! Custom dashboard (50 x 300 grid)
None
h6ps://github.com/
jenkinsci/ jenkins-‐scripts
Custom Dashboard
story of func-onal tests
JRebel Func-onal JDK Tests
JRebel Func-onal JDK Tests
JRebel Func-onal JDK Tests ! Per JDK •
Per func-onal test • Compile couple of classes • Run some methods and assert • Recompile couple of classes • Run some methods and assert • …
JRebel Func-onal JDK Tests ! Per JDK •
Per func-onal test • Compile couple of classes • Run some methods and assert • Recompile couple of classes • Run some methods and assert • …
JRebel Func-onal JDK Tests ! Per JDK •
Per func-onal test • Compile couple of classes • Run some methods and assert • Recompile couple of classes • Run some methods and assert • …
JRebel Func-onal JDK Tests ! Per JDK •
Per func-onal test • Compile couple of classes • Run some methods and assert • Recompile couple of classes • Run some methods and assert • …
JRebel Func-onal JDK Tests ! Per JDK …
! Which Jenkins feature is the best here?
JRebel Func-onal JDK Tests ! Configura-on matrix FTW!
JRebel Func-onal JDK Tests ! Executed with a
Groovy script
JRebel Func-onal JDK Tests
JRebel Func-onal JDK Tests ! How to get
results? Jenkins feature…
JRebel Func-onal JDK Tests ! Output JUnit XML!
JRebel Func-onal JDK Tests
JRebel Func-onal JDK Tests ! Creates ~ 10 000
new files ! Compile ~ 1700 java classes ! Invoke the JVM ~ 550 -mes
JRebel Func-onal JDK Tests Sloooooooow!
JRebel Func-onal JDK Tests ! I/O ! CPU
! Memory
JRebel Func-onal JDK Tests
JRebel Func-onal JDK Tests ! Bare metal !
Cloud ! Bare metal (+ cloud)
JRebel Func-onal JDK Tests ! Cloud • 1
small instance per JDK • Manual update of AMIs • Slow • Scales!
JRebel Func-onal JDK Tests ! Which Jenkins plugin
to use?
JRebel Func-onal JDK Tests ! Amazon EC plugin
JRebel Func-onal JDK Tests ! Bare metal •
8 core & 16GB RAM gaming machines • Recycled developer machines • Marke-ng demo machines (iMac) • Developer machines, ad-‐hoc (?)
Jenkins Master
Jenkins Master Windows Windows Windows
*nix *nix *nix *nix *nix
Jenkins Master Windows Windows Windows
*nix *nix *nix *nix *nix
Jenkins Master Windows Windows Windows
*nix *nix *nix *nix *nix My Laptop iMac
Adding new machines ! How to manage the
configura-ons? ! How to automate the setup?
Adding new machines ! Chef, Puppet
Taming I/O ! SSD: ~30% performance gain
story of servlet tests
Servlet Tests ! Start a container version •
WebSphere, Weblogic, JBoss, etc ! Deploy applica-ons ! Test results, reload changes, test results, …
Custom Dashboard
Servlet Tests ! How to start a server?
Servlet Tests ! Duh! With a startup script!
Servlet Tests ! Problem: 1 app server, 2
jobs. Which plugin to use?
Servlet Tests ! Thro/le Concurrent Builds plugin
Servlet Tests
Servlet Tests ! How do you deploy an
applica-on?
Servlet Tests ! Start Tomcat ! Copy WAR
files to webapps/ ! GET /some-‐url ! Assert ! Update applica-on ! GET /some-‐url ! Assert
Servlet Tests Sloooooooow!
Servlet Tests ! I/O ! CPU !
Memory
Tes-ng Mul-ple Containers ! Cloud • 1 small
instance per container • Need to update AMIs • Slow • Isola-on
Tes-ng Mul-ple Containers ! Single machine • Port
hell • Memory limits • Fast(er)!
story of DVCS
Story of DVCS ! Problem • Many servers
• Many containers • Many tests • Many JDKs ! Slow feedback cycle
Story of DVCS DEV N tests on N
servers (30 minutes) STABLE M tests on M servers (3 hours) Tests green? Push to branch/repository
Story of DVCS
Story of DVCS
scalability
Story of Scaling ! Problem • Exponen-al growths
of tests • (containers) X (configurations) X (tests) + const! • Fight for executors
Story of Scaling ! Add more machines? !
Spin up more cloud instances? ! A/ach developer machines at night? ! Cut tests scope?
Story of Scaling ! Jenkins helps with elas-city!
Story of Scaling ! Jenkins helps with elas-city!
WIN!
random stuff
Random Stuff ! There’s an app plugin for
that!
Some Cool Plugins ! Mercurial plugin ! Thro/le
Concurrent Builds plugin ! Matrix Configura-on plugin ! Matrix Reloaded plugin ! SSH slaves plugin ! Publish over SSH plugin ! Copy Ar-fact plugin ! Copy to slave plugin
Some Cool Plugins: Con-nuous Deployment !
Build Pipeline plugin ! Parametrized Trigger plugin ! Downstream Buildview plugin ! Fingerprints h6p://zeroturnaround.com/blog/how-‐to-‐use-‐jenkins-‐for-‐job-‐chaining-‐and-‐visualizaQons/
Some Cool Plugins ! Chuck Norris plugin BUILD
SUCCESSFUL
Some Cool Plugins ! Chuck Norris plugin BUILD
FAILED
Build-‐it-‐all! JRebel
Build-‐it-‐all! JRebel
Build-‐it-‐all! IntelliJ NetBeans Eclipse Installer
JRebel
Build-‐it-‐all! IntelliJ NetBeans Eclipse Installer
JRebel
Build-‐it-‐all! IntelliJ NetBeans Eclipse Installer
JRebel Tests
UI
None
None
None
None
QuesQons?