06 May 2011

Calling a WLST script from Ant







Code

build.xml
<?xml version="1.0" encoding="windows-1252" ?>
<project name="Run WLST project" default="run-wlst-script">
  <property file="wlst.properties"/>
  
  <taskdef name="wlst" classname="weblogic.ant.taskdefs.management.WLSTTask">
    <classpath>
      <pathelement location="${weblogic.lib.dir}/weblogic.jar"/>
    </classpath>
  </taskdef>
  
  <target name="run-wlst-script">
    <wlst debug="true" failonerror="true" filename="wlst.script.source">
      <classpath>
        <pathelement location="${weblogic.lib.dir}/weblogic.jar"/>
      </classpath>
    </wlst>
  </target>
  
</project>

And the property file

weblogic.home.dir=C:/Oracle/Middleware/wlserver_10.3
weblogic.lib.dir=${weblogic.home.dir}/server/lib
wlst.script.source=C:/JDeveloper/mywork/tmp/Set_Complete_Message_Timeout_script.py


Thanx again Serafim's for another good post!

No comments:

Post a Comment

You might also like:

Related Posts Plugin for WordPress, Blogger...