Tuesday, May 14, 2013

Toastmaster Speech #2 – An Introduction to Jenkins Continuous Integration Server

Time Limits: 6/7/8 mins

Actual Time Taken: 10 min 02 secs.

Following is the content of the speech:


1. What is Jenkins?

a. It’s a continuous integration server.

b. It is a fork of another CI server project Hudson (started by Koshiko Kawaguchi of erstwhile Sun Microsystems).

c. It is free and open source.

2. Hallmarks of Jenkins CI Server:

1. Automates builds via build triggers.

2. Automates running test suites. Fails the build if test fails. Trending of test failures by builds.

3. Encourages regular commits to the version control

4. Builds on each commit

5. Fast builds – build the module and run unit tests per module. Jenkins even supports clustering and can send the builds for different modules to different nodes in the cluster thus enabling “parallel” builds.

6. Dashboard – web based dashboard for viewing results and other notification methods like sending emails etc.

3. Why Jenkins?

a. All CI servers can poll a version control repo and execute compile and test.

b. Jenkins stands-out due to its easy-to-use web UI (with context sensitive help at each UI control level) and its extensive plugin ecosystem.

c. Due to its plug-in based ecosystem, it integrates with most of the popular version control repos, run builds for multiple languages, and view a host of valuable reports about your code.

4. How it works?

a. Jenkins supports both Ant and Maven build tools.

b. Out of the box Jenkins supports 2 version control repos: CVS and SVN.

c. Jenkin Job – You need to define a job to build a certain project. The important items you need to define are:

i. Source code management

1. Which version control branch, tag or label you are building the source code from. This is the “integration” in the CI as your team will be constantly adding new code to version control.

ii. Build triggers – when should the source code be built? This is the “continuous” of the CI.

1. Periodically – say once a day.

2. Poll SCM – set a duration say every 15 mins (specified as cron-like expresssion). If there is a commit that happened since the last poll the build will be executed.

iii. Build – what build goals/targets of the build script to execute.

d. We can have multiple jobs for the same project executing different parts of the build lifecycle. For example, we can have another job that executes once a day and executes the complete integration test suite on the build.

5. Jenkins Dashboard

a. Last Success(S) – status of the latest build

b. Weather (W) – overall health of the job – how many times build failed, whether the tests passed, and other scenarios depending on configured plugins.

6. Execute a build – can be either done manually or automatically (if polling SCM option selected).

7. Report – We can view the test reports for tests executed (triggered via Jenkins)

8. Plugin Manager – Plugins for code metrics tooling are available:

a. Checkstyle – enforces good coding guidelines.

b. FindBugs

9. Conclusion

•Jenkins an extensible CI server tool with easy to use UI and very easy to deploy.

•Use of CI server like Jenkins will go a long way in improving the quality of the software in an organization.

No comments:

Using a Console Cable (USB TTL Serial Cable) with Raspberry Pi 3

A console cable provides terminal access to Raspberry Pi from say a laptop host without requiring to connect a monitor to Pi's HDMI port...