Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Extending Jenkins

You're reading from   Extending Jenkins Get a complete walkthrough of the many interfaces available in Jenkins with the help of real-world examples to take you to the next level with Jenkins

Arrow left icon
Product type Paperback
Published in Dec 2015
Publisher
ISBN-13 9781785284243
Length 152 pages
Edition 1st Edition
Tools
Arrow right icon
Author (1):
Arrow left icon
Donald Simpson Donald Simpson
Author Profile Icon Donald Simpson
Donald Simpson
Arrow right icon
View More author details
Toc

Table of Contents (11) Chapters Close

Preface 1. Preparatory Steps FREE CHAPTER 2. Automating the Jenkins UI 3. Jenkins and the IDE 4. The API and the CLI 5. Extension Points 6. Developing Your Own Jenkins Plugin 7. Extending Jenkins Plugins 8. Testing and Debugging Jenkins Plugins 9. Putting Things Together Index

What this book covers

Chapter 1, Preparatory Steps, will cover the initial setup steps—getting your development environment set up, an overview of Jenkins and some options to install and run it as well as extend the basic setup. We will also review the principles of Continuous Integration, which are explored in greater detail later.

Chapter 2, Automating the Jenkins UI, will discuss how several common issues and bottlenecks may be alleviated through the automation and adaptation of the Jenkins frontend. Here, we will look at four fairly typical use cases, identify the root cause of the issues, and propose some possible improvements that can be made through the alteration and automation of the GUI.

Chapter 3, Jenkins and the IDE, builds on the Continuous Integration principals that we looked at earlier and provides an introduction to the Mylyn project.

It then details how to set up a process that enables developers to interact with Jenkins directly from within their IDE. A selection of examples covers Eclipse, NetBeans, and IntelliJ.

Chapter 4, The API and the CLI, illustrates how we can automate and extend Jenkins through its API and CLI. In this chapter, we will illustrate how to use these interfaces by working through the high-level "building blocks" of an example "Information Radiator" project.

This chapter will explain how to create a dynamic application that consumes information from Jenkins via its exposed interfaces.

We will also review other ways in which you could extend Jenkins via the CLI—by kicking off jobs and making other changes to Jenkins automatically and remotely.

Chapter 5, Extension Points, introduces many important concepts that provide a foundation for the Jenkins Extension points topics in the subsequent chapters. We will run through Java interfaces, Design by Contract, abstract classes, and Singletons. We will then take a look at how these patterns are used in the real world when we define our own Extension Point in Jenkins.

Chapter 6, Developing Your Own Jenkins Plugin, will combine the skills, concepts, and tools from the preceding chapters to build our first Jenkins plugin.

We will take a look at Maven and learn how to set it up and use it for Jenkins plugin development. We will then create our first Jenkins plugin, learn how to install it locally, and then learn how to quickly make, build, and deploy subsequent changes using Maven.

Chapter 7, Extending Jenkins Plugins, makes use of a simple plugin with the "Hello world" functionality we created in the previous chapter to keep the focus on getting to grips with the processes and tools. This chapter takes a look at the best way to get started with adding your own implementations. You will learn how to reuse existing code and functionality and understand how and where to find them.

After taking a look at some existing plugins and using those as examples, we will then take a detailed look at some of the additional resources and technologies you could take advantage of in your own projects.

Chapter 8, Testing and Debugging Jenkins Plugins, explains how to test and debug your own code and how to apply the same approach to existing plugins for troubleshooting.

It covers running tests with Maven, examines some existing tests from a popular plugin, and uses these to demonstrate how you can adapt these approaches to suit your own projects.

We will also take a look at debugging live code through the IDE and show how to integrate these useful functions into popular development IDEs. The final section of this chapter will introduce the inbuilt Jenkins Logger Console.

Chapter 9, Putting Things Together, takes a look at how Jenkins can be extended to work with other technologies and languages. We will start off with a look at the Jenkins Scripting console and see how useful it can be when combined with some Groovy scripting by providing some examples. We will then discuss developing applications using Groovy, Grails, and Gradle as possible alternatives to Maven and Java. The final part of this chapter covers Jenkins and Docker and then discusses how to set up build and deployment pipelines for iOS and Android development.

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image