在WebSphere App Server上實現動態類重新加載功能到J2EE WebApp的任何重新來源或最佳實踐?最好的方式來重新加載沒有WebSphere重新啓動Java類?
重點是我不想讓我的網絡應用程序,而某些類更新。
在WebSphere App Server上實現動態類重新加載功能到J2EE WebApp的任何重新來源或最佳實踐?最好的方式來重新加載沒有WebSphere重新啓動Java類?
重點是我不想讓我的網絡應用程序,而某些類更新。
只需按照WebSphere Infocenter的說明。該部分標題爲「熱部署和動態重載」。這似乎只是你正在尋找的東西。
你可能想看看javarebel,這是藝術的狀態熱重裝AFIK
除了將所有項目文件複製到WebSphere installedapps目錄之外,還有一個Maven任務。現在不需要通過管理界面更新應用程序,只需運行maven install,所有文件將被複制到服務器。不要忘了IBM的web-bnd.xmi和ibm的web-ext.xmi文件的文件添加到您的WEB_INF使類重裝
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<websphere.was.path>L:\WebSphere\AppServer</websphere.was.path>
<websphere.portal.path>L:\WebSphere\PortalServer</websphere.portal.path>
<deploy.path>L:\WebSphere\wp_profile\installedApps\LIPETSK-WPSCell\PA_Services_Search.ear</deploy.path>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
...
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<phase>install</phase>
<configuration>
<tasks>
<property name="src" location="target/${project.artifactId}"/>
<property name="dst" location="${deploy.path}/${project.artifactId}.${project.packaging}"/>
<copy todir="${dst}" overwrite="true" verbose="true">
<fileset dir="${src}" casesensitive="yes">
<include name="**/*.*"/>
<exclude name="WEB-INF/lib/*.*"/>
</fileset>
</copy>
</tasks>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
</executions>
</plugin>
鏈接被重定向到默認信息中心的網頁。請更新 – saurav 2016-06-01 20:59:26