java - 如何刷新 weblogic 上的 jsp

标签 java jsp weblogic weblogic-10.x

我在 weblogic 10.0 生产模式下运行爆炸式 war 。

我想修改一个 jsp 而不必完全重新部署应用程序。我似乎无法使用带有部分 redployment 的 weblogic.Deployer 来实现这一点 - 请参阅:

http://download-llnw.oracle.com/docs/cd/E13222_01/wls/docs100/deployment/redeploy.html#wp1025739

这一定是一个相当标准的问题 - 有人有解决方案吗?

最佳答案

根据您提供的链接,weblogic.Deployer 是您的 friend :

Updating Static Files in a Deployed Application

In a production environment, you may occasionally need to refresh the static content of a Web application module—HTML files, image files, JSPs, and so forth—without redeploying the entire application. If you deployed a Web application or an Enterprise Application as an exploded archive directory, you can use the weblogic.Deployer utility to update one or more changed static files in-place. See Avoiding Unnecessary JSP Compilation on dev2dev.comTuning Web Applications.

To redeploy a single file associated within a deployment unit, specify the file name at the end of the redeploy command. For example:

java weblogic.Deployer -adminurl http://localhost:7001 -user weblogic
   -password weblogic -name myApp -redeploy myApp/copyright.html

Always specify the pathname to updated files relative to the root directory of the exploded archive directory. In the above example, the Web application is deployed as part of an Enterprise Application, so the module directory is specified (myApp/copyright.html).

If the Web application module had been deployed as a stand-alone module, rather than as part of an Enterprise Application, the file would have been specified alone (copyright.html).

You can also redeploy an entire directory of files by specifying a directory name instead of a single file. For example:

java weblogic.Deployer -adminurl http://localhost:7001 -user weblogic
   -password weblogic -name myApp -redeploy myApp/myjsps

In the above example, all files and subdirectories located in the myjsps subdirectory of the Enterprise Application are redeployed in-place.

据我所知,这也适用于生产模式。所以一定是你使用的命令语法有问题。

关于java - 如何刷新 weblogic 上的 jsp,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/1476461/

相关文章:

java - 如何在现有背景图像上添加侧边菜单(导航菜单)

java - 使用ajax从servlet中检索java对象并使用JSTL打印它

java - Weblogic 10.3开启管理员端口后无法访问

java - 为什么 java 使用 JAVA_HOME/lib/security/cacerts 的默认位置 keystore /信任库,尽管我提供了 -Djavax.net.ssl.trustStore 属性

java - 从 Java Web 服务启动外部进程的最佳方式?

java - 控制字谜词

java - HDFS 复制属性未反射(reflect)在 hfs-site.xml 中定义

java - 尝试生成一个 pdf 表,该表将存储在 s3 上并立即作为自动电子邮件附件检索

java - 为什么 maven-war-plugin 忽略我配置的 Web 资源过滤器?

javascript - 我们可以提交一个jsp表单两次吗?