ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bianca Xue Jiang <bji...@us.ibm.com>
Subject RE: Can I make multiple Ant run with the same VM under command line?
Date Wed, 24 Sep 2003 16:22:45 GMT
This looks very promising, Larry.  Thank you.

However, I don't know how the perl script can invoke the different targets 
separately like:  (I admit the way we are using Ant is a little uncommon.)

        (do some work....)
        Ant target1 -Dproperty1=value1 -Dproperty2=value2
        (do some work....)
        Ant target2 -Dproperty2=value2 -Dproperty3=value3
        (do some work....)
        Ant target3 -Dproperty3=value3 -Dproperty2=value2
        (do some work....)
        Ant target2 -Dproperty2=value2 -Dproperty3=value3
        ... ...

I can see parallel reuses resources by execute each target in a separate 
thread.  But how can it help me expose the tasks so that they can be 
called from command line separately?

Thanks,
Bianca





"Shatzer, Larry" <Larry.Shatzer@Spirent.com> 
09/24/2003 11:28 AM
Please respond to
"Ant Users List" <user@ant.apache.org>


To
"'Ant Users List'" <user@ant.apache.org>
cc

Subject
RE: Can I make multiple Ant run with the same VM under command li ne?






<parallel>
  <antcall target="target1"/>
  <antcall target="target2"/>
  <sequential>
  <!-- this has to run before the next -->
    <antcall target="target3"/>
    <antcall target="target4"/>
  </sequential>
  <antcall target="target5"/>
</parallel>

http://ant.apache.org/manual/CoreTasks/parallel.html
http://ant.apache.org/manual/CoreTasks/sequential.html

With antcall you can also pass properties.

http://ant.apache.org/manual/CoreTasks/antcall.html

-- Larry

> -----Original Message-----
> From: Bianca Xue Jiang [mailto:bjiang@us.ibm.com]
> Sent: Wednesday, September 24, 2003 8:14 AM
> To: Ant Users List
> Subject: RE: Can I make multiple Ant run with the same VM 
> under command
> line?
> 
> 
> The problem is the targets are not called at the same time. 
> We actually 
> have a perl script which does some different job before calling each 
> targets.   Depending on the job it finished, the perl script pass in 
> different parameters/properties to the Ant target.  This 
> works for us but 
> takes intolerably extra time to fire a new VM with each call.
> 
> Any insights?
> 
> Thanks,
> Bianca
> 
> 
> 
> 
> 
> "Shatzer, Larry" <Larry.Shatzer@Spirent.com> 
> 09/24/2003 11:05 AM
> Please respond to
> "Ant Users List" <user@ant.apache.org>
> 
> 
> To
> "'Ant Users List'" <user@ant.apache.org>
> cc
> 
> Subject
> RE: Can I make multiple Ant run with the same VM under command li ne?
> 
> 
> 
> 
> 
> 
> You can make a target such as:
> 
>                  <target name="multiple" 
> depends="target1,target2,target3"/>
> 
> and call that target instead.
> 
> -- Larry
> 
> > -----Original Message-----
> > From: Bianca Xue Jiang [mailto:bjiang@us.ibm.com]
> > Sent: Wednesday, September 24, 2003 7:32 AM
> > To: user@ant.apache.org
> > Subject: Can I make multiple Ant run with the same VM under command
> > line?
> > 
> > 
> > Hi,
> > 
> > I need to call an Ant script's different targets frequently 
> > under command 
> > line.  The fact that each time a new VM is started up to 
> > execute Ant takes 
> > much more time than the target itself.  Is there a way to 
> > start Ant under 
> > the same VM every time to optimize this?
> > 
> > Thanks,
> > Bianca
> > 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
> 
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org



Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message