开发者

Ant's global property WEBLOGIC_HOME in eclipse

Ant in Eclipse has the global property WEBLOGIC_HOME but while it gives a correct tooltip in the editor it doesn't work in a build script, e.g.

<taskdef name="wsd开发者_高级运维lc" classname="weblogic.wsee.tools.anttasks.WsdlcTask" classpath="${WEBLOGIC_HOME}\server\lib\weblogic.jar" />

gives: build failed: wsdlctask cannot be found.

When I replace ${WEBLOGIC_HOME} with C:\bea\wlserver_10.3 or define my own global property there is no problem.

So nothing to worry about, but I was wondering, why does such a strange behaviour exist?


If you look at your workspace preferences in Ant > Runtime > Properties, I guess that you'll find out a WEBLOGIC_HOME property. This property is automatically added by the Weblogic plugin for Eclipse using the configuration defined in Server > Runtime Environments.

Not sure it's a good thing. First, I don't like when things happen in my back without being notified. Then, it make the build.xml not portable outside Eclipse. To avoid that, define your own property if necessary.


i had the same problem and i solve it.

The solution is to go execute the ant task as this :

  • in the eclipse outline tab, click right on the task and choose "2 Ant build", the "Edit Configuration" is displayed; click on Classpath tab and Add External JARS. Add weblogic.jar jar from weblogic server lib folder.

last click on up button to make weblogic.jar in the first position.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜