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

No matrix trigger mode in extendedEmail in multi configuration - Jenkins DSL

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • job-dsl-plugin
    • Jenkins(ver. 2.222.1)
      Jenkins DSL plugin((v1.77)
      extendedEmail plugin(v2.69)

      We use multi configuration project on Jenkins(ver. 2.222.1) We use JenkinsDSL(v1.77) to create the free-style jobs from the groovy scripts. Email notifications is with extendedEmail(v2.69)
      It seems like trigger mode for notifications cannot be specified in the groovy script but it could be done via the UI as below(ONLY_PARENT or ONLY_CONFIGURATIONS or BOTH

      As I see we could specify for extendedEmail in groovy for DSL plugin as below

       

      job('example') {
          publishers {
              extendedEmail {
                  recipientList('me@halfempty.org')
                  defaultSubject('Oops')
                  defaultContent('Something broken')
                  contentType('text/html')
                  triggers {
                      beforeBuild()
                      stillUnstable {
                          subject('Subject')
                          content('Body')
                          sendTo {
                              developers()
                              requester()
                              culprits()
                          }
                      }
                  }
              }
          }
      }

      I was wondering if we had something similar to hipChatNotifier as below ( matrixTriggerMode('ONLY_PARENT'))

       

      job('example') {
        publishers {
          hipChatNotifier {
            room('Dev Team A, QA')
            matrixTriggerMode('ONLY_PARENT')
            startJobMessage(null)
            completeJobMessage(null)
            token(null)
            notifications {
              notificationConfig {
                notifyEnabled(true)
                textFormat(true)
                notificationType('ABORTED')
                color('GRAY')
                messageTemplate(null)
              }

      How do I achieve it for extendedEmail? As I could do the same via the UI 

       

          [JENKINS-64574] No matrix trigger mode in extendedEmail in multi configuration - Jenkins DSL

          Anudeep created issue -
          Anudeep made changes -
          Description Original: We use multi configuration project on Jenkins(ver. 2.222.1) We use JenkinsDSL(v1.77) to create the free-style jobs from the groovy scripts. Email notifications is with extendedEmail(v2.69)
          It seems like trigger mode for notifications cannot be specified in the groovy script but it could be done via the UI as below(*ONLY_PARENT or ONLY_CONFIGURATIONS or BOTH*) 


          As I see we could specify for extendedEmail in groovy for DSL plugin as below

           
          {noformat}
          job('example') {
              publishers {
                  extendedEmail {
                      recipientList('me@halfempty.org')
                      defaultSubject('Oops')
                      defaultContent('Something broken')
                      contentType('text/html')
                      triggers {
                          beforeBuild()
                          stillUnstable {
                              subject('Subject')
                              content('Body')
                              sendTo {
                                  developers()
                                  requester()
                                  culprits()
                              }
                          }
                      }
                  }
              }
          }{noformat}
          I was wondering if we had something similar to hipChatNotifier as below ( *matrixTriggerMode('ONLY_PARENT')*)

           
          {noformat}
          job('example') {
            publishers {
              hipChatNotifier {
                room('Dev Team A, QA')
                matrixTriggerMode('ONLY_PARENT')
                startJobMessage(null)
                completeJobMessage(null)
                token(null)
                notifications {
                  notificationConfig {
                    notifyEnabled(true)
                    textFormat(true)
                    notificationType('ABORTED')
                    color('GRAY')
                    messageTemplate(null)
                  }{noformat}
          How do I achieve it for extendedEmail? As I could do the same via the UI 

           
          New: We use multi configuration project on Jenkins(ver. 2.222.1) We use JenkinsDSL(v1.77) to create the free-style jobs from the groovy scripts. Email notifications is with extendedEmail(v2.69)
           It seems like trigger mode for notifications cannot be specified in the groovy script but it could be done via the UI as below(*ONLY_PARENT or ONLY_CONFIGURATIONS or BOTH*) 

          !JenkinsEmailext-1.png|thumbnail!

          As I see we could specify for extendedEmail in groovy for DSL plugin as below

           
          {noformat}
          job('example') {
              publishers {
                  extendedEmail {
                      recipientList('me@halfempty.org')
                      defaultSubject('Oops')
                      defaultContent('Something broken')
                      contentType('text/html')
                      triggers {
                          beforeBuild()
                          stillUnstable {
                              subject('Subject')
                              content('Body')
                              sendTo {
                                  developers()
                                  requester()
                                  culprits()
                              }
                          }
                      }
                  }
              }
          }{noformat}
          I was wondering if we had something similar to hipChatNotifier as below ( *matrixTriggerMode('ONLY_PARENT')*)

           
          {noformat}
          job('example') {
            publishers {
              hipChatNotifier {
                room('Dev Team A, QA')
                matrixTriggerMode('ONLY_PARENT')
                startJobMessage(null)
                completeJobMessage(null)
                token(null)
                notifications {
                  notificationConfig {
                    notifyEnabled(true)
                    textFormat(true)
                    notificationType('ABORTED')
                    color('GRAY')
                    messageTemplate(null)
                  }{noformat}
          How do I achieve it for extendedEmail? As I could do the same via the UI 

           
          Anudeep made changes -
          Description Original: We use multi configuration project on Jenkins(ver. 2.222.1) We use JenkinsDSL(v1.77) to create the free-style jobs from the groovy scripts. Email notifications is with extendedEmail(v2.69)
           It seems like trigger mode for notifications cannot be specified in the groovy script but it could be done via the UI as below(*ONLY_PARENT or ONLY_CONFIGURATIONS or BOTH*) 

          !JenkinsEmailext-1.png|thumbnail!

          As I see we could specify for extendedEmail in groovy for DSL plugin as below

           
          {noformat}
          job('example') {
              publishers {
                  extendedEmail {
                      recipientList('me@halfempty.org')
                      defaultSubject('Oops')
                      defaultContent('Something broken')
                      contentType('text/html')
                      triggers {
                          beforeBuild()
                          stillUnstable {
                              subject('Subject')
                              content('Body')
                              sendTo {
                                  developers()
                                  requester()
                                  culprits()
                              }
                          }
                      }
                  }
              }
          }{noformat}
          I was wondering if we had something similar to hipChatNotifier as below ( *matrixTriggerMode('ONLY_PARENT')*)

           
          {noformat}
          job('example') {
            publishers {
              hipChatNotifier {
                room('Dev Team A, QA')
                matrixTriggerMode('ONLY_PARENT')
                startJobMessage(null)
                completeJobMessage(null)
                token(null)
                notifications {
                  notificationConfig {
                    notifyEnabled(true)
                    textFormat(true)
                    notificationType('ABORTED')
                    color('GRAY')
                    messageTemplate(null)
                  }{noformat}
          How do I achieve it for extendedEmail? As I could do the same via the UI 

           
          New: We use multi configuration project on Jenkins(ver. 2.222.1) We use JenkinsDSL(v1.77) to create the free-style jobs from the groovy scripts. Email notifications is with extendedEmail(v2.69)
           It seems like trigger mode for notifications cannot be specified in the groovy script but it could be done via the UI as below(*ONLY_PARENT or ONLY_CONFIGURATIONS or BOTH*) 

          !JenkinsEmailext-1.png|width=915,height=151,thumbnail!

          As I see we could specify for extendedEmail in groovy for DSL plugin as below

           
          {noformat}
          job('example') {
              publishers {
                  extendedEmail {
                      recipientList('me@halfempty.org')
                      defaultSubject('Oops')
                      defaultContent('Something broken')
                      contentType('text/html')
                      triggers {
                          beforeBuild()
                          stillUnstable {
                              subject('Subject')
                              content('Body')
                              sendTo {
                                  developers()
                                  requester()
                                  culprits()
                              }
                          }
                      }
                  }
              }
          }{noformat}
          I was wondering if we had something similar to hipChatNotifier as below ( *matrixTriggerMode('ONLY_PARENT')*)

           
          {noformat}
          job('example') {
            publishers {
              hipChatNotifier {
                room('Dev Team A, QA')
                matrixTriggerMode('ONLY_PARENT')
                startJobMessage(null)
                completeJobMessage(null)
                token(null)
                notifications {
                  notificationConfig {
                    notifyEnabled(true)
                    textFormat(true)
                    notificationType('ABORTED')
                    color('GRAY')
                    messageTemplate(null)
                  }{noformat}
          How do I achieve it for extendedEmail? As I could do the same via the UI 

           
          Jamie Tanna made changes -
          Assignee Original: Daniel Spilker [ daspilker ] New: Jamie Tanna [ jamietanna ]
          Alex Earl made changes -
          Component/s Original: email-ext-plugin [ 15538 ]

            jamietanna Jamie Tanna
            anudeepmk Anudeep
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: