| View previous topic :: View next topic |
| Author |
Message |
phanik
Joined: 08 Jun 2009 Posts: 3
|
Posted: Tue Jan 05, 2010 10:55 am Post subject: Parallel Restarts with a time frame |
|
|
Hi Team,
I have question on <parallel> ant task.
Currently i am using <parallel>task to bounce jobss server
<parallel>
<propertycopy name="remote.host" from="deploy.${target.env}.host.${remote.id}" />
<propertycopy name="remote.port" from="deploy.${target.env}.port.${remote.id}" />
<echo message="${remote.host} session .............. open"/>
<sshexec trust="true"
host="${remote.host}"
port="${remote.port}"
username="${user}"
keyfile="${user.key}"
command="sudo /usr/local/bin/bounce_jboss" />
<echo message="${remote.host} session ............. close"/>
</parallel>
servers information is defined in build.properties.
But the problem is , Since my Jboss Administrator is telling there is a cluster issue while doing a parallel restart, wanted to find out a time frame of 30 to 45 seconds for each server restart.
Is there a way where i can put some<sleep> command in between each server restart.
Please give me some inputs.
thanks |
|
| Back to top |
|
JNiven
Joined: 17 Feb 2008 Posts: 1288 Location: Glasgow, Scotland
|
Posted: Tue Jan 05, 2010 11:08 am Post subject: |
|
|
Hi phanik
Uh, this is a Subversion forum, not an Ant forum - you'll almost certainly have more luck at the correct venue
That said, the point of the parallel task is that it runs stuff concurrently. If you want a pause between each bounce, try the sequential task - sequential even allows a "sleep" period to be specified.
Cheers
John _________________ John Niven |
|
| Back to top |
|
phanik
Joined: 08 Jun 2009 Posts: 3
|
Posted: Tue Jan 05, 2010 12:40 pm Post subject: problem with sequential |
|
|
problem with sequential is, it cannot invoke another task until the first task finishes. This wont meet the requirement.
Any ways thanks for the inputs, will try in ant forums. |
|
| Back to top |
|
JNiven
Joined: 17 Feb 2008 Posts: 1288 Location: Glasgow, Scotland
|
Posted: Tue Jan 05, 2010 1:07 pm Post subject: |
|
|
No worries. One final thought - could you create your own Ant task, inheriting from parallel, but with a "sleep" component? I've not looked at the source for parallel, but I'd imagine it'd be fairly straightforward code, without too much to add.
Good luck!
John _________________ John Niven |
|
| Back to top |
|
|
View previous topic :: View next topic |