Nothing Special   »   [go: up one dir, main page]

Skip to content

sends build status and time to an Argus endpoint

License

Notifications You must be signed in to change notification settings

jenkinsci/argus-notifier-plugin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Argus Notifier

NOTE: This plugin is no longer maintained and is up for adoption. Be aware that there may be vulnerable dependencies as a result.

License Jenkins Plugin GitHub release Jenkins Plugin Installs

This Jenkins plugin sends build status and build time (including queue time, build time, and total time) to an Argus endpoint. It also sends system metrics from the Metrics plugin. Administrators can configure whether system and build metrics are automatically sent or not.

Table of Contents

Demo

So, you're using, or considering, the Argus time-series monitoring and alerting platform and you also use Jenkins. Well, hey, you should check this plugin out to easily send Jenkins metrics to Argus.

Configuration

First, you'll need to have a valid Username with Password credential set up in your Jenkins credentials. Next, you simply go to Jenkins -> Manage Jenkins -> Configure System and find the configuration for Argus Notifier. Then you'll configure the following values:

  • Credentials Id - A Username with Password credential that has access to your Argus instance.
  • Argus URL - The URL to your Argus web service endpoint.
  • Scope - The Argus scope you'd like to use (typically we use a URL or conceptual name)
  • Source - The Argus source you'd like to use (the plugin will set this to Scope if you don't fill this in)
  • Send for all builds? - Whether you'd like all builds to send build metrics (timings and status) upon build completion
  • Send system metrics? - Whether you'd like the plugin to send system metrics every minute

You can test that your connection works by hitting the Test Connection button as long as you've selected a valid Credentials Id and filled in your Argus URL. See below:

Argus Notifier configuration - Test Connection animation

Once you've saved or applied your Jenkins configuration, the plugin will go to work.

Show me the money!

So, let's say we have a few jobs set up on Jenkins and a couple of them run quite a bit:

  1. concurrent-runner runs every minute and sleeps for 90 seconds
  2. sir-runs-alot runs every 3 minutes, says "yep" and then sleeps for 70 seconds

Behold, the Jenkins jobs: Jenkins jobs

Queue Information

Clearly we're going to have jobs queue up since we only have 2 executors (WHAT?! NO AGENTS!!). So, let's check out our queue metrics in Argus:

Queue Visualization (w/ legend)

Queue visualization with legend

Queue Visualization (you can hover over the graph to see labels)

Queue visualization with hover

Executor Information

Let's see how those executors are doing...

Executor visualization with legend Executor visualization with hover

Build Times and Statuses

What about those build runs?

Build visualization with legend Build visualization with hover

System Information

System visualization with legend System visualization with hover System animation

Alerts

Of course, since Argus is also an alerting platform you could set alerts for any of these metrics. 😄

Metric implementation details

  • Timings are currently sent in units of seconds for consistency
  • Result statuses are mapped to numbers in BuildResultsResolver
  • Numeric gauge metrics from the Metrics plugin are sent if configured.

Plugin Dependencies

Developer Stuff

Build

To build the project with Maven, simply run mvn clean package

Test

Run mvn clean hpi:run to start up a test version of Jenkins with the requisite plugins installed.

Releasing

Run mvn release:prepare release:perform but ensure that your Maven settings.xml has been set up with your Artifactory password