Fast Connection Failover, Connection Pooling and ONS

Hello,

I am trying to configure a connection pool (on the Sun Java System Application Server Enterprise Edition 8.1_02 (build b15-p06)) to connect to an Oracle cluster. I have configured ONS to what is described in the docs. However, upon trying to "ping" the connection pool from within the server itself, I keep getting these message (see bottom of post for the full stack trace):

SEVERE|sun-appserver-ee8.1_02|javax.enterprise.resource.resourceadapter|_Thread ID=13;|RAR5103 : Error setting java bean value : {0}

java.lang.reflect.InvocationTargetException

AND

Caused by: java.sql.SQLException: Connection Caching Not Enabled or Not a Valid Cache Enabled DataSource

This only occurs when I try to set these parameters on the pool:

ConnectionCachingEnabled = true

FastConnectionFailoverEnabled=true

I have the most current drivers, etc. Does anyone have any ideas as to why this will not work?

Thanks!

FULL STACK:::::

SEVERE|sun-appserver-ee8.1_02|javax.enterprise.resource.resourceadapter|_Thread ID=13;|RAR5103 : Error setting java bean value : {0}

java.lang.reflect.InvocationTargetException

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.ja va:25)

at java.lang.reflect.Method.invoke(Method.java:585)

at com.sun.gjc.util.MethodExecutor.runMethod(MethodExecutor.java:94)

at com.sun.gjc.common.DataSourceObjectBuilder.constructDataSourceObject(DataSource ObjectBuilder.java:73)

at com.sun.gjc.spi.CPManagedConnectionFactory.createManagedConnection(CPManagedCon nectionFactory.java:72)

at com.sun.enterprise.connectors.ConnectorConnectionPoolAdminServiceImpl.getUnpool edConnection(ConnectorConnectionPoolAdminServiceImpl.java:1181)

at com.sun.enterprise.connectors.ConnectorConnectionPoolAdminServiceImpl.testConne ctionPool(ConnectorConnectionPoolAdminServiceImpl.java:507)

at com.sun.enterprise.connectors.ConnectorRuntime.testConnectionPool(ConnectorRunt ime.java:504)

at com.sun.enterprise.admin.mbeans.ResourcesMBean.pingConnectionPool(ResourcesMBea n.java:1920)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.ja va:25)

at java.lang.reflect.Method.invoke(Method.java:585)

at com.sun.enterprise.admin.MBeanHelper.invokeOperationInBean(MBeanHelper.java:302 )

at com.sun.enterprise.admin.config.BaseConfigMBean.invoke(BaseConfigMBean.java:357 )

at com.sun.jmx.mbeanserver.DynamicMetaDataImpl.invoke(DynamicMetaDataImpl.java:213 )

at com.sun.jmx.mbeanserver.MetaDataImpl.invoke(MetaDataImpl.java:220)

at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServer Interceptor.java:815)

at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:784)

at sun.reflect.GeneratedMethodAccessor23.invoke(Unknown Source)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.ja va:25)

at java.lang.reflect.Method.invoke(Method.java:585)

at com.sun.enterprise.admin.util.proxy.ProxyClass.invoke(ProxyClass.java:54)

at $Proxy1.invoke(Unknown Source)

at com.sun.enterprise.admin.server.core.jmx.SunoneInterceptor.invoke(SunoneInterce ptor.java:272)

at com.sun.enterprise.tools.admingui.util.MBeanUtil.invoke(MBeanUtil.java:148)

at com.sun.enterprise.tools.admingui.util.MBeanUtil.invoke(MBeanUtil.java:46)

at com.sun.enterprise.tools.admingui.handlers.CommonHandlers.invokeMBean(CommonHan dlers.java:123)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.ja va:25)

at java.lang.reflect.Method.invoke(Method.java:585)

at com.sun.enterprise.tools.guiframework.view.DescriptorViewHelper.invokeHandler(D escriptorViewHelper.java:863)

at com.sun.enterprise.tools.guiframework.view.DescriptorViewHelper.invokeHandlers( DescriptorViewHelper.java:800)

at com.sun.enterprise.tools.guiframework.view.DescriptorViewHelper.dispatchEvent(D escriptorViewHelper.java:775)

at com.sun.enterprise.tools.guiframework.view.DescriptorViewHelper.execute(Descrip torViewHelper.java:291)

at com.sun.enterprise.tools.guiframework.view.DescriptorViewBeanBase.execute(Descr iptorViewBeanBase.java:192)

at com.iplanet.jato.view.RequestHandlingViewBase.handleRequest(RequestHandlingView Base.java:308)

at com.iplanet.jato.view.ViewBeanBase.dispatchInvocation(ViewBeanBase.java:802)

at com.iplanet.jato.view.ViewBeanBase.invokeRequestHandlerInternal(ViewBeanBase.ja va:740)

at com.iplanet.jato.view.ViewBeanBase.invokeRequestHandlerInternal(ViewBeanBase.ja va:760)

at com.iplanet.jato.view.ViewBeanBase.invokeRequestHandler(ViewBeanBase.java:571)

at com.iplanet.jato.ApplicationServletBase.dispatchRequest(ApplicationServletBase. java:957)

at com.iplanet.jato.ApplicationServletBase.processRequest(ApplicationServletBase.j ava:615)

at com.sun.enterprise.tools.guiframework.view.BaseServlet.processRequest(BaseServl et.java:186)

at com.iplanet.jato.ApplicationServletBase.doPost(ApplicationServletBase.java:473)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:767)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:860)

at sun.reflect.GeneratedMethodAccessor87.invoke(Unknown Source)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.ja va:25)

at java.lang.reflect.Method.invoke(Method.java:585)

at org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:249)

at java.security.AccessController.doPrivileged(Native Method)

at javax.security.auth.Subject.doAsPrivileged(Subject.java:517)

at org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:282)

at org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:165)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFil terChain.java:257)

at org.apache.catalina.core.ApplicationFilterChain.access$000(ApplicationFilterCha in.java:55)

at org.apache.catalina.core.ApplicationFilterChain$1.run(ApplicationFilterChain.ja va:161)

at java.security.AccessController.doPrivileged(Native Method)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain .java:157)

at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java: 263)

at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)

at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextVal ve.java:225)

at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java: 173)

at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)

at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:170)

at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)

at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:933)

at com.sun.enterprise.web.connector.httpservice.HttpServiceProcessor.process(HttpS erviceProcessor.java:226)

at com.sun.enterprise.web.HttpServiceWebContainer.service(HttpServiceWebContainer. java:2074)

Caused by: java.sql.SQLException: Connection Caching Not Enabled or Not a Valid Cache Enabled DataSource

at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:112)

at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:146)

at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:208)

at oracle.jdbc.pool.OracleDataSource.setConnectionCachingEnabled(OracleDataSource. java:504)

... 73 more

[8263 byte] By [myersshawn] at [2007-11-26 9:30:39]
# 1
Hi,1) Can you post your connection pool configuration ?2) Seems like oracle driver or database is throwing this error. What is the oracle database version ?Thanks,-Jagadish
JagadishPrasath at 2007-7-7 0:14:48 > top of Java-index,Application & Integration Servers,Application Servers...
# 2

Hello Jagadish,

Thank you for your reply. Here are the details - hopefully they will suffice:

--> Oracle Version - 10.2.02

--> Connection Pool Config:

DataSourceName = OracleConnectionPoolDataSource

ImplicitCachingEnabled = true

ConnectionCachingEnabled=true

FastConnectionFailoverEnabled=true

ONSConfiguration=nodes=<hostname>:1521,<hostname>:1521

Also note that I am using the thin driver, as opposed to oci.

I have tried various configurations, removed and added properties, etc. All to no avail.

Any suggestions are appreciated.

Thanks!

myersshawn at 2007-7-7 0:14:49 > top of Java-index,Application & Integration Servers,Application Servers...