Jenkins 2.0 and Beyond
About Jenkins
Jenkins 2.0 is an automation engine with an
unparalleled plugin ecosystem to support all of your
favorite tools in your delivery pipelines, whether your
goal is continuous integration, automated testing, or
continuous delivery.
Let’s discuss
●Why Jenkins 2.0 exists
●What is Jenkins 2.0
●Pipelines
●Other stuff
Meet Jenkins
Jenkins 101
6
• 2005 – Hudson (Sun)
• 2008 – It becomes popular, Duke's Choice
Award
• 2011 – Conflict with Oracle, renaming to Jenkins
• License: MIT (core)
• https://github.com/jenkinsci/
Why “automation”?
7
Continuous Integration
Continuous
Integration
Continuous
Delivery
DevOps
Accounting
automation
Home
Automation
CRON + WebUI
Jenkins weaknesses. Growth Problems
8
Jenkins used to grow faster than its Dev community
Jenkins weaknesses. Compatibility costs
9
• More than 5 years of backward compatibility
• Hudson 2 plugins still work on Jenkins!
• BUT:
• Architecture design issues, complex APIs
• Outdated libs
• Outdated UI
• Plugin integration issues
...Fixes are on the way
Pipelines in Jenkins 1.x
●Create jobs
●Trigger “downstream” jobs for next stage
●Easy!
Pipelines in Jenkins 1.x
Pipelines in Jenkins 1.x
Pipelines in Jenkins 1.x
Pipelines in Jenkins 1.x
Pipelines in Jenkins 1.x
Pipelines in Jenkins 1.x
Classic Job Configuration UI
● All the options you could ever want
○ and more!
● Consistent for almost a decade
Low maintenance
●Many users install Jenkins once
●Usage pattern: “set it, and forget it!”
Meet Jenkins 2.0
jenkins-ci.org/2.0
©2015CloudBees,Inc.AllRightsReserved
20
• CI-to-CD with Pipeline-as-Code
• Improved “out of the box” experience
• Updated easier to use UI
• New Jenkins.xx site
Jenkins 2.0 Themes
Pipeline as Code
©2015CloudBees,Inc.AllRightsReserved
22
• Entire flow is one concise Groovy script using Workflow DSL
– For loops, try-finally, fork-join, etc
• Can restart Jenkins while flow is running
• Allocate build nodes and workspaces
– As many as you want, when you want
• Stages throttle concurrency of builds
• Human input/approval integrated into flow
• Standard project concepts: SCM, artifacts, plugins
Key Pipeline Features
©2015CloudBees,Inc.AllRightsReserved
23
Jenkins Powered CD Pipelines: Jenkins Workflow
Development Production
Commit Build Stage Deploy
? ?
Pipelines Need:
✓ Branching
✓ Looping
✓ Restarts
✓ Checkpoints
✓ Manual Input
Sonar Test
Selenium Test
Perf Test
Jenkins Workflow
©2015CloudBees,Inc.AllRightsReserved
24
A Real-world CD Pipeline with Jenkins Workflow
Development Production
Jenkins Workflow
Pipeline as Code
● Introduce “pipeline” as a new type in Jenkins
● Codify an implicit series of stages into an explicit
.Jenkinsfile in your source repository
● Resumability/durability of the pipeline state
● Extend the DSL with your own steps
github.com/jenkinsci/pipeline-examples
Pipeline DSL
node('docker') {
checkout scm
/* Grab the abbreviated SHA1 of our pipeline’s commit.
*/
sh 'git rev-parse HEAD > GIT_COMMIT'
def shortCommit = readFile('GIT_COMMIT').take(6)
stage 'Build'
def image = docker.build("jenkinsciinfra/bind:build-${shortCommit}")
stage 'Deploy'
image.push()
}
©2015CloudBees,Inc.AllRightsReserved
27
CloudBees Jenkins Pipeline Stage View
Jenkins Pipeline Stage View
SOURCE
CODE
CONTROL
SYSTEM
Code
Commit
<
/
>
Development Production
Jenkins Pipeline
Better Out-of-the-box UX
Better Out-of-the-box UI
User Interface Improvements
User Interface Improvements
● Improved “New Item” page
● More consistent terminology
2.0 is a drop-in replacement for 1.x
● Evolution not revolution
● No need to wait
Better Out-of-the-box UX
Better Out-of-the-box UX
Better Out-of-the-box UI
User Interface Improvements
User Interface Improvements
User Interface Improvements
●Improved “New Item” page
●More consistent terminology
2.0 is a drop-in replacement for 1.x
Get Involved
Jenkins is made of people
Try out Jenkins 2.0
●jenkins-ci.org/2.0
●jenkinsci-users@googlegroups.com
●#jenkins on Freenode
Get Jenkins 2.0 (alpha) now
jenkins-ci.org/2.0
New Community Site: jenkins.io (Beta)
● Modern platform and UI
● Easier to use
● 1-2-3-4 Quickstart
● Centralized Documentation
● Solution-oriented Use
Cases
● Events listings
● Launching March 22nd
Feedback
Q1
– CloudBees Jenkins Platform: Private SaaS Edition Launched
– Jenkins and CJP Certification
Later in 2016
– Jenkins 2.0 Release
– Jenkins 2.0 LTS Release
– Updated User Interface: Blue Ocean
– CloudBees Jenkins Platform 16.05 Release
– Jenkins World (September)
Recent and Upcoming Activities
Questions and Answers

SD DevOps Meet-up - Jenkins 2.0 and Pipeline-as-Code

Editor's Notes

  • #23 Here are some really cool features in Jenkins Workflow. SAs talk here about coolness of Workflow.
  • #24 As we said, CD involves creating Pipelines for application code. This means that for every code “check-in” by every developer, the new code needs to go through the Pipeline that will take it from Dev to Prod. So, the CD Platform needs to manage the execution of many of these Pipelines. And the pipelines can be complex. They may have decision points or branches. They may need to be paused or restarted. Modeling the real-world process of application delivery requires that these pipelines be robust, flexible and powerful.
  • #25 Here’s a real-world example of a complex CD Pipeline used by a Jenkins Workflow user.
  • #28 The CloudBees Jenkins Platform also provides a dashboard that shows the current state of the pipeline activity, such as this example, which is critical to providing a full understanding of how things are performing.