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

No e-mail when maven fails before a build starts

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Critical
    • Resolution: Fixed
    • Component/s: maven-plugin
    • Labels:
      None
    • Environment:
      Platform: All, OS: Linux
    • Similar Issues:

      Description

      Hudson does not send failure e-mails when maven fails to validate a pom (easy to
      reproduce by using a random text file as a pom).
      This might be a maven embedder issue, but the shell command does return 1 (at
      least for maven 2.0.8).

      (this is on unix, no idea about whether this works on windows)

        Attachments

          Issue Links

            Activity

            Hide
            abayer Andrew Bayer added a comment -

            Taking issue. Should be fixed in 1.324 - I added a call to MailSender
            (conditional on MavenMailer being configured for the project) in the cleanUp
            method at the top-level MavenModuleSetBuild.RunnerImpl, so that we actually get
            an email for the entire Maven project, not just one per module. That said,
            email-ext does the trick on this too.

            Show
            abayer Andrew Bayer added a comment - Taking issue. Should be fixed in 1.324 - I added a call to MailSender (conditional on MavenMailer being configured for the project) in the cleanUp method at the top-level MavenModuleSetBuild.RunnerImpl, so that we actually get an email for the entire Maven project, not just one per module. That said, email-ext does the trick on this too.
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in hudson
            User: : abayer
            Path:
            trunk/hudson/main/maven-plugin/src/main/java/hudson/maven/MavenModuleSetBuild.java
            http://fisheye4.cenqua.com/changelog/hudson/?cs=21509
            Log:
            [FIXED JENKINS-1066] Added call to MailSender in RunnerImpl.cleanUp so that mail gets sent for top-level Maven project as well as individual modules. Also, William the Conqueror won the Battle of Hastings in 1066. Just thought I'd mention that.

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in hudson User: : abayer Path: trunk/hudson/main/maven-plugin/src/main/java/hudson/maven/MavenModuleSetBuild.java http://fisheye4.cenqua.com/changelog/hudson/?cs=21509 Log: [FIXED JENKINS-1066] Added call to MailSender in RunnerImpl.cleanUp so that mail gets sent for top-level Maven project as well as individual modules. Also, William the Conqueror won the Battle of Hastings in 1066. Just thought I'd mention that.
            Hide
            skybird Florian Rosenauer added a comment -
                • Issue 3955 has been marked as a duplicate of this issue. ***
            Show
            skybird Florian Rosenauer added a comment - Issue 3955 has been marked as a duplicate of this issue. ***
            Hide
            rajpra rajpra added a comment -

            Can this fix please be optional?
            we use subversion and now for some reason when a poll is done and even when nothing in subversion has changed a email is trigger if the subversion server cannot be reached.

            from time to time due to network issues. planned and unplanned maintance on the network and or dns server, subversion will not be reachable (mainly on weekends)
            if the svn server cannot be reached we do not want a email triggered.
            over the weekend this caused over 5000 emails over 1.5 days sent to developers who now thing hudson is a buggy system.

            error:

            Started by an SCM change
            Building remotely on RHEL5.2_x86_64VM1
            Updating http://subversion/dev/project/trunk
            ERROR: Failed to update http://subversion/dev/project/trunk
            org.tmatesoft.svn.core.SVNException: svn: unknown host
            svn: OPTIONS request failed on '/dev/project/trunk'
            at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:103)
            at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:87)
            at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:616)
            at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:273)
            at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:261)
            at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.exchangeCapabilities(DAVConnection.java:516)
            at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.open(DAVConnection.java:98)
            at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.openConnection(DAVRepository.java:1001)
            at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.getRepositoryUUID(DAVRepository.java:146)
            at org.tmatesoft.svn.core.wc.SVNBasicClient.createRepository(SVNBasicClient.java:342)
            at org.tmatesoft.svn.core.wc.SVNBasicClient.createRepository(SVNBasicClient.java:330)
            at org.tmatesoft.svn.core.wc.SVNUpdateClient.update(SVNUpdateClient.java:535)
            at org.tmatesoft.svn.core.wc.SVNUpdateClient.doUpdate(SVNUpdateClient.java:401)
            at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:699)
            at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:660)
            at hudson.FilePath$FileCallableWrapper.call(FilePath.java:2018)
            at hudson.remoting.UserRequest.perform(UserRequest.java:69)
            at hudson.remoting.UserRequest.perform(UserRequest.java:23)
            at hudson.remoting.Request$2.run(Request.java:213)
            at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
            at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
            at java.util.concurrent.FutureTask.run(FutureTask.java:138)
            at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
            at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
            at java.lang.Thread.run(Thread.java:619)
            Caused by: java.net.UnknownHostException: svnglobal
            at java.net.InetAddress.getAllByName0(InetAddress.java:1157)
            at java.net.InetAddress.getAllByName(InetAddress.java:1083)
            at java.net.InetAddress.getAllByName(InetAddress.java:1019)
            at java.net.InetAddress.getByName(InetAddress.java:969)
            at org.tmatesoft.svn.core.internal.util.SVNSocketFactory.createAddres(SVNSocketFactory.java:132)
            at org.tmatesoft.svn.core.internal.util.SVNSocketFactory.createPlainSocket(SVNSocketFactory.java:54)
            at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.connect(HTTPConnection.java:183)
            at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:323)
            ... 22 more

            Show
            rajpra rajpra added a comment - Can this fix please be optional? we use subversion and now for some reason when a poll is done and even when nothing in subversion has changed a email is trigger if the subversion server cannot be reached. from time to time due to network issues. planned and unplanned maintance on the network and or dns server, subversion will not be reachable (mainly on weekends) if the svn server cannot be reached we do not want a email triggered. over the weekend this caused over 5000 emails over 1.5 days sent to developers who now thing hudson is a buggy system. error: Started by an SCM change Building remotely on RHEL5.2_x86_64VM1 Updating http://subversion/dev/project/trunk ERROR: Failed to update http://subversion/dev/project/trunk org.tmatesoft.svn.core.SVNException: svn: unknown host svn: OPTIONS request failed on '/dev/project/trunk' at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:103) at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:87) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:616) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:273) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:261) at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.exchangeCapabilities(DAVConnection.java:516) at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.open(DAVConnection.java:98) at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.openConnection(DAVRepository.java:1001) at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.getRepositoryUUID(DAVRepository.java:146) at org.tmatesoft.svn.core.wc.SVNBasicClient.createRepository(SVNBasicClient.java:342) at org.tmatesoft.svn.core.wc.SVNBasicClient.createRepository(SVNBasicClient.java:330) at org.tmatesoft.svn.core.wc.SVNUpdateClient.update(SVNUpdateClient.java:535) at org.tmatesoft.svn.core.wc.SVNUpdateClient.doUpdate(SVNUpdateClient.java:401) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:699) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:660) at hudson.FilePath$FileCallableWrapper.call(FilePath.java:2018) at hudson.remoting.UserRequest.perform(UserRequest.java:69) at hudson.remoting.UserRequest.perform(UserRequest.java:23) at hudson.remoting.Request$2.run(Request.java:213) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) at java.util.concurrent.FutureTask.run(FutureTask.java:138) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907) at java.lang.Thread.run(Thread.java:619) Caused by: java.net.UnknownHostException: svnglobal at java.net.InetAddress.getAllByName0(InetAddress.java:1157) at java.net.InetAddress.getAllByName(InetAddress.java:1083) at java.net.InetAddress.getAllByName(InetAddress.java:1019) at java.net.InetAddress.getByName(InetAddress.java:969) at org.tmatesoft.svn.core.internal.util.SVNSocketFactory.createAddres(SVNSocketFactory.java:132) at org.tmatesoft.svn.core.internal.util.SVNSocketFactory.createPlainSocket(SVNSocketFactory.java:54) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.connect(HTTPConnection.java:183) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:323) ... 22 more
            Hide
            kutzi kutzi added a comment -

            rajpra what you seem to be referring to is more related to issue like JENKINS-10173 or JENKINS-763

            PS: I think subversion checkout error should be handled as build errors!

            Show
            kutzi kutzi added a comment - rajpra what you seem to be referring to is more related to issue like JENKINS-10173 or JENKINS-763 PS: I think subversion checkout error should be handled as build errors!

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              el_1972 el_1972
              Votes:
              2 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: