首页 > 解决方案 > 消息驱动的 EJB 无法连接 JMS 目标,说明创建 db_connection 时出错

问题描述

我们有 Oracle OSB 11g,它连接到远程位置或不同 LAN 中的 Oracle 12C DB。

WebLogic EJB 通过 JMS/JDBC 连接到 Oracle AQ,目前我们遇到了问题。

WLS 日志说:

####<Sep 21, 2018 9:15:51.083 AM GMT+00:00> <Warning> <EJB> <10.170.128.102> 
<osb02_m1> <[ACTIVE] ExecuteThread: '18' for queue: 'weblogic.kernel.Default 
(self-tuning)'> <<anonymous>> <> 
<e10b4740d6c6fa2e:-5f6b2f84:165f9d83f34:-8000-0000000000000f87> 
<1537521351083> <BEA-010096> <The Message-Driven EJB: 
RequestEJB3103778799539238415X86e7f92.165e6e1ae31.X725d is unable to connect 
to the JMS destination or bind to JCA resource adapter: queue/ProvRequestAQ. 
Connection failed after 2,609 attempts. The MDB will attempt to 
reconnect/rebind every 10 seconds. This log message will repeat every 600 
seconds until the condition clears.>

####<Sep 21, 2018 9:15:51.083 AM GMT+00:00> <Warning> <EJB> <10.170.128.102> 
<osb02_m1> <[ACTIVE] ExecuteThread: '18' for queue: 'weblogic.kernel.Default 
(self-tuning)'> <<anonymous>> <> 
<e10b4740d6c6fa2e:-5f6b2f84:165f9d83f34:-8000-0000000000000f87> 
<1537521351083> <BEA-010061> <The Message-Driven EJB: 
RequestEJB3103778799539238415X86e7f92.165e6e1ae31.X725d is unable to connect 
to the JMS destination: queue/ProvRequestAQ. The Error was:
oracle.jms.AQjmsException: Error creating the db_connection
Nested exception: java.lang.UnsupportedOperationException: Remote JDBC 
disabled
Nested exception: java.lang.UnsupportedOperationException: Remote JDBC 
disabled>

我在互联网上搜索并找到了我必须添加以下参数并添加到 setDomainEnv.sh 并重新启动 WebLogic 管理员和托管服务器的解决方案,但这个问题仍然没有解决。我还检查了用于连接数据库的数据库用户是否具有对 Oracle 队列的入队/出队权限。

参数是

WLS_JDBC_REMOTE_ENABLED="-Dweblogic.jdbc.remoteEnabled=true"

标签: oraclejmsejbdatasourceadvanced-queuing

解决方案


我认为该参数必须从域控制台添加到托管服务器的启动参数中。添加参数后重新启动托管服务器。

请求的参数可能会给 weblogic 12.1.3 带来一些麻烦。事实上,该参数自 weblogic 10.3.6 起已弃用。

如果您仍然遇到问题,请尝试以下解决方法:

https://docs.oracle.com/cd/E24329_01/web.1211/e24376/rmidriver.htm#JDBCP350

可能会有所帮助。


推荐阅读