从java jdeveloper连接weblogic wlst时出错

从java jdeveloper连接weblogic wlst时出错,java,weblogic,jdeveloper,wlst,Java,Weblogic,Jdeveloper,Wlst,我正在尝试使用WLST解释器在java中嵌入WLST脚本。但是,我遇到以下错误: Exception in thread "main" java.lang.RuntimeException: error in finding weblogic.Home at weblogic.Home.getInstance(Home.java:91) at weblogic.Home.getPath(Home.java:97) at weblogic.Home.getFile(Home.java:102)

我正在尝试使用WLST解释器在java中嵌入WLST脚本。但是,我遇到以下错误:

Exception in thread "main" java.lang.RuntimeException: error in finding 
weblogic.Home at weblogic.Home.getInstance(Home.java:91) at 
weblogic.Home.getPath(Home.java:97) at weblogic.Home.getFile(Home.java:102) at 
weblogic.management.scripting.utils.WLSTInterpreter.(WLSTInterpreter.java:116) at 
weblogic.management.scripting.utils.WLSTInterpreter.(WLSTInterpreter.java:76) at 
weblogic.management.scripting.utils.WLSTUtil.ensureInterpreter(WLSTUtil.java:157) at 
client.WLSTWrapper.doSomething(WLSTWrapper.java:19) at 
client.WLSTWrapper.main(WLSTWrapper.java:13)

任何帮助都将不胜感激。

请确保weblogic.jar位于您的类路径中。如果问题仍然存在,请尝试在启动脚本中添加如下java选项:

-Dweblogic.home=/opt/oracle/mw/wlserver_10.3

谢谢,我试着将weblogic.jar添加到类路径,并编辑脚本。还是遇到了同样的问题。不过,我找到了一个更好的方法来运行脚本:Process p=Runtime.getRuntime().exec(“脚本的wlst.cmd位置”),谢谢您的帮助。