Skip to content

Instantly share code, notes, and snippets.

@willis7
Created August 19, 2013 21:55
Show Gist options
  • Save willis7/6274651 to your computer and use it in GitHub Desktop.
Save willis7/6274651 to your computer and use it in GitHub Desktop.
<target name="bounce-svc" description="Bounce service on HOST">
<bounceService server="${j2ee.host}" service="beasvc ${weblogic.domain.name}_${weblogic.deploy.target}" />
</target>
<macrodef name="bounceService">
<attribute name="server" />
<attribute name="service" />
<sequential>
<echo message="Bouncing @{service} on @{server}" />
<exec executable="sc" outputproperty="dummy">
<arg line="\\@{server} stop &quot;@{service}&quot;" />
</exec>
<exec executable="sc" outputproperty="dummy">
<arg line="\\@{server} start &quot;@{service}&quot;" />
</exec>
<echo message="Completed bounce of @{service} on @{server}" />
</sequential>
</macrodef>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment