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

Jenkins job created by seed job using jobdsl script does't shows JMS message checks on job UI.

    • Icon: Task Task
    • Resolution: Won't Fix
    • Icon: Minor Minor
    • jms-messaging-plugin
    • None
    • jenkins version : 2.156 and 2.174

      job DSL Version : 1.72
      JMS version : 1.1.4

      I have Jenkins seed job which include DSL script for creating new jobs.

      in which i have passed JMS message checks, when seed job triggers it created job but not showing message checks on job UI, but it shows message checks in job/config.xml 

       

      DSL script includes following : 

      • checks {
      • msgCheck {
      • field(String value)
      • expectedValue(String value)}}
      • name(String value)
      • overrides { * [topic|https://platform-stg-jenkins.rhev-ci-vms.eng.rdu2.redhat.com/plugin/job-dsl/api-viewer/index.html#path/job-steps-ciMessageSubscriberBuilder-providerData-activeMQSubscriberProviderData-overrides-topic](String value)}
      • // JMS selector to choose messages that will fire the trigger.selector(String value) 

       

       

      Please see the attachment

        1. image-2019-05-24-10-32-46-026.png
          image-2019-05-24-10-32-46-026.png
          182 kB
        2. image-2019-05-24-10-29-04-077.png
          image-2019-05-24-10-29-04-077.png
          66 kB
        3. image-2019-05-24-10-28-55-246.png
          image-2019-05-24-10-28-55-246.png
          125 kB
        4. message-checks.png
          message-checks.png
          143 kB
        5. job_config.png
          job_config.png
          104 kB
        6. created-job_ui.png
          created-job_ui.png
          45 kB
        7. dsl_script.png
          dsl_script.png
          78 kB

          [JENKINS-57581] Jenkins job created by seed job using jobdsl script does't shows JMS message checks on job UI.

          sachin pathare created issue -
          Scott Hebert made changes -
          Attachment New: message-checks.png [ 47493 ]

          Scott Hebert added a comment -

          I was not able to reproduce your issue.

          Here is the script I was using:

          pipelineJob("trigger") {
          
              definition {
          
                  parameters {
                      stringParam('CI_MESSAGE', '', 'contents of message')
                  }
          
                  triggers {
                      ciBuildTrigger {
                          providerData {
                              activeMQSubscriberProviderData {
                                  name("UMB")
                                  overrides {
                                      topic("Consumer.rh-jenkins-ci-plugin.8dad9900-abcdef.VirtualTopic.eng.brew.build.complete")
                                  }
                                  checks {
                                      msgCheck {
                                          field('$.info.extra.container_koji_task_id')
                                          expectedValue("\\d+")
                                      }
                                  }
                                  selector("mtype = 'scott'")
                              }
                          }
                          noSquash(true)
                      }
                  }
          
                  cps {
                      sandbox(false)
                      script("""
          node('master') {
            echo CI_MESSAGE
          }
          """)
                  }
              }
          }
          

          Here is my job config:

          Scott Hebert added a comment - I was not able to reproduce your issue. Here is the script I was using: pipelineJob( "trigger" ) { definition { parameters { stringParam( 'CI_MESSAGE' , '', ' contents of message') } triggers { ciBuildTrigger { providerData { activeMQSubscriberProviderData { name( "UMB" ) overrides { topic( "Consumer.rh-jenkins-ci-plugin.8dad9900-abcdef.VirtualTopic.eng.brew.build.complete" ) } checks { msgCheck { field( '$.info.extra.container_koji_task_id' ) expectedValue( "\\d+" ) } } selector( "mtype = 'scott' " ) } } noSquash( true ) } } cps { sandbox( false ) script(""" node( 'master' ) { echo CI_MESSAGE } """) } } } Here is my job config:
          Scott Hebert made changes -
          Resolution New: Cannot Reproduce [ 5 ]
          Status Original: Open [ 1 ] New: Resolved [ 5 ]

          sachin pathare added a comment - - edited

          scoheb,

          your using a Pipline script and I am using DSL script to create job, On my side also it shows in config.xml  file but not on the JOB UI. 

           

          See attachment

           

           

          Created job does't shows that mesg checks on the UI but it does shows in config.xml file : 

           

           

           

           

          Config.xml file for job shows mesg checks :

           

           

          sachin pathare added a comment - - edited scoheb , your using a Pipline script and I am using DSL script to create job, On my side also it shows in config.xml  file but not on the JOB UI.    See attachment     Created job does't shows that mesg checks on the UI but it does shows in config.xml file :          Config.xml file for job shows mesg checks :    
          sachin pathare made changes -
          Attachment New: image-2019-05-24-10-23-48-581.png [ 47498 ]
          sachin pathare made changes -
          Attachment New: image-2019-05-24-10-25-04-003.png [ 47499 ]
          sachin pathare made changes -
          Attachment New: image-2019-05-24-10-29-04-077.png [ 47500 ]
          Attachment New: image-2019-05-24-10-28-55-246.png [ 47501 ]
          sachin pathare made changes -
          Attachment Original: image-2019-05-24-10-23-48-581.png [ 47498 ]
          sachin pathare made changes -
          Attachment Original: image-2019-05-24-10-25-04-003.png [ 47499 ]

            scoheb Scott Hebert
            spathare sachin pathare
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: