Dashboard View

Skip to end of metadata
Go to start of metadata

Plugin Information

Plugin ID dashboard-view Changes In Latest Release
Since Latest Release
Latest Release
Latest Release Date
Required Core
Dependencies
2.9.2
Oct 27, 2013
1.509.1
maven-plugin (version:1.509.1)
Source Code
Issue Tracking
Maintainer(s)
GitHub
Open Issues
Peter Hayes (id: petehayes)
Marco Ambu (id: mambu)
Usage Installations 2013-Apr 8162
2013-May 8436
2013-Jun 8684
2013-Jul 9151
2013-Aug 9221
2013-Sep 9518
2013-Oct 9981
2013-Nov 10188
2013-Dec 9998
2014-Jan 10475
2014-Feb 10968
2014-Mar 11493

This plugin contributes a new view implementation that provides a dashboard / portal-like view for your Jenkins instance.

Description

This plugin contributes a new view implementation that provides a dashboard / portal-like view for Jenkins.

Add new view

On the Jenkins main page, click the + tab to start the new view wizard (If you do not see a +, it is likely you do not have permission to create a new view).  On the create new view page, give your view a name and select the Dashboard type and click ok.  

Configure dashboard view

The configuration is done in 2 parts, selecting the Jenkins jobs to include in the view, and selecting which dashboard portlets to have included in the view.  The jobs that you select are used for all the portlets to draw their information from.

Select jobs

Select the list of jobs to include in the dashboard. This is exactly the same process as the standard list view that comes with Jenkins.

Also a regular expression can be used to specify the jobs to include in the view.

Options

  • Show standard Jenkins list at the top of the page: shows uses standard Jenkins jobs list as it would be when using Jenkins' built-in  'List View' type.

Select portlets

Configure which portlets you want to see on the top and on the left and the right column.  Each portlet may have its own configuration but at a minimum it requires a name to be given to it.
Click ok and the dashboard configuration will be saved and you will be brought to the dashboard view itself.

View layout

The dashboard view supports a layout with rows spanning the entire view with 2 columns.

Top portlet 1........
.......................
Left portlet 1
Right portlet 1
Left portlet 2
Right portlet 2
Bottom portlet 1...
.......................

Core portlets

The dashboard view comes with a number of portlets that you can configure your view with (New portlets can be contributed to Jenkins via other plugins, even your own).

Standard Jenkins jobs list

This portlet shows a row for each job showing the standard columns configured in Jenkins. All the configured portlets are displayed below this list.

Jobs Grid

The jobs grid portlet displays a 3 column table with the current status and a clickable link to the job.  This offers a more compressed presentation of your jobs than the standard 1 row per job view, albeit at the cost of some job information.

Unstable Jobs

This portlet lists the unstable jobs within the view.  Note, this does not necessarily list all of Jenkins' unstable jobs, but only looks at jobs configured for this view.

Test Statistics Grid

The test statistics grid shows detailed test data for the configured jobs.  This is useful to get an aggregated count of tests across the jobs in your view.

Test Statistics Chart

This is a pie chart of the tests in the configured jobs.  It shows the passing, failing, and skipped jobs with the total # and percentages.

Test Trend Chart

This is a chart that shows your tests over time in aggregate.  The logic is that for every day since the first job in the view was built, it shows the total number of passing, skipped and failing tests in aggregate across the build.  It assumes that if a build did not occur on a given day, that the previous day's build results (or the previous-previous day, etc.) will be used.

Jobs statistics

Shows statistics based on jobs health.

Build statistics

Shows statistics based on build status.

Extending the Dashboard View plugin

Much of the benefit of this plugin will be realized when other plugins that enhance Jenkins offer support for it.

Add support in your plugin:

  • Extend the DashboardPortlet class and provide a descriptor that extends the Descriptor<DashboardPortlet>
  • Create a jelly view called portlet.jelly
  • Optionally create a jelly view called main.jelly to be used when the portlet is in maximized mode (otherwise the same portlet.jelly view will be used)

It is possible to define custom parameters for the DashboardPortlet. The displayName is always required. To add new parameters:

  • create a jelly file called config.jelly to be used when the portlet is configured (added to the view in 'Edit View' config page);
  • modify constructor (with @DataBoundConstructor) to receive the new parameters.

Looking at the source code of this plugin will show a number of examples of doing this. The core portlets do the same thing that your plugin would do.

On your plugin Wiki page, add the label supports-dashboard-view so that it will show up in the list below.

Sample files:

MyPortlet.java
import hudson.plugins.view.dashboard.DashboardPortlet;

class MyPortlet extends DashboardPortlet {

    @DataBoundConstructor
    public MyPortlet(String name) {
        super(name);
    }

// do whatever you want

    @Extension
    public static class DescriptorImpl extends Descriptor<DashboardPortlet> {
        @Override
        public String getDisplayName() {
            return "MyPortlet";
        }
    }
};
portlet.jelly
<j:jelly xmlns:j="jelly:core" xmlns:st="jelly:stapler" xmlns:d="jelly:define" xmlns:dp="/hudson/plugins/view/dashboard" xmlns:l="/lib/layout" xmlns:t="/lib/hudson" xmlns:f="/lib/form">

  <dp:decorate portlet="${it}"> <!-- This is to say that this is a dashboard view portlet -->
    <tr><td> <!-- This is needed because everything is formatted as a table - ugly, I know -->

      <!-- you can include a separate file with the logic to display your data or you can write here directly -->
      <div align="center">
        <st:include page="myportlet.jelly"/>
       </div>

     </td></tr>
  </dp:decorate>
</j:jelly>

Other plugins that support the Dashboard View

Page: Project Statistics Plugin — This plugin provides new dashboard-view portlets and new columns for displaying project statistics for your Jenkins instance.
Page: Release Plugin — This plugin adds the ability to wrap your job with pre- and post- build steps which are only executed when a manual release build is triggered.
Page: PMD Plugin — This plugin generates the trend report for PMD, an open source static code analysis program. 
Page: Task Scanner Plugin — This plugin scans the workspace files for open tasks and generates a trend report.
Page: Static Code Analysis Plug-ins — This plug-in provides utilities for the static code analysis plug-ins.
Page: Rich Text Publisher Plugin — This plugin puts custom rich text message to the Build pages and Job main page (for last build). Atlassian Confluence, WikiText and HTML notations are supported.
Page: CCM Plugin — This plug-in generates reports on cyclomatic complexity for .NET code.
Page: Android Lint Plugin — Parses output from the Android lint tool and displays the results for analysis.
Page: Custom Job Icon Plugin — This plugin allows to configure a custom icon for each job in order to improve the job visibility on the dashboard.
Page: Checkstyle Plugin — This plugin generates the trend report for Checkstyle, an open source static code analysis program. 
Page: Warnings Plugin — This plugin generates the trend report for compiler warnings in the console log or in log files.
Page: FindBugs Plugin — This plugin generates the trend report for FindBugs, an open source program which uses static analysis to look for bugs in Java code. 
Page: Analysis Collector Plugin — This plug-in is an add-on for the plug-ins Checkstyle, Dry, FindBugs, PMD, Task Scanner, and Warnings: the plug-in collects the different analysis results and shows the results in a combined trend graph. Additionally, the plug-in provides health reporting and build stability based on these combined results.
Page: Cppcheck Plugin — This plugin generates the trend report for CppCheck, a tool for static C/C++ code analysis.
Page: M2 Release Plugin — This plugin allows you to perform a release build using the maven-release-plugin from within Jenkins.
Page: DRY Plugin — This plugin generates the trend report for duplicate code checkers like CPD or Simian.
Page: SLOCCount Plugin — This plug-in generates the trend report for SLOCCount, an open source program which counts the number of lines of codes in over 25 different languages, including C/C++, Ada, COBOL, Fortran, SQL, Ruby, Python, etc...

TODO

  • Use 'div' instead of 'table' to place portlets in the page.
  • update this wiki page with more updated screenshots.

This portlet has been implemented in the Project Statistics Plugin:
Idea for another portlet as asked in the mailing list: Number of failed/Unstable/Success builds per project

Job
Success
Unstable
Fail
MyJob1
5
3
1

Version History

Version 2.9.1 (2013/8/16)

  • Upgrading to dashboard-view 2.9 causes Jobs Grid information to not be displayed (issue #19219).

Version 2.9 (2013/8/13)

  • Added configuration to JobsPortlet: Number of column and job filling direction.
  • Added Timeshift-Option for Test-Trend-Chart (issue #15814).
  • Build statistics does not display result with regex .* filter (issue #18880).
  • Added Number of columns and Fill column first parameters (pull/10).
  • Awful performance from Latest Builds portlet (issue #18861).

Version 2.8 (2013/7/9)

  • Avoid loading too many build records for display jobs (issue #15858).
  • Fix test trend chart for TestNG test results.
  • Sort list of available dashboards alphabetically (issue #6289).

Version 2.7 (2013/6/27)

  • Dashboard View plugin v2.6 broke URL path to build stability images(issue #18049).

Version 2.6 (2012/05/19)

TBC

Version 2.5 (2012/03/23)

  • Added possibility to sort the test statistics grid portlet results issue #16943
  • Added iframe portlet
  • Removed configure link from dashboard

Version 2.4 (2012/11/12)

  • Fixed null pointer exception in TestTrendChart portlet issue #14522
  • Showing Jenkins pop-up menu when hovering on the job link issue #15294
  • Added optional colours to TestStatisticChart (improvement provided by user jake-stacktrace)
  • Added support for folders in view (provided by user ndeloof)

Version 2.3 (2012/07/17)

  • Added image portlet: allows to display an image given the URL
  • Modified "Test Trend Chart" portlet: allow to select what type of tests to display (All tests, Only successful, Only failed, Only skipped) issue #12126
  • Modified "Test Trend Chart" portlet: modified x-axis label of test trend to use only day-month

Version 2.2 (2012/01/11)

Version 2.1 (2011/10/08)

  • Added patch provided by Matt issue #9559
  • Added timestamp sorting in LatestBuilds view issue #9606
  • TestTrendChart was reporting tests contribution in the past; modified to contribute to the future issue #10529
  • Fixed visualization when a date range is provided issue #10529
  • Fixed issue with test trend chart is empty with maven2 projects issue #7099 (fix provided by user larrys)
  • Add new statistics portlet "Slaves statistics" which displays count of slaves, offline slaves, online slaves, disconected slaves, tasks in a queue and running jobs (provided by user lvotypko)

Version 2.0.2

  • Renamed hudson to jenkins.

Version 2.0.1 (2011/03/07)

  • Supported near 100 and near 0 percents in test statistics grid issue #7913
  • Modified relative to absolute URL image for portlet collapse/expand icons issue #8956
  • Improved the usability of show/hide portlet; using new icons from jenkins theme issue #8624]
  • Added build button to Unstable and Grid Jobs portlets issue #7569

Version 2.0 (2011/02/11)

  • Modified for github and Jenkins.
  • Allow to hide/show portlets directly from the dashboard (without having to go to the configuration page); see issue #7465 and issue #8623 (fix provided by Godin)
  • Allow to specify a range of dates for TestTrendGraph portlet (use 0 to auto-adjust the range) issue #7596
  • Supported near 100 and near 0 percents in test statistics grid issue #7913 (missing in this version)
  • Fixed bug issue #7595

Version 1.8.2 (01/20/2011)

  • Added Japanese translation.

Version 1.8.1 (09/16/2010)

  • Allow to configure standard view parameters for Dashboard View issue #6618

Version 1.8 (09/15/2010)

  • Added some italian translations
  • The configuration page has been re-organized
  • Allow to specify width of left and right columns in dashboard view (percentage or fixed width) issue #7429

Version 1.7 (08/12/2010)

  • Show job description tooltip and build description tooltip issue #7107
  • Allow parametrization of graph width and height for 'Test Trend Graph' Portlet issue #6811
  • Allow parametrization of number of builds used for 'Latest Builds' portlet issue #7090
  • Keep 'standard' order for jobLink: build status - health status - job name issue #6611
  • Added i18n to some parts of the plugin

Version 1.6 (05/20/2010)

  • Added health icon in custom jobLink
  • Added 'title' attribute to img tags
  • Added default name on portlet add issue #5952
  • Added unique id to each portlet (within the same dashboard/view) issue #6118

Version 1.5 (04/02/2010)

  • Fixed 'Last 10 builds' showing always bullet from last build issue #6091
  • Fixed 'Last 10 builds' doesn't filter jobs issue #6106
  • Allowing to hide disabled jobs when not using regexp

Version 1.4 (03/25/2010)

  • Fixed standard Jenkns list view visualization problem

Version 1.3 (03/05/2010)

WARNING: if upgrading from a previous release, all the dashboard views must be edited and saved (also without modifying anything) to correctly work with this version.

  • Layout: added top portlets (portlets that spawn the entire page width) and are shown above the left and right portlets issue #5759
  • New portlets:
    • standard Jenkins jobs list issue #5691
    • Jobs statistics
    • Build statistics
  • Added option to show standard Jenkins jobs list before displaying all the portlets issue #5814

Version 1.1 (11/15/2009)

  • Fixed issue with Unstable Jobs portlet where content was empty if builds were being actively run
  • New option on regular expression job inclusion to prevent disabled jobs from appearing
  • Supports single column view if only portlets are only specified for left or right column

Version 1.0 (10/11/2009)

  • Initial release

Labels

Edit
plugin-ui plugin-ui Delete
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.

Add Comment