Discussion:
How to creating concurrent call in batch file
feilong
2005-07-08 14:30:01 UTC
Permalink
Hallo,
I want to write a batch file under windows to call 6 instances concurrently to test whether the program is thread-safe. Below is the shell script for linux to create parallel call, it works. But if I use the same syntax, i.e. "&" to connect "java" call in batch file under windows, it only creates serial call, not concurrent call.
How can I write a windows script or a batch file under windows to build parallel call.

Best Regards
saarxfk


parallelCall.sh
------------------------------------------------------------------------------------------------
# set the classpath
export CLASSPATH=
for i in jars/*jar; do export CLASSPATH=$CLASSPATH:$i; done

java WinsServiceClient morganti.pdf morganti.pdf it &
java WinsServiceClient alesi.pdf alesi.pdf it &
java WinsServiceClient morganti2.pdf morganti2.pdf it &
java WinsServiceClient alesi2.pdf alesi2.pdf it &
java WinsServiceClient morganti3.pdf morganti3.pdf it &
java WinsServiceClient alesi3.pdf alesi3.pdf it
------------------------------------------------------------------------------------------------

Best Regards
Feilong
Felipe Palma Dias
2005-07-08 14:54:59 UTC
Permalink
Try

start java ...
Post by feilong
Hallo,
I want to write a batch file under windows to call 6
instances concurrently to test whether the program
is thread-safe. Below is the shell script for linux
to create parallel call, it works. But if I use the
same syntax, i.e. "&" to connect "java" call in
batch file under windows, it only creates serial
call, not concurrent call.
How can I write a windows script or a batch file
under windows to build parallel call.
Best Regards
saarxfk
parallelCall.sh
------------------------------------------------------------------------------------------------
Post by feilong
# set the classpath
export CLASSPATH=
for i in jars/*jar; do export
CLASSPATH=$CLASSPATH:$i; done
java WinsServiceClient morganti.pdf morganti.pdf it
&
java WinsServiceClient alesi.pdf alesi.pdf it &
java WinsServiceClient morganti2.pdf morganti2.pdf
it &
java WinsServiceClient alesi2.pdf alesi2.pdf it &
java WinsServiceClient morganti3.pdf morganti3.pdf
it &
java WinsServiceClient alesi3.pdf alesi3.pdf it
------------------------------------------------------------------------------------------------
Post by feilong
Best Regards
Feilong
Felipe F. Palma Dias - São Paulo/SP
http://www.palmadias.com.br
MSN: ***@yahoo.com.br
Yahoo: palmadias
Mobile: +55 11 99157578





_______________________________________________________
Yahoo! Acesso Grátis - Internet rápida e grátis.
Instale o discador agora! http://br.acesso.yahoo.com/
Scott Nichol
2005-07-08 15:50:24 UTC
Permalink
In case it is not clear, what he means is

start java WinsServiceClient morganti.pdf morganti.pdf it
start java WinsServiceClient alesi.pdf alesi.pdf it
start java WinsServiceClient morganti2.pdf morganti2.pdf it
start java WinsServiceClient alesi2.pdf alesi2.pdf it
start java WinsServiceClient morganti3.pdf morganti3.pdf it
start java WinsServiceClient alesi3.pdf alesi3.pdf it

The "start" command launches a new window in which to run the command.

Scott Nichol

Do not send e-mail directly to this e-mail address,
because it is filtered to accept only mail from
specific mail lists.
----- Original Message -----
From: "Felipe Palma Dias" <***@yahoo.com.br>
To: <soap-***@ws.apache.org>
Sent: Friday, July 08, 2005 10:54 AM
Subject: Re: How to creating concurrent call in batch file
Post by Felipe Palma Dias
Try
start java ...
Post by feilong
Hallo,
I want to write a batch file under windows to call 6
instances concurrently to test whether the program
is thread-safe. Below is the shell script for linux
to create parallel call, it works. But if I use the
same syntax, i.e. "&" to connect "java" call in
batch file under windows, it only creates serial
call, not concurrent call.
How can I write a windows script or a batch file
under windows to build parallel call.
Best Regards
saarxfk
parallelCall.sh
------------------------------------------------------------------------------------------------
Post by feilong
# set the classpath
export CLASSPATH=
for i in jars/*jar; do export
CLASSPATH=$CLASSPATH:$i; done
java WinsServiceClient morganti.pdf morganti.pdf it
&
java WinsServiceClient alesi.pdf alesi.pdf it &
java WinsServiceClient morganti2.pdf morganti2.pdf
it &
java WinsServiceClient alesi2.pdf alesi2.pdf it &
java WinsServiceClient morganti3.pdf morganti3.pdf
it &
java WinsServiceClient alesi3.pdf alesi3.pdf it
------------------------------------------------------------------------------------------------
Post by feilong
Best Regards
Feilong
Felipe F. Palma Dias - São Paulo/SP
http://www.palmadias.com.br
Yahoo: palmadias
Mobile: +55 11 99157578
_______________________________________________________
Yahoo! Acesso Grátis - Internet rápida e grátis.
Instale o discador agora! http://br.acesso.yahoo.com/
Loading...