Skip navigation

Website

November 6, 2012 Previous day Next day

Hi all,

 

new integration point for JBoss Community systems is here as I promised last week. It's based on feature request ORG-1560 and allows you to display build results from Jenkins instance running at the hudson.jboss.org on the issues.jboss.org hosted JIRA dashboard or on some pages of community.jboss.org.

Displaying build status on JIRA Dashboard

If you want to display build status on jira dashboard, simply login to JIRA and display your dashboard (you have to create your personal dashboard if not created one yet and use only default dashboard). Then use "Add Gadget" button at top right, select "Other" group in "Gadget directory", and use "Add now" button for "Build Status" gadget.

JiraBuildGadget1.png

Then you can close "Gadget directory" and configure gadget on dashboard to show selected build. Use small arrow button on top right of gadget window to open menu, and use "Edit" item here. Then you can put name of selected jenkins job into provided input field and "Save" it.

JiraBuildGadget2.png

Page is reloaded and voila, build status for selected job is shown here.

JiraBuildGadget3.png

Color around Job title is changing depending on status of last builds to provide you quick visual information. It can be green, yellow or red. Job title acts as link to the job page in Jenkins server. And there are links to the latest, latest successful and latest stable builds of given Job too.

 

If you want to monitor more jobs simply add other "Biuld Status" gadgets into Dashboard.

Displaying build status in community.jboss.org

Very similar process can be used to display build status in some pages of community.jboss.org system. It can be used on all pages with configurable layout as is Personal dashboard, Space main page, Group main page etc. 

SBSBuildGadget.png

Technical background

Build status displaying is based on Google Gadget technology, so in reality it can be used in each system/container supporting this technology. Gadget is hosted as plugin in JIRA, and uses Jenkins REST API to obtain build status information to be displayed.

If you want to use this gadget in another gadget container system, you can find URL to the Gadget definition xml file on JIRA "Gadget directory" page, it's https://issues.jboss.org/rest/gadgets/1.0/g/org.jboss.jira.plugin.build-gadgets:build-status-gadget/gadget.xml .

 

And finally, source code for this gadget is available at https://github.com/jbossorg/jira-jenkins-gadget

 

Enjoy