EJB 调用过程出现 ADFContext memory leak 警告信息
(Doc ID 2134496.1)
Last updated on AUGUST 06, 2020
适用于:
Oracle JDeveloper - 版本 12.1.3.0.0 和更高版本本文档所含信息适用于所有平台
目标
EJB/RMI 客户端程序调用部署在 Weblogic Server 12.1.3.0.0 服务器里面的 EJB, 源代码示意如下.
try {
ctx = new InitialContext(jndiProps);
appModuleService = ctx.lookup("AppModuleServiceBean#demo.model.common.serviceinterface.AppModuleService");
appModuleService.getClass().getMethod(methodName, paramTypes).invoke(appModuleService, paramArray);
} catch (Exception e) {
......
}
每个 EJB 方法调用后都会看到下面的警告信息:
<Apr 27, 2016 9:17:01 AM UTC> <Warning> <oracle.adf.share.ADFContext> <BEA-000000> <Automatically initializing a DefaultContext for getCurrent.
Caller should ensure that a DefaultContext is proper for this use.
Memory leaks and/or unexpected behaviour may occur if the automatic initialization is performed improperly.
This message may be avoided by performing initADFContext before using getCurrent().
For more information please enable logging for oracle.adf.share.ADFContext at FINEST level.>
<Apr 27, 2016 9:17:01 AM UTC> <Error> <oracle.adf.share.ADFContext> <BEA-000000> <ADF detected an ADFContext leak.
Please see the documentation for more information about handling ADFContext leaks.
For more information about the leaking ADFContext please enable logging for oracle.adf.share.ADFContext at FINEST level.
中文环境下:
<oracle.adf.common> <ADFContext> <getCurrent> <自动初始化 DefaultContext 以执行 getCurrent。
调用方应确保 DefaultContext 适合此用法。
如果未正确执行自动初始化, 则可能会出现内存泄露和/或意外行为。
在使用 getCurrent() 之前执行 initADFContext 可避免此消息。
有关详细信息, 请在 FINEST 级别对 oracle.adf.share.ADFContext 启用日志记录。>
<oracle.adf.common> <ADFContext$1> <run> <ADF 检测到 ADFContext 泄漏。
有关处理 ADFContext 泄漏的详细信息, 请参阅相关文档。
有关 ADFContext 泄漏的详细信息, 请启用 FINEST 级别的 oracle.adf.share.ADFContext 日志记录。
>
Caller should ensure that a DefaultContext is proper for this use.
Memory leaks and/or unexpected behaviour may occur if the automatic initialization is performed improperly.
This message may be avoided by performing initADFContext before using getCurrent().
For more information please enable logging for oracle.adf.share.ADFContext at FINEST level.>
<Apr 27, 2016 9:17:01 AM UTC> <Error> <oracle.adf.share.ADFContext> <BEA-000000> <ADF detected an ADFContext leak.
Please see the documentation for more information about handling ADFContext leaks.
For more information about the leaking ADFContext please enable logging for oracle.adf.share.ADFContext at FINEST level.
中文环境下:
<oracle.adf.common> <ADFContext> <getCurrent> <自动初始化 DefaultContext 以执行 getCurrent。
调用方应确保 DefaultContext 适合此用法。
如果未正确执行自动初始化, 则可能会出现内存泄露和/或意外行为。
在使用 getCurrent() 之前执行 initADFContext 可避免此消息。
有关详细信息, 请在 FINEST 级别对 oracle.adf.share.ADFContext 启用日志记录。>
<oracle.adf.common> <ADFContext$1> <run> <ADF 检测到 ADFContext 泄漏。
有关处理 ADFContext 泄漏的详细信息, 请参阅相关文档。
有关 ADFContext 泄漏的详细信息, 请启用 FINEST 级别的 oracle.adf.share.ADFContext 日志记录。
>
果真会导致内存泄露吗? 如何解决?
解决方案
To view full details, sign in with your My Oracle Support account. |
|
Don't have a My Oracle Support account? Click to get started! |
文档内容
目标 |
解决方案 |
参考 |