Build time graph broken


After an upgrade from Debian 8 to Debian 9 (currently using Jenkins 2.312), our ‘Build time graph’ is broken:

Any idea how to fix this?


Check for a stack trace in the Jenkins log that might tell you more about what is happening when that failure occurs. The log at may provide hints of the cause.

I ran the Jenkins Docker image for 2.312 and confirmed that it renders the trend graph correctly in my installation. Since the Docker image for 2.312 is running Debian 11 (bullseye) and Java 11.0.12, I’m reasonably confident that the issue is something local in your environment rather than a general purpose failure in Jenkins

OK, checking that log URL you mentioned, shows me there seems to be a problem with the “Project Build Times” plugin:

Oct 28, 2021 11:00:28 AM WARNING hudson.ExtensionFinder$GuiceFinder$FaultTolerantScope$1 error
Failed to instantiate Key[type=hudson.plugins.projectbuildtimes.BuildTimesChart$DescriptorImpl, annotation=[none]]; skipping this component
java.lang.ClassNotFoundException: org.joda.time.Chronology
	at jenkins.util.AntClassLoader.findClassInComponents(
	at jenkins.util.AntClassLoader.findClass(
	at jenkins.util.AntClassLoader.loadClass(
	at java.lang.ClassLoader.loadClass(
Caused: java.lang.NoClassDefFoundError: org/joda/time/Chronology
	at java.lang.Class.getDeclaredMethods0(Native Method)
	at java.lang.Class.privateGetDeclaredMethods(
	at java.lang.Class.privateGetMethodRecursive(
	at java.lang.Class.getMethod0(
	at java.lang.Class.getMethod(
	at hudson.model.Descriptor.<init>(
	at hudson.plugins.projectbuildtimes.BuildTimesChart$DescriptorImpl.<init>(
	at hudson.plugins.projectbuildtimes.BuildTimesChart$DescriptorImpl$$FastClassByGuice$$2ee9c38b.newInstance(<generated>)
	at hudson.ExtensionFinder$GuiceFinder$SezpozModule.onProvision(
Caused: Unable to provision, see the following errors:

1) Error injecting constructor, java.lang.NoClassDefFoundError: org/joda/time/Chronology
  at hudson.plugins.projectbuildtimes.BuildTimesChart$DescriptorImpl.<init>(

1 error
	at hudson.ExtensionFinder$GuiceFinder$FaultTolerantScope$1.get(
	at hudson.ExtensionFinder$GuiceFinder._find(
	at hudson.ExtensionFinder$GuiceFinder.find(
	at hudson.ClassicPluginStrategy.findComponents(
	at hudson.ExtensionList.load(
	at hudson.ExtensionList.ensureLoaded(
	at hudson.ExtensionList.getComponents(
	at hudson.DescriptorExtensionList.load(
	at hudson.ExtensionList.ensureLoaded(
	at hudson.ExtensionList.iterator(
	at org.jenkinsci.plugins.xunit.AliasInitializer.init(
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(
	at java.lang.reflect.Method.invoke(
	at hudson.init.TaskMethodFinder.invoke(
	at hudson.init.TaskMethodFinder$
	at org.jvnet.hudson.reactor.Reactor.runTask(
	at jenkins.model.Jenkins$5.runTask(
	at org.jvnet.hudson.reactor.Reactor$
	at org.jvnet.hudson.reactor.Reactor$
	at java.util.concurrent.ThreadPoolExecutor.runWorker(
	at java.util.concurrent.ThreadPoolExecutor$

However, version 1.2.1 of this plugin is installed:

What would be your advice? Uninstalling and reinstalling that plugin?

Apparently, the libjoda-time-java package was not installed on my Debian 9 system. I now installed it, but even after a restart of my Jenkins Master node, the graph does not appear. No new builds did run yet… maybe I should wait until a build was run and hope that the graph gets regenerated? Or am I on the wrong track here?

Oh wow, is 4 years old now. It needs a bit of love. Seems to me its using a class it doesn’t explictly declare in its pom file, and so whatever was providing it, now doesn’t (probably removed from jenkins core).

It probably wouldn’t be that hard to modernize it and bring it up to date if your interested.

Java doesn’t really work like that :frowning: Dependancies are not pulled from the system at runtime. I think the plugin will need to be recompiled.

@halkeye , you mention the “Global Build Stats” plugin, but for as far as I can conclude from a Google search, hudson.plugins.projectbuildtimes.BuildTimesChart is related to the “Project Build Times” plugin. See

Aren’t we confusing two plugins here? I have the “Project Build Times” plugin installed (version 1.2.1) but even after a restart of my Jenkins Master node, the graph isn’t fixed…

After installing the libjoda-time-java package, I now get other errors. One of them is the following:

Error while serving http://<foobar>/job/<somejob>/buildTimeGraph/png
java.lang.NoClassDefFoundError: Could not initialize class org.jfree.chart.JFreeChart
	at org.jfree.chart.ChartFactory.createStackedAreaChart(
	at hudson.model.Job$4.createGraph(
	at hudson.util.Graph.render(
	at hudson.util.Graph.doPng(
	at java.lang.invoke.MethodHandle.invokeWithArguments(
	at org.kohsuke.stapler.Function$MethodFunction.invoke(

So probably more Java-related packages need to be installed on my system?

I now also installed the libjfreechart-java package and am currently waiting for our Jenkins to restart. I’ll report back later if that solved the problem.

You don’t need to install java packages in your system, they come automatically with a plugin. If not, then the plugin is broken and not compatible anymore with the Jenkins version that you are using.

The project build times plugin was last released 7 years ago. However, the page that you showed with the broken image is not being generated by the project build times plugin. The project build times plugin provides a graph that can be inserted into a dashboard view. The page you’re showing with the broken graph is not a dashboard view as far as I can tell.

There is probably another stack trace somewhere that provides hints for the failure in the job trend chart.

If the dashboard view is also broken (as seems likely based on the stack trace), then your choices for the project build times plugin in a dashboard view are:

  • Remove the plugin and accept that those graphs are not available in the dashboard view
  • Update the plugin to work with recent versions of Jenkins

If you’re interested in updating the plugin to work with recent versions of Jenkins, there is a workshop document that guides through a series of small steps to modernize a plugin. We used many of the steps in the workshop document to create a five part video series on adopting Jenkins plugins.

If you decide to update the plugin, you’re welcome to ask questions here if you encounter surprises or have questions.

1 Like