Menu

UnsupportedOperationException

2014-12-18
2014-12-18
  • M. Rahil Rafiq

    M. Rahil Rafiq - 2014-12-18

    I am using c3p0 with olap4j to create connection pool in tomcat.

    I am using the following jars

    c3p0-0.9.5-pre5.jar
    mchange-commons-java-0.2.6.2.jar
    olap4j-1.2.0.jar
    olap4j-1.2.0-sources.jar
    olap4j-tck-1.2.0.jar
    olap4j-xmla-1.2.0.jar
    xerces-2.9.1.jar

    I have JNDI resource in context.xml like this...

    <Resource name="jdbc/olap" auth="Container" type="com.mchange.v2.c3p0.ComboPooledDataSource" factory="org.apache.naming.factory.BeanFactory" driverClass="org.olap4j.driver.xmla.XmlaOlap4jDriver" jdbcUrl="jdbc:xmla:Server=http://OLAP-DB/OLAP/msmdpump.dll;Catalog=Clm_Data" user="***" password="***"/>

    I am getting the following exception.

    Dec 18, 2014 2:47:20 PM com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool
    WARNING: A PooledConnection was acquired, but an Exception occurred while preparing it for use. Attempting to destroy.
    java.sql.SQLException: An SQLException was provoked by the following failure: java.lang.UnsupportedOperationException
    at com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:118)
    at com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:77)
    at com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:74)
    at com.mchange.v2.c3p0.impl.NewPooledConnection.handleThrowable(NewPooledConnection.java:505)
    at com.mchange.v2.c3p0.impl.NewProxyConnection.getWarnings(NewProxyConnection.java:1432)
    at com.mchange.v2.c3p0.SQLWarnings.logAndClearWarnings(SQLWarnings.java:54)
    at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool$1PooledConnectionResourcePoolManager.acquireResource(C3P0PooledConnectionPool.java:251)
    at com.mchange.v2.resourcepool.BasicResourcePool.doAcquire(BasicResourcePool.java:1086)
    at com.mchange.v2.resourcepool.BasicResourcePool.doAcquireAndDecrementPendingAcquiresWithinLockOnSuccess(BasicResourcePool.java:1073)
    at com.mchange.v2.resourcepool.BasicResourcePool.access$800(BasicResourcePool.java:44)
    at com.mchange.v2.resourcepool.BasicResourcePool$ScatteredAcquireTask.run(BasicResourcePool.java:1810)
    at com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread.run(ThreadPoolAsynchronousRunner.java:696)
    Caused by: java.lang.UnsupportedOperationException
    at org.olap4j.driver.xmla.XmlaOlap4jConnection.getWarnings(XmlaOlap4jConnection.java:589)
    at com.mchange.v2.c3p0.impl.NewProxyConnection.getWarnings(NewProxyConnection.java:1418)
    ... 7 more

    Anyone have any idea?

    Thanks

     

    Last edit: M. Rahil Rafiq 2014-12-18
    • Julian Hyde

      Julian Hyde - 2014-12-18

      It’s quite simple - getWarnings is not implemented in the XMLA driver. Can you log a bug.

      On Dec 18, 2014, at 2:36 AM, M. Rahil Rafiq rahilrafiq101@users.sf.net wrote:

      I am using c3p0 with olap4j to create connection pool in tomcat.

      I am using the following jars

      c3p0-0.9.5-pre5.jar
      mchange-commons-java-0.2.6.2.jar
      olap4j-1.2.0.jar
      olap4j-1.2.0-sources.jar
      olap4j-tck-1.2.0.jar
      olap4j-xmla-1.2.0.jar
      xerces-2.9.1.jar

      I have JNDI resource in context.xml like this...

      <Resource name="jdbc/olap" auth="Container" type="com.mchange.v2.c3p0.ComboPooledDataSource" factory="org.apache.naming.factory.BeanFactory" driverClass="org.olap4j.driver.xmla.XmlaOlap4jDriver" jdbcUrl="jdbc:xmla:Server=http://OLAP-DB/OLAP/msmdpump.dll;Catalog=Clm_Data" user="iis" password="Sol@123"/>

      I am getting the following exception.

      Dec 18, 2014 2:47:20 PM com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool
      WARNING: A PooledConnection was acquired, but an Exception occurred while preparing it for use. Attempting to destroy.
      java.sql.SQLException: An SQLException was provoked by the following failure: java.lang.UnsupportedOperationException
      at com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:118)
      at com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:77)
      at com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:74)
      at com.mchange.v2.c3p0.impl.NewPooledConnection.handleThrowable(NewPooledConnection.java:505)
      at com.mchange.v2.c3p0.impl.NewProxyConnection.getWarnings(NewProxyConnection.java:1432)
      at com.mchange.v2.c3p0.SQLWarnings.logAndClearWarnings(SQLWarnings.java:54)
      at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool$1PooledConnectionResourcePoolManager.acquireResource(C3P0PooledConnectionPool.java:251)
      at com.mchange.v2.resourcepool.BasicResourcePool.doAcquire(BasicResourcePool.java:1086)
      at com.mchange.v2.resourcepool.BasicResourcePool.doAcquireAndDecrementPendingAcquiresWithinLockOnSuccess(BasicResourcePool.java:1073)
      at com.mchange.v2.resourcepool.BasicResourcePool.access$800(BasicResourcePool.java:44)
      at com.mchange.v2.resourcepool.BasicResourcePool$ScatteredAcquireTask.run(BasicResourcePool.java:1810)
      at com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread.run(ThreadPoolAsynchronousRunner.java:696)
      Caused by: java.lang.UnsupportedOperationException
      at org.olap4j.driver.xmla.XmlaOlap4jConnection.getWarnings(XmlaOlap4jConnection.java:589)
      at com.mchange.v2.c3p0.impl.NewProxyConnection.getWarnings(NewProxyConnection.java:1418)
      ... 7 more

      Anyone have any idea?

      Thanks

      UnsupportedOperationException

      Sent from sourceforge.net because you indicated interest in https://sourceforge.net/p/olap4j/discussion/577988/

      To unsubscribe from further messages, please visit https://sourceforge.net/auth/subscriptions/

       

Log in to post a comment.