Joe Freeman

Command line compilation time -- Can we multi-thread

Discussion created by Joe Freeman on Oct 31, 2008
Latest reply on Dec 11, 2008 by Niall M

We have integrated our Blaze Rules into our continuous integration process.  This means we build our rules along with our Java code 5-6 times per day.  The rules currently take 22 minutes to compile when compiled from the command line in a single threaded manner.  We tried modifying our build to compile Blaze multi-threaded with little success.  The process is several times slower than our single threaded build.   Our current single threaded compilation process uses NdAdvisorProjectCompiler.main() and that is what we used in each of the threads. We're wondering if we're using the wrong approach. 



 private void compile(Service service) {


    getLog().debug("Starting compilation of Blaze service.");


     int i = 0;

    String[] args = new String[4];    args[i++] =

"-server";    File f = new File(service.getServer());

    args[i++] = f.getPath();

    args[i++] = "-name";    String serverOutName = stripSuffix(service.getServer(),

SERVER);    f = new File(serverOutName + COMPILED_SERVER);

    args[i++] = f.getPath();


    getLog().debug("Executing NdAdvisorProjectCompiler with args:");     for (int j = 0; j < args.length; j++) {






    getLog().debug("Finished compiling Blaze project");