title: BUILD FAILURE in maven
body: <p>I am trying to build my <code>new-webapp</code> module using maven, and whenever I am doing <code>mvn install</code> from the command prompt using cygwin, it gives me this error - </p>
  
  <pre><code>$ mvn install
  [INFO] Scanning for projects...
  [INFO]
  [INFO] ------------------------------------------------------------------------
  [INFO] Building new-webapp MAIN
  [INFO] ------------------------------------------------------------------------
  [WARNING] The POM for com.parent:test-logic:jar:MAIN is missing, no dependency information available
  [INFO] ------------------------------------------------------------------------
  [INFO] BUILD FAILURE
  [INFO] ------------------------------------------------------------------------
  [INFO] Total time: 0.404s
  [INFO] Finished at: Tue Nov 19 22:19:10 PST 2013
  [INFO] Final Memory: 4M/243M
  [INFO] ------------------------------------------------------------------------
  [ERROR] Failed to execute goal on project new-webapp: Could not resolve dependencies for project com.parent:new-webapp:jar:MAIN: Failure to find com.parent:test-logic:jar:MAIN in http://caucho.com/m2-snapshot was cached in the local repository, resolution will not be reattempted until the update interval of caucho.maven-repo has elapsed or updates are forced -&gt; [Help 1]
  [ERROR]
  [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
  [ERROR] Re-run Maven using the -X switch to enable full debug logging.
  [ERROR]
  [ERROR] For more information about the errors and possible solutions, please read the following articles:
  [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/DependencyResolutionException
  </code></pre>
  
  <p>And this <code>new-webapp</code> module depends on couple more dependency and from the above error it strike me that I need to build - <code>com.parent:test-logic:jar</code> dependency as well and then only I can build my <code>new-webapp</code>.</p>
  
  <p>So I thought, I need to build that dependency (<code>com.parent:test-logic:jar</code>) first before doing <code>mvn install</code> on my <code>new-webapp</code>. So I went to my <code>test-logic</code> project and I ran the same command <code>mvn install</code> and this time I got different error and I am not sure how to fix that error -</p>
  
  <pre><code>[INFO] Cobertura 1.9.4.1 - GNU GPL License (NO WARRANTY) - See COPYRIGHT file
  Cobertura: Loaded information on 247 classes.
  
  [ERROR] com.parent.logic.exception.AlreadyLockedException failed check. Line coverage rate of 0.0% is below 80.0%
  com.parent.logic.util.LuaUtil$1 failed check. Line coverage rate of 0.0% is below 80.0%
  com.parent.logic.dao.impl.UrlDAOReadOnlyImpl failed check. Branch coverage rate of 0.0% is below 90.0%
  com.parent.logic.dao.impl.UrlDAOReadOnlyImpl failed check. Line coverage rate of 0.0% is below 80.0%
  com.parent.logic.service.CronService failed check. Branch coverage rate of 0.0% is below 90.0%
  com.parent.logic.service.CronService failed check. Line coverage rate of 0.0% is below 80.0%
  com.parent.logic.msg.client.AppStoreResponse failed check. Branch coverage rate of 0.0% is below 90.0%
  
  ----- some other errors like this
  
  Project failed check. Total branch coverage rate of 0.0% is below 85.0%
  Project failed check. Total line coverage rate of 0.0% is below 85.0%
  
  [INFO] ------------------------------------------------------------------------
  [INFO] BUILD FAILURE
  [INFO] ------------------------------------------------------------------------
  [INFO] Total time: 12.424s
  [INFO] Finished at: Tue Nov 19 22:18:42 PST 2013
  [INFO] Final Memory: 23M/249M
  [INFO] ------------------------------------------------------------------------
  [ERROR] Failed to execute goal org.codehaus.mojo:cobertura-maven-plugin:2.5.2:check (default) on project mac-core: Coverage check failed. See messages above. -&gt; [Help 1]
  [ERROR]
  [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
  [ERROR] Re-run Maven using the -X switch to enable full debug logging.
  [ERROR]
  [ERROR] For more information about the errors and possible solutions, please read the following articles:
  [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
  </code></pre>
  
  <p>This is related with some cobertura maven plugin error. My <code>test-logic</code> project is using cobertura plugin. So is there any way while doing <code>mvn install</code> on <code>test-logic</code> project, I can skip all these cobertura things and <code>test-logic</code> project gets build properly?</p>
  
  <p>If needed,I can provide the pom.xml file for <code>test-logic</code> project as well. if I can make this <code>test-logic</code> project build properly, then I might be able to build new-weabapp project as well.</p>
  
  <p>My main goal is to build new-webapp project properly using mvn install and whenever I do, it always gives me the above mentioned error.</p>
  
  <p>Any help on this would be really appreciated!!!
  Thanks.</p>
  
  <p><strong>UPDATE:-</strong></p>
  
  <p>I just checked my pom. test-logic project doesn't have any cobertura thing..</p>
  
  <p>Only my parent pom.xml has cobertura thing and it has two modules adeed, one for <code>new-webapp</code> and other for <code>logic</code>. Below is my pom.xml file - </p>
  
  <pre><code>&lt;project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
           xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"&gt;
     &lt;modelVersion&gt;4.0.0&lt;/modelVersion&gt;
     &lt;groupId&gt;com.parent&lt;/groupId&gt;
     &lt;artifactId&gt;test-parent&lt;/artifactId&gt;
     &lt;version&gt;MAIN&lt;/version&gt;
     &lt;packaging&gt;pom&lt;/packaging&gt;
     &lt;name&gt;Host-PC&lt;/name&gt;
  
     &lt;properties&gt;
        &lt;project.build.sourceEncoding&gt;UTF-8&lt;/project.build.sourceEncoding&gt;
        &lt;project.reporting.outputEncoding&gt;UTF-8&lt;/project.reporting.outputEncoding&gt;
        &lt;release.version&gt;MAIN&lt;/release.version&gt;
        &lt;cobertura.version&gt;1.9.4&lt;/cobertura.version&gt;
     &lt;/properties&gt;
  
     &lt;modules&gt;
        &lt;module&gt;logic&lt;/module&gt;
         &lt;module&gt;new-webapp&lt;/module&gt;
     &lt;/modules&gt;
  
     &lt;pluginRepositories&gt;
        &lt;pluginRepository&gt;
           &lt;id&gt;caucho&lt;/id&gt;
           &lt;name&gt;Caucho&lt;/name&gt;
           &lt;url&gt;http://caucho.com/m2-snapshot&lt;/url&gt;
        &lt;/pluginRepository&gt;
     &lt;/pluginRepositories&gt;
  
     &lt;repositories&gt;
        &lt;repository&gt;
           &lt;id&gt;caucho.maven-repo&lt;/id&gt;
           &lt;name&gt;Caucho Repository&lt;/name&gt;
           &lt;url&gt;http://caucho.com/m2-snapshot&lt;/url&gt;
        &lt;/repository&gt;
        &lt;repository&gt;
           &lt;id&gt;java.net-Public&lt;/id&gt;
           &lt;name&gt;Maven Java Net Snapshots and Releases&lt;/name&gt;
           &lt;url&gt;https://maven.java.net/content/groups/public/&lt;/url&gt;
        &lt;/repository&gt;
     &lt;/repositories&gt;
  
     &lt;dependencies&gt;
        &lt;dependency&gt;
           &lt;groupId&gt;com.caucho&lt;/groupId&gt;
           &lt;artifactId&gt;resin&lt;/artifactId&gt;
           &lt;version&gt;4.0-SNAPSHOT&lt;/version&gt;
           &lt;scope&gt;provided&lt;/scope&gt;
        &lt;/dependency&gt;
        &lt;dependency&gt;
           &lt;groupId&gt;com.caucho&lt;/groupId&gt;
           &lt;artifactId&gt;resin-javaee&lt;/artifactId&gt;
           &lt;version&gt;4.0-SNAPSHOT&lt;/version&gt;
           &lt;scope&gt;provided&lt;/scope&gt;
        &lt;/dependency&gt;
        &lt;dependency&gt;
           &lt;groupId&gt;javax.validation&lt;/groupId&gt;
           &lt;artifactId&gt;validation-api&lt;/artifactId&gt;
           &lt;version&gt;1.0.0.GA&lt;/version&gt;
           &lt;scope&gt;provided&lt;/scope&gt;
        &lt;/dependency&gt;
  
        &lt;dependency&gt;
           &lt;groupId&gt;javax.xml.bind&lt;/groupId&gt;
           &lt;artifactId&gt;jaxb-api&lt;/artifactId&gt;
           &lt;version&gt;2.2.4&lt;/version&gt;
        &lt;/dependency&gt;
  
        &lt;dependency&gt;
           &lt;groupId&gt;com.sun.xml.bind&lt;/groupId&gt;
           &lt;artifactId&gt;jaxb-impl&lt;/artifactId&gt;
           &lt;version&gt;2.2.4-1&lt;/version&gt;
        &lt;/dependency&gt;
  
        &lt;dependency&gt;
           &lt;groupId&gt;com.google.guava&lt;/groupId&gt;
           &lt;artifactId&gt;guava&lt;/artifactId&gt;
           &lt;version&gt;12.0&lt;/version&gt;
        &lt;/dependency&gt;
  
        &lt;dependency&gt;
           &lt;groupId&gt;org.slf4j&lt;/groupId&gt;
           &lt;artifactId&gt;slf4j-api&lt;/artifactId&gt;
           &lt;version&gt;1.7.5&lt;/version&gt;
        &lt;/dependency&gt;
        &lt;dependency&gt;
           &lt;groupId&gt;ch.qos.logback&lt;/groupId&gt;
           &lt;artifactId&gt;logback-classic&lt;/artifactId&gt;
           &lt;version&gt;1.0.13&lt;/version&gt;
        &lt;/dependency&gt;
        &lt;dependency&gt;
           &lt;groupId&gt;org.testng&lt;/groupId&gt;
           &lt;artifactId&gt;testng&lt;/artifactId&gt;
           &lt;version&gt;6.3&lt;/version&gt;
           &lt;scope&gt;test&lt;/scope&gt;
        &lt;/dependency&gt;
     &lt;/dependencies&gt;
  
     &lt;dependencyManagement&gt;
        &lt;dependencies&gt;
           &lt;dependency&gt;
              &lt;groupId&gt;com.parent&lt;/groupId&gt;
              &lt;artifactId&gt;test-logic&lt;/artifactId&gt;
              &lt;version&gt;${project.version}&lt;/version&gt;
           &lt;/dependency&gt;
        &lt;/dependencies&gt;
     &lt;/dependencyManagement&gt;
  
  
   &lt;profiles&gt;
        &lt;profile&gt;
           &lt;id&gt;cobertura-instrument&lt;/id&gt;
           &lt;activation&gt;
              &lt;property&gt;
                 &lt;name&gt;cobertura-build&lt;/name&gt;
              &lt;/property&gt;
           &lt;/activation&gt;
           &lt;modules&gt;
              &lt;module&gt;test-cobertura&lt;/module&gt;
           &lt;/modules&gt;
           &lt;build&gt;
              &lt;plugins&gt;
                 &lt;plugin&gt;
                    &lt;groupId&gt;org.codehaus.mojo&lt;/groupId&gt;
                    &lt;artifactId&gt;cobertura-maven-plugin&lt;/artifactId&gt;
                    &lt;version&gt;2.5.2&lt;/version&gt;
                    &lt;configuration&gt;
                    &lt;/configuration&gt;
                    &lt;executions&gt;
                       &lt;execution&gt;
                          &lt;id&gt;instrument-code&lt;/id&gt;
                          &lt;phase&gt;process-classes&lt;/phase&gt;
                          &lt;goals&gt;
                             &lt;goal&gt;instrument&lt;/goal&gt;
                          &lt;/goals&gt;
                          &lt;configuration&gt;
                             &lt;attach&gt;true&lt;/attach&gt;
                          &lt;/configuration&gt;
                       &lt;/execution&gt;
                    &lt;/executions&gt;
                 &lt;/plugin&gt;
                 &lt;plugin&gt;
                    &lt;groupId&gt;org.apache.maven.plugins&lt;/groupId&gt;
                    &lt;artifactId&gt;maven-source-plugin&lt;/artifactId&gt;
                    &lt;version&gt;2.2.1&lt;/version&gt;
                    &lt;executions&gt;
                       &lt;execution&gt;
                          &lt;id&gt;attach-sources&lt;/id&gt;
                          &lt;goals&gt;
                             &lt;goal&gt;jar&lt;/goal&gt;
                          &lt;/goals&gt;
                       &lt;/execution&gt;
                    &lt;/executions&gt;
                    &lt;inherited&gt;true&lt;/inherited&gt;
                 &lt;/plugin&gt;
              &lt;/plugins&gt;
           &lt;/build&gt;
           &lt;dependencies&gt;
              &lt;dependency&gt;
                 &lt;groupId&gt;net.sourceforge.cobertura&lt;/groupId&gt;
               &lt;artifactId&gt;cobertura-runtime&lt;/artifactId&gt;
                 &lt;version&gt;${cobertura.version}&lt;/version&gt;
                 &lt;scope&gt;provided&lt;/scope&gt;
                 &lt;type&gt;pom&lt;/type&gt;
              &lt;/dependency&gt;
           &lt;/dependencies&gt;
        &lt;/profile&gt;
     &lt;/profiles&gt;
  
  
     &lt;build&gt;
        &lt;finalName&gt;test-${project.version}-r${buildNumber}&lt;/finalName&gt;
        &lt;pluginManagement&gt;
           &lt;plugins&gt;
              &lt;plugin&gt;
                 &lt;groupId&gt;org.codehaus.mojo&lt;/groupId&gt;
                 &lt;artifactId&gt;buildnumber-maven-plugin&lt;/artifactId&gt;
                 &lt;version&gt;1.0&lt;/version&gt;
              &lt;/plugin&gt;
              &lt;plugin&gt;
                 &lt;groupId&gt;org.codehaus.mojo&lt;/groupId&gt;
                 &lt;artifactId&gt;cobertura-maven-plugin&lt;/artifactId&gt;
                 &lt;version&gt;2.5.2&lt;/version&gt;
              &lt;/plugin&gt;
           &lt;/plugins&gt;
        &lt;/pluginManagement&gt;
  
        &lt;plugins&gt;
           &lt;plugin&gt;
              &lt;groupId&gt;org.codehaus.mojo&lt;/groupId&gt;
              &lt;artifactId&gt;buildnumber-maven-plugin&lt;/artifactId&gt;
              &lt;version&gt;1.0&lt;/version&gt;
              &lt;executions&gt;
                 &lt;execution&gt;
                    &lt;phase&gt;validate&lt;/phase&gt;
                    &lt;goals&gt;
                       &lt;goal&gt;create&lt;/goal&gt;
                    &lt;/goals&gt;
                 &lt;/execution&gt;
              &lt;/executions&gt;
              &lt;configuration&gt;
                 &lt;useLastCommittedRevision&gt;true&lt;/useLastCommittedRevision&gt;
                 &lt;scmDirectory&gt;${project.parent.basedir}&lt;/scmDirectory&gt;
                 &lt;doCheck&gt;false&lt;/doCheck&gt;
                 &lt;doUpdate&gt;false&lt;/doUpdate&gt;
              &lt;/configuration&gt;
           &lt;/plugin&gt;
           &lt;plugin&gt;
              &lt;groupId&gt;org.apache.felix&lt;/groupId&gt;
              &lt;artifactId&gt;maven-bundle-plugin&lt;/artifactId&gt;
              &lt;version&gt;2.3.6&lt;/version&gt;
              &lt;executions&gt;
                 &lt;execution&gt;
                    &lt;id&gt;bundle-manifest&lt;/id&gt;
                    &lt;phase&gt;process-resources&lt;/phase&gt;
                    &lt;goals&gt;
                       &lt;goal&gt;manifest&lt;/goal&gt;
                    &lt;/goals&gt;
                 &lt;/execution&gt;
              &lt;/executions&gt;
              &lt;configuration&gt;
                 &lt;supportedProjectTypes&gt;
                    &lt;supportedProjectType&gt;jar&lt;/supportedProjectType&gt;
                    &lt;supportedProjectType&gt;bundle&lt;/supportedProjectType&gt;
                    &lt;supportedProjectType&gt;war&lt;/supportedProjectType&gt;
                 &lt;/supportedProjectTypes&gt;
                 &lt;instructions&gt;
                    &lt;Build-version&gt;${buildNumber}&lt;/Build-version&gt;
                 &lt;/instructions&gt;
              &lt;/configuration&gt;
           &lt;/plugin&gt;
           &lt;plugin&gt;
              &lt;groupId&gt;org.codehaus.mojo&lt;/groupId&gt;
              &lt;artifactId&gt;cobertura-maven-plugin&lt;/artifactId&gt;
              &lt;version&gt;2.5.2&lt;/version&gt;
              &lt;configuration&gt;
                 &lt;instrumentation&gt;
                    &lt;includes&gt;
                       &lt;include&gt;com/parent/**/*.class&lt;/include&gt;
                    &lt;/includes&gt;
                    &lt;!--
                    &lt;ignores&gt;
                       &lt;ignore&gt;com.example.boringcode.*&lt;/ignore&gt;
                    &lt;/ignores&gt;
                    --&gt;
                    &lt;!--
                    &lt;excludes&gt;
                       &lt;exclude&gt;com/example/dullcode/**/*.class&lt;/exclude&gt;
                       &lt;exclude&gt;com/example/**/*Test.class&lt;/exclude&gt;
                    &lt;/excludes&gt;
                    --&gt;
                 &lt;/instrumentation&gt;
                 &lt;check&gt;
                    &lt;branchRate&gt;85&lt;/branchRate&gt;
                    &lt;lineRate&gt;85&lt;/lineRate&gt;
                    &lt;haltOnFailure&gt;true&lt;/haltOnFailure&gt;
                    &lt;totalBranchRate&gt;85&lt;/totalBranchRate&gt;
                    &lt;totalLineRate&gt;85&lt;/totalLineRate&gt;
                    &lt;packageLineRate&gt;85&lt;/packageLineRate&gt;
                    &lt;packageBranchRate&gt;85&lt;/packageBranchRate&gt;
                    &lt;regexes&gt;
                       &lt;regex&gt;
                          &lt;pattern&gt;com.parent.*&lt;/pattern&gt;
                          &lt;branchRate&gt;90&lt;/branchRate&gt;
                          &lt;lineRate&gt;80&lt;/lineRate&gt;
                       &lt;/regex&gt;
                    &lt;/regexes&gt;
                 &lt;/check&gt;
              &lt;/configuration&gt;
              &lt;executions&gt;
                 &lt;execution&gt;
                    &lt;goals&gt;
                       &lt;goal&gt;clean&lt;/goal&gt;
                       &lt;goal&gt;check&lt;/goal&gt;
                    &lt;/goals&gt;
                 &lt;/execution&gt;
              &lt;/executions&gt;
           &lt;/plugin&gt;
        &lt;/plugins&gt;
     &lt;/build&gt;
  
     &lt;reporting&gt;
        &lt;plugins&gt;
           &lt;plugin&gt;
              &lt;groupId&gt;org.codehause.mojo&lt;/groupId&gt;
              &lt;artifactId&gt;codertura-maven-plugin&lt;/artifactId&gt;
              &lt;version&gt;2.5.2&lt;/version&gt;
              &lt;configuration&gt;
                 &lt;formats&gt;
                    &lt;format&gt;html&lt;/format&gt;
                    &lt;format&gt;xml&lt;/format&gt;
                 &lt;/formats&gt;
              &lt;/configuration&gt;
           &lt;/plugin&gt;
        &lt;/plugins&gt;
     &lt;/reporting&gt;
  
  
  &lt;/project&gt;
  </code></pre>