weblogic-application.xml

本文解释了如何正确配置WebLogic Server特定的部署描述符weblogic-application.xml。此文件不能放置在WAR文件中,而应该包含在EAR文件的META-INF目录内。文中详细介绍了使用Maven EAR Plugin进行打包的方法。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

Could you please let me know whether weblogic-application.xml can be added in a WAR file and if so, then how to do the same.

No, it cannot. If you do it, then it won't be considered.

It needs to be in an ear-file/META-INF

The weblogic-application.xml file is the WebLogic Server-specific deployment descriptor extension for the application.xml deployment descriptor from Sun Microsystems. This is where you configure features such as shared Java EE libraries referenced in the application and EJB caching.

This info is for WLS 10.3.x more details at:http://docs.oracle.com/cd/E21764_01/web.1111/e13706/app_xml.htm#i1007581



Maven

The weblogic-application.xml should be packaged in the META-INF directory of your final EAR (next to the standard application.xml).

With the Maven EAR Plugin, the default location for extra files to include in the EAR (that you can control with the earSourceDirectory parameter) is src/main/application. So the following would work (using the defaults):

myear
|-- src
|   `-- main
|       `-- application
|           `-- META-INF
|               `-- weblogic-application.xml
`-- pom.xml

转载于:https://my.oschina.net/u/138995/blog/203995

打包报错了,<Jul 30, 2025, 5:50:36,784 PM China Standard Time> <Error> <Deployer> <BEA-149265> <Failure occurred in the execution of deployment request with ID "7889792369197352" for task "920" on [partition-name: DOMAIN]. Error is: "weblogic.application.ModuleException: java.lang.ClassNotFoundException: com.lkm.ejb.toolmanage.server.ToolManageEjb" weblogic.application.ModuleException: java.lang.ClassNotFoundException: com.lkm.ejb.toolmanage.server.ToolManageEjb at weblogic.application.internal.ExtensibleModuleWrapper.prepare(ExtensibleModuleWrapper.java:114) at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:100) at weblogic.application.internal.flow.ModuleStateDriver$1.next(ModuleStateDriver.java:192) at weblogic.application.internal.flow.ModuleStateDriver$1.next(ModuleStateDriver.java:187) at weblogic.application.utils.StateMachineDriver$ParallelChange.run(StateMachineDriver.java:83) Truncated. see log file for complete stacktrace Caused By: java.lang.ClassNotFoundException: com.lkm.ejb.toolmanage.server.ToolManageEjb at weblogic.utils.classloaders.GenericClassLoader.findLocalClass(GenericClassLoader.java:1035) at weblogic.utils.classloaders.GenericClassLoader.findClass(GenericClassLoader.java:996) at weblogic.utils.classloaders.ChangeAwareClassLoader.findClass(ChangeAwareClassLoader.java:101) at weblogic.utils.classloaders.GenericClassLoader.doFindClass(GenericClassLoader.java:617) at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:547) Truncated. see log file for complete stacktrace
最新发布
07-31
<Jul 29 17:54:38> <Error> <Deployer> <Failure occurred in the execution of deployment request with ID "7803635478605029" for task "199" on [partition-name: DOMAIN]. Error is: "weblogic.management.DeploymentException: weblogic.application.naming.ReferenceResolutionException: [J2EE:160200]Error resolving ejb-ref "com.lkm.ejb.impl.UserInfoBean/userInfoRemoteEjb" from module "null" of application "LkmNcEjbs". The ejb-ref does not have an ejb-link and the JNDI name of the target bean has not been specified. Attempts to automatically link the ejb-ref to its target bean failed because no EJBs in the application were found to implement the "com.lkm.ejb.service.UserInfoRemoteEjb" interface. Link or map this ejb-ref to its target EJB and ensure the interfaces declared in the ejb-ref are correct." weblogic.management.DeploymentException: weblogic.application.naming.ReferenceResolutionException: [J2EE:160200]Error resolving ejb-ref "com.lkm.ejb.impl.UserInfoBean/userInfoRemoteEjb" from module "null" of application "LkmNcEjbs". The ejb-ref does not have an ejb-link and the JNDI name of the target bean has not been specified. Attempts to automatically link the ejb-ref to its target bean failed because no EJBs in the application were found to implement the "com.lkm.ejb.service.UserInfoRemoteEjb" interface. Link or map this ejb-ref to its target EJB and ensure the interfaces declared in the ejb-ref are correct. at weblogic.application.internal.flow.EnvContextFlow.activate(EnvContextFlow.java:81) at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:752) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:45) at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:262) at weblogic.application.internal.EarDeployment.activate(EarDeployment.java:66) Truncated. see log file for complete stacktrace
07-30
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值