# Maven build error on DataMart

**URL:** <https://community.dhis2.org/t/maven-build-error-on-datamart/17237>\
**Category:** Support - Assistance technique\
**Created:** [27 October 2012 08:09 UTC](https://community.dhis2.org/t/maven-build-error-on-datamart/17237 "2012-10-27T08:09:14Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![jamesc](https://dhis2.b-cdn.net/letter_avatar_proxy/v4/letter/j/bc8723/32.png) [@jamesc](https://community.dhis2.org/u/jamesc)\
**Post date:** [27 October 2012 08:09 UTC](https://community.dhis2.org/t/maven-build-error-on-datamart/17237/1 "2012-10-27T08:09:14Z")

</div>

Hi,

I am trying to get the Dhis2 development environment setup, but having problem making a successful project build using Maven.

Could someone give me some help on this?

I am not suppose to do this on Windows 7 64bit?

I am using Windows 7 OS 64bit, Bazaar 2.5.1-1, JDK 1.7.0\_09, apache-maven-2.2.1

Followed ‘[http://dhis2.org/development](http://dhis2.org/development)’ ‘Quick start’ to download Dhis2 source code via ‘bzr branch lp:dhis2’ without doing the login via ‘bzr lp-login ’.

However, when doing the ‘mvn install’ on ‘/dhis-2’, it keeps on giving me an error on datamart test part.

> **···**
>
> ==================================
> 
> Running org.hisp.dhis.datamart.DataMartServiceOrgUnitTestTests run: 5, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 3.437 sec \<\<\< FA
> 
> ILURE!
> 
> Results :
> 
> Failed tests: testIndicatorDataMart(org.hisp.dhis.datamart.DataMartServiceOrgU
> 
> nitTest): expected:\<482.6\> but was:\<480.6\>
> 
> Tests run: 26, Failures: 1, Errors: 0, Skipped: 7
> 
> [INFO] ------------------------------------------------------------------------
> 
> [ERROR] BUILD FAILURE
> 
> [INFO] ------------------------------------------------------------------------
> 
> [INFO] There are test failures.
> 
> ==================================
> 
> It doesn’t require database setup before doing this, does it?
> 
> I have also tried downloading Dhis 2.9, and tried with JDK 1.6 and tried with apache-maven-3.0.4-bin.
> 
> On those tries, I got a bit different DataMart related error and once on DHIS System Support build compile error.
> 
> ==================================
> 
> [ERROR] COMPILATION ERROR :
> 
> [INFO] -------------------------------------------------------------
> 
> [ERROR] \DHIS2\2.9\dhis-2\dhis-support\dhis-support-system\src\main\java\org\his
> 
> p\dhis\system\util\ReflectionUtils.java:[254,31] type parameters of T cannot
> 
> be determined; no unique maximal instance exists for type variable T with upper
> 
> bounds T,java.lang.Object
> 
> ==================================
> 
> Does someone know the exact version of JDK, Dhis, Maven, Bazaar that would work on Windows 7 64bit?

---

<div class="post-metadata">

**Author:** ![jason](https://dhis2.b-cdn.net/user_avatar/community.dhis2.org/jason/32/32739_2.png) [@jason](https://community.dhis2.org/u/jason)\
**Post date:** [28 October 2012 03:41 UTC](https://community.dhis2.org/t/maven-build-error-on-datamart/17237/2 "2012-10-28T03:41:43Z")

</div>

Hi James,  
I have had the exact same error on 64 bit Win7, with different JDKs.

Only solution (not ideal) is to skip the tests. Look at the build.sh script.

#!/bin/sh

# Requires maven to be on the classpath  
# Skips test phase

mvn clean install -DskipTests=true  
mvn clean install -DskipTests=true -f dhis-web/pom.xm

Best regards,  
Jason

> **···**
>
> On Sat, Oct 27, 2012 at 3:09 PM, James Chang \<jamesbchang@gmail.com\> wrote:
> 
> > Hi,
> > 
> > I am trying to get the Dhis2 development environment setup, but having  
> > problem making a successful project build using Maven.  
> > Could someone give me some help on this?  
> > I am not suppose to do this on Windows 7 64bit?
> > 
> > I am using Windows 7 OS 64bit, Bazaar 2.5.1-1, JDK 1.7.0\_09,  
> > apache-maven-2.2.1
> > 
> > Followed '[Developer Resources - DHIS2](http://dhis2.org/development&#39); 'Quick start' to download Dhis2  
> > source code via 'bzr branch lp:dhis2' without doing the login via 'bzr  
> > lp-login \<username\>'.
> > 
> > However, when doing the 'mvn install' on '/dhis-2', it keeps on giving me an  
> > error on datamart test part.
> > 
> > ==================================  
> > Running org.hisp.dhis.datamart.DataMartServiceOrgUnitTestTests run: 5,  
> > Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 3.437 sec \<\<\< FA  
> > ILURE!  
> > Results :
> > 
> > Failed tests:  
> > testIndicatorDataMart(org.hisp.dhis.datamart.DataMartServiceOrgU  
> > nitTest): expected:\<482.6\> but was:\<480.6\>
> > 
> > Tests run: 26, Failures: 1, Errors: 0, Skipped: 7
> > 
> > # [INFO] ------------------------------------------------------------------------ [ERROR] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] There are test failures.
> > 
> > It doesn't require database setup before doing this, does it?
> > 
> > I have also tried downloading Dhis 2.9, and tried with JDK 1.6 and tried  
> > with apache-maven-3.0.4-bin.  
> > On those tries, I got a bit different DataMart related error and once on  
> > DHIS System Support build compile error.
> > 
> > # ================================== [ERROR] COMPILATION ERROR : [INFO] ------------------------------------------------------------- [ERROR] \DHIS2\2.9\dhis-2\dhis-support\dhis-support-system\src\main\java\org\his p\dhis\system\util\ReflectionUtils.java:[254,31] type parameters of \<T\>T cannot be determined; no unique maximal instance exists for type variable T with upper bounds T,java.lang.Object
> > 
> > Does someone know the exact version of JDK, Dhis, Maven, Bazaar that would  
> > work on Windows 7 64bit?
> > 
> > \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_  
> > Mailing list: [DHIS 2 developers in Launchpad](https://launchpad.net/~dhis2-devs)  
> > Post to : dhis2-devs@lists.launchpad.net  
> > Unsubscribe : [DHIS 2 developers in Launchpad](https://launchpad.net/~dhis2-devs)  
> > More help : [ListHelp - Launchpad Help](https://help.launchpad.net/ListHelp)

---

<div class="post-metadata">

**Author:** ![jamesc](https://dhis2.b-cdn.net/letter_avatar_proxy/v4/letter/j/bc8723/32.png) [@jamesc](https://community.dhis2.org/u/jamesc)\
**Post date:** [29 October 2012 03:55 UTC](https://community.dhis2.org/t/maven-build-error-on-datamart/17237/3 "2012-10-29T03:55:00Z")

</div>

Thanks a lot, Jason.

Running with ‘mvn clean install -DskipTests=true’ worked.

I really appreciate your help. Thanks.

> **···**
>
> On Sun, Oct 28, 2012 at 12:41 PM, Jason Pickering [jason.p.pickering@gmail.com](mailto:jason.p.pickering@gmail.com) wrote:
> 
> > Hi James,
> > 
> > I have had the exact same error on 64 bit Win7, with different JDKs.
> > 
> > Only solution (not ideal) is to skip the tests. Look at the build.sh script.
> > 
> > #!/bin/sh
> > 
> > # Requires maven to be on the classpath
> > 
> > # Skips test phase
> > 
> > mvn clean install -DskipTests=true
> > 
> > mvn clean install -DskipTests=true -f dhis-web/pom.xm
> > 
> > Best regards,
> > 
> > Jason
> > 
> > On Sat, Oct 27, 2012 at 3:09 PM, James Chang [jamesbchang@gmail.com](mailto:jamesbchang@gmail.com) wrote:
> > 
> > > Hi,
> > 
> > > 
> > 
> > > I am trying to get the Dhis2 development environment setup, but having
> > 
> > > problem making a successful project build using Maven.
> > 
> > > Could someone give me some help on this?
> > 
> > > I am not suppose to do this on Windows 7 64bit?
> > 
> > > 
> > 
> > > I am using Windows 7 OS 64bit, Bazaar 2.5.1-1, JDK 1.7.0\_09,
> > 
> > > apache-maven-2.2.1
> > 
> > > 
> > 
> > > Followed ‘[http://dhis2.org/development](http://dhis2.org/development)’ ‘Quick start’ to download Dhis2
> > 
> > > source code via ‘bzr branch lp:dhis2’ without doing the login via 'bzr
> > 
> > > lp-login '.
> > 
> > > 
> > 
> > > However, when doing the ‘mvn install’ on ‘/dhis-2’, it keeps on giving me an
> > 
> > > error on datamart test part.
> > 
> > > 
> > 
> > > 
> > 
> > > ==================================
> > 
> > > Running org.hisp.dhis.datamart.DataMartServiceOrgUnitTestTests run: 5,
> > 
> > > Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 3.437 sec \<\<\< FA
> > 
> > > ILURE!
> > 
> > > Results :
> > 
> > > 
> > 
> > > Failed tests:
> > 
> > > testIndicatorDataMart(org.hisp.dhis.datamart.DataMartServiceOrgU
> > 
> > > nitTest): expected:\<482.6\> but was:\<480.6\>
> > 
> > > 
> > 
> > > Tests run: 26, Failures: 1, Errors: 0, Skipped: 7
> > 
> > > 
> > 
> > > [INFO]
> > 
> > > * * *
> > 
> > > [ERROR] BUILD FAILURE
> > 
> > > [INFO]
> > 
> > > * * *
> > 
> > > [INFO] There are test failures.
> > 
> > > ==================================
> > 
> > > 
> > 
> > > 
> > 
> > > It doesn’t require database setup before doing this, does it?
> > 
> > > 
> > 
> > > I have also tried downloading Dhis 2.9, and tried with JDK 1.6 and tried
> > 
> > > with apache-maven-3.0.4-bin.
> > 
> > > On those tries, I got a bit different DataMart related error and once on
> > 
> > > DHIS System Support build compile error.
> > 
> > > 
> > 
> > > ==================================
> > 
> > > [ERROR] COMPILATION ERROR :
> > 
> > > [INFO] -------------------------------------------------------------
> > 
> > > [ERROR]
> > 
> > > \DHIS2\2.9\dhis-2\dhis-support\dhis-support-system\src\main\java\org\his
> > 
> > > p\dhis\system\util\ReflectionUtils.java:[254,31] type parameters of T
> > 
> > > cannot
> > 
> > > be determined; no unique maximal instance exists for type variable T with
> > 
> > > upper
> > 
> > > bounds T,java.lang.Object
> > 
> > > ==================================
> > 
> > > 
> > 
> > > 
> > 
> > > Does someone know the exact version of JDK, Dhis, Maven, Bazaar that would
> > 
> > > work on Windows 7 64bit?
> > 
> > > 
> > 
> > >
> 
> > > * * *
> > 
> > > Mailing list: [https://launchpad.net/~dhis2-devs](https://launchpad.net/~dhis2-devs)
> > 
> > > Post to : [dhis2-devs@lists.launchpad.net](mailto:dhis2-devs@lists.launchpad.net)
> > 
> > > Unsubscribe : [https://launchpad.net/~dhis2-devs](https://launchpad.net/~dhis2-devs)
> > 
> > > More help : [https://help.launchpad.net/ListHelp](https://help.launchpad.net/ListHelp)
> > 
> > >

---

<div class="post-metadata">

**Author:** ![Lars](https://dhis2.b-cdn.net/user_avatar/community.dhis2.org/lars/32/34166_2.png) [@Lars](https://community.dhis2.org/u/Lars)\
**Post date:** [29 October 2012 11:27 UTC](https://community.dhis2.org/t/maven-build-error-on-datamart/17237/4 "2012-10-29T11:27:23Z")

</div>

Hi James,

I have seen this before - data mart tests is failing in certain  
circumstances/JVMs. The funny thing is that they pass in most  
environments and I am not able to reproduce it. We need to closer on  
this.

Lars

> **···**
>
> On Mon, Oct 29, 2012 at 4:55 AM, James Chang \<jamesbchang@gmail.com\> wrote:
> 
> > Thanks a lot, Jason.
> > 
> > Running with 'mvn clean install -DskipTests=true' worked.
> > 
> > I really appreciate your help. Thanks.
> > 
> > On Sun, Oct 28, 2012 at 12:41 PM, Jason Pickering \> \<jason.p.pickering@gmail.com\> wrote:
> > 
> > > Hi James,  
> > > I have had the exact same error on 64 bit Win7, with different JDKs.
> > > 
> > > Only solution (not ideal) is to skip the tests. Look at the build.sh  
> > > script.
> > > 
> > > #!/bin/sh
> > > 
> > > # Requires maven to be on the classpath  
> > > # Skips test phase
> > > 
> > > mvn clean install -DskipTests=true  
> > > mvn clean install -DskipTests=true -f dhis-web/pom.xm
> > > 
> > > Best regards,  
> > > Jason
> > > 
> > > On Sat, Oct 27, 2012 at 3:09 PM, James Chang \<jamesbchang@gmail.com\> \>\> wrote:  
> > > \> Hi,  
> > > \>  
> > > \> I am trying to get the Dhis2 development environment setup, but having  
> > > \> problem making a successful project build using Maven.  
> > > \> Could someone give me some help on this?  
> > > \> I am not suppose to do this on Windows 7 64bit?  
> > > \>  
> > > \> I am using Windows 7 OS 64bit, Bazaar 2.5.1-1, JDK 1.7.0\_09,  
> > > \> apache-maven-2.2.1  
> > > \>  
> > > \> Followed '[Developer Resources - DHIS2](http://dhis2.org/development&#39); 'Quick start' to download Dhis2  
> > > \> source code via 'bzr branch lp:dhis2' without doing the login via 'bzr  
> > > \> lp-login \<username\>'.  
> > > \>  
> > > \> However, when doing the 'mvn install' on '/dhis-2', it keeps on giving  
> > > \> me an  
> > > \> error on datamart test part.  
> > > \>  
> > > \>  
> > > \> ==================================  
> > > \> Running org.hisp.dhis.datamart.DataMartServiceOrgUnitTestTests run: 5,  
> > > \> Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 3.437 sec \<\<\< FA  
> > > \> ILURE!  
> > > \> Results :  
> > > \>  
> > > \> Failed tests:  
> > > \> testIndicatorDataMart(org.hisp.dhis.datamart.DataMartServiceOrgU  
> > > \> nitTest): expected:\<482.6\> but was:\<480.6\>  
> > > \>  
> > > \> Tests run: 26, Failures: 1, Errors: 0, Skipped: 7  
> > > \>  
> > > \> [INFO]  
> > > \> ------------------------------------------------------------------------  
> > > \> [ERROR] BUILD FAILURE  
> > > \> [INFO]  
> > > \> ------------------------------------------------------------------------  
> > > \> [INFO] There are test failures.  
> > > \> ==================================  
> > > \>  
> > > \>  
> > > \> It doesn't require database setup before doing this, does it?  
> > > \>  
> > > \> I have also tried downloading Dhis 2.9, and tried with JDK 1.6 and tried  
> > > \> with apache-maven-3.0.4-bin.  
> > > \> On those tries, I got a bit different DataMart related error and once on  
> > > \> DHIS System Support build compile error.  
> > > \>  
> > > \> ==================================  
> > > \> [ERROR] COMPILATION ERROR :  
> > > \> [INFO] -------------------------------------------------------------  
> > > \> [ERROR]  
> > > \> \DHIS2\2.9\dhis-2\dhis-support\dhis-support-system\src\main\java\org\his  
> > > \> p\dhis\system\util\ReflectionUtils.java:[254,31] type parameters of \<T\>T  
> > > \> cannot  
> > > \> be determined; no unique maximal instance exists for type variable T  
> > > \> with  
> > > \> upper  
> > > \> bounds T,java.lang.Object  
> > > \> ==================================  
> > > \>  
> > > \>  
> > > \> Does someone know the exact version of JDK, Dhis, Maven, Bazaar that  
> > > \> would  
> > > \> work on Windows 7 64bit?  
> > > \>  
> > > \>  
> > > \> \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_  
> > > \> Mailing list: [DHIS 2 developers in Launchpad](https://launchpad.net/~dhis2-devs)  
> > > \> Post to : dhis2-devs@lists.launchpad.net  
> > > \> Unsubscribe : [DHIS 2 developers in Launchpad](https://launchpad.net/~dhis2-devs)  
> > > \> More help : [ListHelp - Launchpad Help](https://help.launchpad.net/ListHelp)  
> > > \>
> > 
> > \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_  
> > Mailing list: [DHIS 2 developers in Launchpad](https://launchpad.net/~dhis2-devs)  
> > Post to : dhis2-devs@lists.launchpad.net  
> > Unsubscribe : [DHIS 2 developers in Launchpad](https://launchpad.net/~dhis2-devs)  
> > More help : [ListHelp - Launchpad Help](https://help.launchpad.net/ListHelp)
