Invoke a java main class when weblogic server starts

时间:2016-07-11 20:15:34

标签: java weblogic jdeveloper weblogic12c

I have a java class has a main method. I want this main method to be executed whenever I start the WebLogic server.

Also I would like to have this class exit safely if I stop the WebLogic server.

I am not sure how to deploy this simple java application to WebLogic server or there is a way to configure the WebLogic server to call a jar file. What is the best way to do this? Thank you.

1 个答案:

答案 0 :(得分:1)

您可以在启动和/或关闭时通过管理控制台将WLS配置为call a specific Java class。该类必须位于WLS类路径上,因此对该类进行修改涉及滚动节点重启(以及将文件放在类路径启动脚本上的能力)。