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

Build failure causes are deleted when saving Jenkins global configuration.

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Reopened (View Workflow)
    • Priority: Blocker
    • Resolution: Unresolved
    • Labels:
      None
    • Environment:
      Windows, jdk1.8.0_141, Jenkins LTS 2.190.1.
      Installed plugin list in attached file.
    • Similar Issues:
    • Released As:
      1.23.1

      Description

      Basically a new build-failure-analyzer.xml configuration file with default settings is written when "Save" is clicked in Jenkins global configuration (http://jenkins_ulr/configure).

      I also observed that when installing build-failure-analyzer first time, then restart Jenkins, still there is no build-failure-analyzer.xml in JENKINS_HOME.
      If I change a global setting and click save, the file appears.
      If I add a failure cause, and and use it, it stays and is visible in build-failure-analyzer.xml.
      And the failure cause is still there after restarting Jenkins.
      But if I change the global configuration, the modifed file is overwritten with default settings, which means that I effectively loose all my failure causes.

      My BFA global settings are in the screenshot, and I notice alse that it defaults to enable the gerrit-trigger notifications, although that plugin is not installed.

      Reproduce:
      Install Jenkins, install all mentioned plugins except BFA
      Install BFA, restart Jenkins, Notice there is no BFA configuration file
      Change a global setting and save. Notice BFA configuration file now exist
      Add a failure cause - do what ever, the failure cause stays
      Change a global setting and save. Notice BFA configuration file still exists, but the failure cause is gone.

        Attachments

          Issue Links

            Activity

            jbrejner1 Jens Brejner created issue -
            t_westling Tomas Westling made changes -
            Field Original Value New Value
            Status Open [ 1 ] In Progress [ 3 ]
            Hide
            t_westling Tomas Westling added a comment -

            I have been able to reproduce the issue locally.

            Show
            t_westling Tomas Westling added a comment - I have been able to reproduce the issue locally.
            Hide
            n_o_a Nils Oliver Adam added a comment - - edited

            With Jenkins LTS 2.176.3 I've got the same issue.

            By going back from Build Failure Analyzer 1.23 to Build Failure Analyzer 1.22  the deletion doesn't happen anymore.

            Show
            n_o_a Nils Oliver Adam added a comment - - edited With Jenkins LTS 2.176.3 I've got the same issue. By going back from Build Failure Analyzer  1.23 to Build Failure Analyzer  1.22  the deletion doesn't happen anymore.
            Hide
            t_westling Tomas Westling added a comment - - edited

            Yes, the issue is in the Build Failure Analyzer v 1.23 and is present in every Jenkins version.

            I'm working on a fix.

            Show
            t_westling Tomas Westling added a comment - - edited Yes, the issue is in the Build Failure Analyzer v 1.23 and is present in every Jenkins version. I'm working on a fix.
            t_westling Tomas Westling made changes -
            Link This issue duplicates JENKINS-59593 [ JENKINS-59593 ]
            t_westling Tomas Westling made changes -
            Link This issue duplicates JENKINS-59593 [ JENKINS-59593 ]
            t_westling Tomas Westling made changes -
            Status In Progress [ 3 ] In Review [ 10005 ]
            Hide
            t_westling Tomas Westling added a comment -
            Show
            t_westling Tomas Westling added a comment - I have uploaded a fix here: https://github.com/jenkinsci/build-failure-analyzer-plugin/pull/112  
            Hide
            svut Soeren Uttrup added a comment - - edited

            Hi Tomas Westling
            When can i expect a plugin update to be ready for download ?

            Show
            svut Soeren Uttrup added a comment - - edited Hi Tomas Westling When can i expect a plugin update to be ready for download ?
            Hide
            t_westling Tomas Westling added a comment -

            I can't say for sure, but I am currently working on fixing some review comments.

            After the pull request is in, releasing a new version is quick work.

            Show
            t_westling Tomas Westling added a comment - I can't say for sure, but I am currently working on fixing some review comments. After the pull request is in, releasing a new version is quick work.
            ukphilj Philip Johnson made changes -
            Comment [ I wish I'd backed up that failure analyzer xml file. Dozens of causes lost :(. Anyone know if they'd be stored anywhere else? ]
            t_westling Tomas Westling made changes -
            Link This issue relates to JENKINS-59593 [ JENKINS-59593 ]
            t_westling Tomas Westling made changes -
            Released As 1.23.1
            Resolution Done [ 10000 ]
            Status In Review [ 10005 ] Closed [ 6 ]
            Hide
            svut Soeren Uttrup added a comment -

            Hi Tomas Westling
            Not able to upgrade to 1.23.1 only 1.23.0 available

            Show
            svut Soeren Uttrup added a comment - Hi Tomas Westling Not able to upgrade to 1.23.1 only 1.23.0 available
            Hide
            t_westling Tomas Westling added a comment -

            That is weird, but seems it has to be a problem on your end, since 1.23.1 is visible from all our Jenkins instances.

            When was the last "update information obtained" ? It has been in the update site for quite a while now.

            Show
            t_westling Tomas Westling added a comment - That is weird, but seems it has to be a problem on your end, since 1.23.1 is visible from all our Jenkins instances. When was the last "update information obtained" ? It has been in the update site for quite a while now.
            Hide
            svut Soeren Uttrup added a comment -

            You were right, I was not getting any updates.
            I have updated to 1.23.1 now and everything works fine.
            Thanks !

            Show
            svut Soeren Uttrup added a comment - You were right, I was not getting any updates. I have updated to 1.23.1 now and everything works fine. Thanks !
            Hide
            sgjenkins Steve Graham added a comment - - edited

            just noticed that ALL my build-failure-analysis reasons have been deleted, the xml file only contains the default.
            I upgraded to the Jenkins weekly 2.202 last week ( Oct 29th ).
            I did have build-analyser plugin version 1.24 installed.
            I'm trying to go back to the 1.23.1 version - but I guess its not going to get my failure reasons back again.
            I'm also fairly sure I didn't change the Global configuration.
            Is there a backup of the build-failuer-analyser.xml file ?
            ( I cancelled the uninstall of version 1.24 - it won't bring back my extensive database of failure reasons )

            Show
            sgjenkins Steve Graham added a comment - - edited just noticed that ALL my build-failure-analysis reasons have been deleted, the xml file only contains the default. I upgraded to the Jenkins weekly 2.202 last week ( Oct 29th ). I did have build-analyser plugin version 1.24 installed. I'm trying to go back to the 1.23.1 version - but I guess its not going to get my failure reasons back again. I'm also fairly sure I didn't change the Global configuration. Is there a backup of the build-failuer-analyser.xml file ? ( I cancelled the uninstall of version 1.24 - it won't bring back my extensive database of failure reasons )
            sgjenkins Steve Graham made changes -
            Resolution Done [ 10000 ]
            Status Closed [ 6 ] Reopened [ 4 ]
            Hide
            sgjenkins Steve Graham added a comment -

            I found an old version of the build-failuer-analyser.xml file from Oct 2018 and copied it. Reloaded the configuration from Disk but still can't see any entries in the Failure Cause Management view.

            Show
            sgjenkins Steve Graham added a comment - I found an old version of the build-failuer-analyser.xml file from Oct 2018 and copied it. Reloaded the configuration from Disk but still can't see any entries in the Failure Cause Management view.
            Hide
            n_o_a Nils Oliver Adam added a comment -

            You have to restart Jenkins. "Reload from Disk" doesn't do the Job in this case.

            Show
            n_o_a Nils Oliver Adam added a comment - You have to restart Jenkins. "Reload from Disk" doesn't do the Job in this case.
            Hide
            sgjenkins Steve Graham added a comment -

            ok - thanks. I got my build failure list from 1 year ago back again.
            BFA version is now 1.24. , jenkins is 2.202 ( just about to go up to 2.203 )
            I tried changing the global config and my build-failure list is still there.
            Relieved but still lost any additions I made in the last year.

            Show
            sgjenkins Steve Graham added a comment - ok - thanks. I got my build failure list from 1 year ago back again. BFA version is now 1.24. , jenkins is 2.202 ( just about to go up to 2.203 ) I tried changing the global config and my build-failure list is still there. Relieved but still lost any additions I made in the last year.
            Hide
            gordin Christoph Vogtländer added a comment -

            I just noticed that the configuration was removed in my instance a while back.  Just wanted to drop a note that if you happen to have the "build configuration history" plug-in installed, a backup of build-failure-analyzer.xml exists and can be restored to the exact version before the broken update (go to https://<yourserver>/jobConfigHistory/history?name=build-failure-analyzer)

            Show
            gordin Christoph Vogtländer added a comment - I just noticed that the configuration was removed in my instance a while back.  Just wanted to drop a note that if you happen to have the "build configuration history" plug-in installed, a backup of build-failure-analyzer.xml exists and can be restored to the exact version before the broken update (go to https://<yourserver>/jobConfigHistory/history?name=build-failure-analyzer)

              People

              Assignee:
              t_westling Tomas Westling
              Reporter:
              jbrejner1 Jens Brejner
              Votes:
              6 Vote for this issue
              Watchers:
              15 Start watching this issue

                Dates

                Created:
                Updated: