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

regression: parameters not set if build triggered by fstrigger 0.41

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • fstrigger-plugin
    • Jenkins 2.277.4 (linux, openjdk version "1.8.0_292")
      fs trigger 0.41
      (full list of plugins in attachments)
    • fstrigger-plugin 0.42

      Symptoms:

      When a job gets triggered via fstrigger 0.41, default values from parameters are not used, the parameters are empty, the build fails. environmentVariables are working, though (see output_0.41-fstrigger-failure.txt)

      If the same job gets manually triggered via "BuildWithParameters", this works (see output-0.41-buildWithParameters.txt)

      The same job works flawlessly with fstrigger 0.39 (see output_0.39_fstrigger-success.txt) with otherwise same jenkins and other plugins versions (compare plugin_list_fstrigger-0.39.txtplugin_list_fstrigger-0.41.txt)

      How to reproduce:

      Use attached jobdsl debug.groovy to create a job. Trigger via placing a file in /tmp/test. It will fail with fstrigger 0.41, and succeed with fstrigger 0.39.

       

      Further notes:

      0.41 fixed https://issues.jenkins.io/browse/JENKINS-64229 and an issue with editing/saving freestyle jobs in the GUI for us, but introduced this issue. Since no other components changed, and this works when reverting to 0.39, i assume this is a regression.

       

      Thanks for you work on this very useful plugin!

      Please let me know if I can be of any assistance in analysing this issue further.

       

       

       

          [JENKINS-65661] regression: parameters not set if build triggered by fstrigger 0.41

          DS added a comment -

          DS added a comment - potentially related to: https://github.com/jenkinsci/fstrigger-plugin/issues/12

          Tony Noble added a comment -

          Hi compuglobalhypermeganet_vp ,

          Thanks for the detailed write-up.  This seems to have manifested in the URLTrigger plugin as well, which makes me think the underlying XTrigger-Lib is at fault (between 0.39 and 0.41, xtrigger dependency was increased from 0.29 to 0.34).

          I'll have a look and see if I can narrow down the issue.

          Tony

          Tony Noble added a comment - Hi compuglobalhypermeganet_vp , Thanks for the detailed write-up.  This seems to have manifested in the URLTrigger plugin as well, which makes me think the underlying XTrigger-Lib is at fault (between 0.39 and 0.41, xtrigger dependency was increased from 0.29 to 0.34). I'll have a look and see if I can narrow down the issue. Tony

          Tony Noble added a comment -

          Further update: This appears to tie-in with the move from using AbstractProject to run Run when setting up the triggered job in XTrigger, as required by newer versions of Jenkins.  Not a regression as such, just the method of scheduling needs to be amended to set the default parameters (sounds simpler than it is).

          Tony Noble added a comment - Further update: This appears to tie-in with the move from using AbstractProject to run Run when setting up the triggered job in XTrigger, as required by newer versions of Jenkins.  Not a regression as such, just the method of scheduling needs to be amended to set the default parameters (sounds simpler than it is).

          James added a comment -

          Experiencing the same issue but when downgrading to version 0.39 the parameters are generated. But I have an additional issue on version 0.39.  When using version 0.39 after selecting configure for a job the tabs across the top  only the first 3 appear.

                   General  Source Code Management  Build Triggers  Build Environment  Build  Post-build Actions 

           

          It appears all elements are available  to configure. Just a bit confusing.

           

          Any help would be appreciated.

          James added a comment - Experiencing the same issue but when downgrading to version 0.39 the parameters are generated. But I have an additional issue on version 0.39.  When using version 0.39 after selecting configure for a job the tabs across the top  only the first 3 appear.           General  Source Code Management  Build Triggers   Build Environment  Build  Post-build Actions    It appears all elements are available  to configure. Just a bit confusing.   Any help would be appreciated.

          James added a comment -

          And the rest of the story, Using Jenkins 2.289.3 but version 0.039 does not allow to save or apply any changes or create new jobs using the configure page. Basically the plugin messes up the UI but if already configured does allow the parameters to be passed. 

          James added a comment - And the rest of the story, Using Jenkins 2.289.3 but version 0.039 does not allow to save or apply any changes or create new jobs using the configure page. Basically the plugin messes up the UI but if already configured does allow the parameters to be passed. 

          James added a comment -

          and one final update the plugin does pick up the file or folder changes.  

          James added a comment - and one final update the plugin does pick up the file or folder changes.  

          DS added a comment -

          Hi stealthdj,

          > the method of scheduling needs to be amended to set the default parameters (sounds simpler than it is).
          I assume there are no updates here?

          Due to this issue, we're still stuck with 0.39, which means we are affected by:

          Any proposal for a workaround in the meantime?

          Thanks for all the effort you put into this plugin!

          Best regards.

           

           

          DS added a comment - Hi stealthdj , > the method of scheduling needs to be amended to set the default parameters (sounds simpler than it is). I assume there are no updates here? Due to this issue, we're still stuck with 0.39, which means we are affected by: XXE vulnerability and https://issues.jenkins.io/browse/JENKINS-64229 and the issue with editing/saving freestyle jobs in the GUI (which have been fixed in 0.41) Any proposal for a workaround in the meantime? Thanks for all the effort you put into this plugin! Best regards.    

          Tony Noble added a comment -

          Hi compuglobalhypermeganet_vp

          Apologies - time has been somewhat lacking to try and resolve this.  There have been some fairly significant changes under the hood regarding how Jenkins represents jobs and builds and this is an artifact of that.  It's also not as simple a fix as I might have hoped.

          I'll try to get some time to work on the required changes.  In the meantime, all I could suggest is to code the defaults into the job if the parameters are not set.  Not an ideal scenario, I admit - I'll have another go at figuring this one out.

          Tony

          Tony Noble added a comment - Hi compuglobalhypermeganet_vp Apologies - time has been somewhat lacking to try and resolve this.  There have been some fairly significant changes under the hood regarding how Jenkins represents jobs and builds and this is an artifact of that.  It's also not as simple a fix as I might have hoped. I'll try to get some time to work on the required changes.  In the meantime, all I could suggest is to code the defaults into the job if the parameters are not set.  Not an ideal scenario, I admit - I'll have another go at figuring this one out. Tony

          Tony Noble added a comment -

          compuglobalhypermeganet_vp - Finally managed to find the magic combination to fix xtrigger-lib and have release fstrigger-0.42, which should resolve the default parameter issue.

          Tony Noble added a comment - compuglobalhypermeganet_vp - Finally managed to find the magic combination to fix xtrigger-lib and have release fstrigger-0.42, which should resolve the default parameter issue.

          DS added a comment -

          stealthdj Works like a charm - thank you very much for your continued efforts!

          DS added a comment - stealthdj Works like a charm - thank you very much for your continued efforts!

            stealthdj Tony Noble
            compuglobalhypermeganet_vp DS
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: