Posts Tagged ‘wlpackage’
Weblogic ant tasks
January 29, 2009
2 comments
If you are trying to use weblogic ant task you might have run into the following problem when calling the task :
Could not create task or type of type: wlcompile.
This happens because ant can’t find the classes associated with the task, to solve this include the following snippet in your build xml:
<taskdef name="wlcompile" classname="weblogic.ant.taskdefs.build.WLCompileTask"> <classpath> <pathelement location="${weblogic.jar}"/> </classpath> </taskdef>
Please note the classpath element, this is important or ant will not find the appropriate class files. The weblogic.jar property points towards the weblogic.jar file present in your server/lib folder.
This example is for the wlcompile task. Here are the names and classes for the other avaiable task:
- wldeploy – weblogic.ant.taskdefs.management.WLDeploy
- wlappc – weblogic.ant.taskdefs.build.WLCompileTask
- wlpackage – weblogic.ant.taskdefs.build.WLPackageTask
- wlserver – weblogic.ant.taskdefs.management.WLServer
Good place for some more info is the bea edocs site avaiable at : http://edocs.bea.com
Also check out Developing Applications with WebLogic Server 10.0