You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@directory.apache.org by Felix Knecht <fe...@otego.com> on 2010/06/07 22:36:26 UTC

Scheduling Junit tests with RunnerScheduler for a concurrent execution

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

I came across following site (http://junit.org/node/589) talking about
concurrent execution if junit tests and couldn't resist to give it a try
on the shared project. I used the same configuration in the page shown
(threads=6) and added it to all tests in the shared project. It's 10
seconds faster (64s <-> 54s) what is ~16%.

IMO it's worth to have a closer look at it also when thinking of larger
tests in the apacheds project.

WDOT?
Felix


without concurrency:
[INFO]
- ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
- ------------------------------------------------------------------------
[INFO] Apache Directory Shared ............................... SUCCESS
[2.288s]
[INFO] Apache Directory Shared I18n .......................... SUCCESS
[1.814s]
[INFO] Apache Directory Shared ASN.1 ......................... SUCCESS
[2.728s]
[INFO] Apache Directory Shared ASN.1 Codec ................... SUCCESS
[1.489s]
[INFO] Apache Directory Shared Cursor ........................ SUCCESS
[2.345s]
[INFO] Apache Directory Shared LDAP Constants ................ SUCCESS
[1.560s]
[INFO] Apache Directory Shared LDAP .......................... SUCCESS
[13.242s]
[INFO] Apache Directory Shared LDIF .......................... SUCCESS
[3.169s]
[INFO] Apache Directory Shared DSML Parser ................... SUCCESS
[3.830s]
[INFO] Apache Directory Shared LDAP Converters ............... SUCCESS
[2.839s]
[INFO] Apache Directory Shared JNDI .......................... SUCCESS
[1.690s]
[INFO] Apache Directory Shared LDAP Schema ................... SUCCESS
[4.314s]
[INFO] Apache Directory Shared LDAP Schema Loader ............ SUCCESS
[1.811s]
[INFO] Apache Directory Shared LDAP Schema Manager ........... SUCCESS
[17.710s]
[INFO] Apache Directory Shared All ........................... SUCCESS
[2.779s]
[INFO]
- ------------------------------------------------------------------------
[INFO]
- ------------------------------------------------------------------------
[INFO] BUILD SUCCESSFUL
[INFO]
- ------------------------------------------------------------------------
[INFO] Total time: 1 minute 4 seconds



with concurrency
[INFO] Reactor Summary:
[INFO]
- ------------------------------------------------------------------------
[INFO] Apache Directory Shared ............................... SUCCESS
[2.097s]
[INFO] Apache Directory Shared I18n .......................... SUCCESS
[1.865s]
[INFO] Apache Directory Shared ASN.1 ......................... SUCCESS
[2.706s]
[INFO] Apache Directory Shared ASN.1 Codec ................... SUCCESS
[1.484s]
[INFO] Apache Directory Shared Cursor ........................ SUCCESS
[2.387s]
[INFO] Apache Directory Shared LDAP Constants ................ SUCCESS
[1.559s]
[INFO] Apache Directory Shared LDAP .......................... SUCCESS
[12.984s]
[INFO] Apache Directory Shared LDIF .......................... SUCCESS
[3.017s]
[INFO] Apache Directory Shared DSML Parser ................... SUCCESS
[3.644s]
[INFO] Apache Directory Shared LDAP Converters ............... SUCCESS
[2.873s]
[INFO] Apache Directory Shared JNDI .......................... SUCCESS
[1.704s]
[INFO] Apache Directory Shared LDAP Schema ................... SUCCESS
[4.154s]
[INFO] Apache Directory Shared LDAP Schema Loader ............ SUCCESS
[1.744s]
[INFO] Apache Directory Shared LDAP Schema Manager ........... SUCCESS
[9.636s]
[INFO] Apache Directory Shared All ........................... SUCCESS
[2.362s]
[INFO]
- ------------------------------------------------------------------------
[INFO]
- ------------------------------------------------------------------------
[INFO] BUILD SUCCESSFUL
[INFO]
- ------------------------------------------------------------------------
[INFO] Total time: 54 seconds
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.15 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkwNWEoACgkQ2lZVCB08qHGtwQCeP/hTs1CW8j7CbLsbjw7mwB9i
RWIAoKJpOM2QyVyN2QAvqe4f8S9L7MiI
=LO0x
-----END PGP SIGNATURE-----

Re: Scheduling Junit tests with RunnerScheduler for a concurrent execution

Posted by Emmanuel Lecharny <el...@gmail.com>.
On 6/7/10 10:36 PM, Felix Knecht wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> I came across following site (http://junit.org/node/589) talking about
> concurrent execution if junit tests and couldn't resist to give it a try
> on the shared project. I used the same configuration in the page shown
> (threads=6) and added it to all tests in the shared project. It's 10
> seconds faster (64s<->  54s) what is ~16%.
>
> IMO it's worth to have a closer look at it also when thinking of larger
> tests in the apacheds project.
>
> WDOT?
>    

I'm 100% in favor of using such a thing. There is however one little 
issue we have to take care of : when we are using tests using a port, we 
have to take care that the same port is not used by another test.

Otherwise, we have checked Maven 3.0 which has a // mode too (except 
that this // mode is only at the module level). Quite interesting.

So atm, if you want to use the annotation to //ize shared, you have my +1

-- 
Regards,
Cordialement,
Emmanuel Lécharny
www.nextury.com