Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-50924

StackedArea chart style broken in plot plugin since 2.0.0


    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Component/s: plot-plugin
    • Labels:
    • Environment:
      Jenkins 2.117, Plot plugin 2.0.3
    • Similar Issues:


      The StackedArea chart style stopped working after recent updates to the plot plugin and the graph is now simply shown in the default line style.

      After looking into the code base I discovered that the bug is caused by a recent change in creating the charts via hudson.plugins.plot.Plot#createChart and the newly introduced ChartStyle enum.

      The problem is that via the hudson.plugins.plot.Plot.ChartStyle#forName method the given style is now compared case-sensitive while it was previously compare case-insensitive. And it just so happens to be that the StackedArea style is passed via the config as stackedArea (see hudson/plugins/plot/PlotBuilder/config.jelly:41) but the name of the hudson.plugins.plot.Plot.ChartStyle#STACKED_AREA enum is just stackedarea.

      This results in the StackedArea style to be interpreted as LineSimple style, which is not the desired outcome. Fixing this bug could be done via a change to the config file or to the name of the enum. Or just change the comparison to be again case-insensitive as before.

      Thanks in advance for looking into this. It would be great if our graph would work again as expected.




          stefanv Stefan Victora created issue -
          vgaidarji Veaceslav Gaidarji made changes -
          Field Original Value New Value
          Status Open [ 1 ] In Progress [ 3 ]
          vgaidarji Veaceslav Gaidarji made changes -
          Status In Progress [ 3 ] In Review [ 10005 ]
          vgaidarji Veaceslav Gaidarji made changes -
          Status In Review [ 10005 ] Resolved [ 5 ]
          Resolution Fixed [ 1 ]


            • Assignee:
              vgaidarji Veaceslav Gaidarji
              stefanv Stefan Victora
            • Votes:
              0 Vote for this issue
              3 Start watching this issue


              • Created: