users@glassfish.java.net

RE: RE: Re: SQLException does not drop JDBC connection from pool

From: Markus Karg <karg_at_quipsy.de>
Date: Wed, 15 Oct 2008 11:30:13 +0200

Here it is. The funny thing is that the shown SQL is the SQL that the business application wants to run, which is working on exactly the table used to check the connection (VBFert). I do not believe that SELECT * FROM VBFert is working while SELECT DISTINCT Text FROM VBFert ist not (or the driver is doing some caching on the client side?).
 
[#|2008-10-13T08:48:21.845+0200|WARNING|sun-appserver9.1|oracle.toplink.essentials.session.file:/C:/Programme/glassfish/domains/domain1/applications/j2ee-apps/SuperSimple/SuperSimple_jar/-QUIPSY|_ThreadID=37;_ThreadName=p: thread-pool-1; w: 42;_RequestID=dba6dd82-56b7-4d6c-8f20-5ec3c278e9f6;|
Local Exception Stack:
Exception [TOPLINK-4002] (Oracle TopLink Essentials - 2.0.1 (Build b04-fcs (04/11/2008))): oracle.toplink.essentials.exceptions.DatabaseException
Internal Exception: java.sql.SQLException: [Sybase][ODBC Driver][SQL Anywhere]Server 'FMEA': [Sybase][ODBC Driver][SQL Anywhere]Verbindung wurde beendet
Error Code: -660
Call: SELECT DISTINCT Text FROM VBFert
Query: ReportQuery(de.quipsy.persistency.manufacturingMethod.ManufacturingMethod)
        at oracle.toplink.essentials.exceptions.DatabaseException.sqlException(DatabaseException.java:319)
        at oracle.toplink.essentials.internal.databaseaccess.DatabaseAccessor.basicExecuteCall(DatabaseAccessor.java:566)
        at oracle.toplink.essentials.internal.databaseaccess.DatabaseAccessor.executeCall(DatabaseAccessor.java:452)
        at oracle.toplink.essentials.threetier.ServerSession.executeCall(ServerSession.java:473)
        at oracle.toplink.essentials.internal.queryframework.DatasourceCallQueryMechanism.executeCall(DatasourceCallQueryMechanism.java:228)
        at oracle.toplink.essentials.internal.queryframework.DatasourceCallQueryMechanism.executeCall(DatasourceCallQueryMechanism.java:214)
        at oracle.toplink.essentials.internal.queryframework.DatasourceCallQueryMechanism.executeSelectCall(DatasourceCallQueryMechanism.java:285)
        at oracle.toplink.essentials.internal.queryframework.DatasourceCallQueryMechanism.selectAllRows(DatasourceCallQueryMechanism.java:615)
        at oracle.toplink.essentials.internal.queryframework.ExpressionQueryMechanism.selectAllRowsFromTable(ExpressionQueryMechanism.java:2416)
        at oracle.toplink.essentials.internal.queryframework.ExpressionQueryMechanism.selectAllReportQueryRows(ExpressionQueryMechanism.java:2382)
        at oracle.toplink.essentials.queryframework.ReportQuery.executeDatabaseQuery(ReportQuery.java:802)
        at oracle.toplink.essentials.queryframework.DatabaseQuery.execute(DatabaseQuery.java:628)
        at oracle.toplink.essentials.queryframework.ObjectLevelReadQuery.execute(ObjectLevelReadQuery.java:692)
        at oracle.toplink.essentials.queryframework.ObjectLevelReadQuery.executeInUnitOfWork(ObjectLevelReadQuery.java:746)
        at oracle.toplink.essentials.internal.sessions.UnitOfWorkImpl.internalExecuteQuery(UnitOfWorkImpl.java:2233)
        at oracle.toplink.essentials.internal.sessions.AbstractSession.executeQuery(AbstractSession.java:952)
        at oracle.toplink.essentials.internal.sessions.AbstractSession.executeQuery(AbstractSession.java:924)
        at oracle.toplink.essentials.internal.ejb.cmp3.base.EJBQueryImpl.executeReadQuery(EJBQueryImpl.java:367)
        at oracle.toplink.essentials.internal.ejb.cmp3.base.EJBQueryImpl.getResultList(EJBQueryImpl.java:478)
        at de.quipsy.application.complaint.manufacturingMethodManager.ManufacturingMethodManagerBean.getNames(ManufacturingMethodManagerBean.java:122)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at com.sun.enterprise.security.application.EJBSecurityManager.runMethod(EJBSecurityManager.java:1067)
        at com.sun.enterprise.security.SecurityUtil.invoke(SecurityUtil.java:176)
        at com.sun.ejb.containers.BaseContainer.invokeTargetBeanMethod(BaseContainer.java:2895)
        at com.sun.ejb.containers.BaseContainer.intercept(BaseContainer.java:3986)
        at com.sun.ejb.containers.EJBObjectInvocationHandler.invoke(EJBObjectInvocationHandler.java:203)
        at com.sun.ejb.containers.EJBObjectInvocationHandler.invoke(EJBObjectInvocationHandler.java:120)
        at $Proxy98.getNames(Unknown Source)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at com.sun.corba.ee.impl.presentation.rmi.ReflectiveTie._invoke(ReflectiveTie.java:154)
        at com.sun.corba.ee.impl.protocol.CorbaServerRequestDispatcherImpl.dispatchToServant(CorbaServerRequestDispatcherImpl.java:687)
        at com.sun.corba.ee.impl.protocol.CorbaServerRequestDispatcherImpl.dispatch(CorbaServerRequestDispatcherImpl.java:227)
        at com.sun.corba.ee.impl.protocol.CorbaMessageMediatorImpl.handleRequestRequest(CorbaMessageMediatorImpl.java:1846)
        at com.sun.corba.ee.impl.protocol.CorbaMessageMediatorImpl.handleRequest(CorbaMessageMediatorImpl.java:1706)
        at com.sun.corba.ee.impl.protocol.CorbaMessageMediatorImpl.handleInput(CorbaMessageMediatorImpl.java:1088)
        at com.sun.corba.ee.impl.protocol.giopmsgheaders.RequestMessage_1_2.callback(RequestMessage_1_2.java:223)
        at com.sun.corba.ee.impl.protocol.CorbaMessageMediatorImpl.handleRequest(CorbaMessageMediatorImpl.java:806)
        at com.sun.corba.ee.impl.protocol.CorbaMessageMediatorImpl.dispatch(CorbaMessageMediatorImpl.java:563)
        at com.sun.corba.ee.impl.protocol.CorbaMessageMediatorImpl.doWork(CorbaMessageMediatorImpl.java:2567)
        at com.sun.corba.ee.impl.orbutil.threadpool.ThreadPoolImpl$WorkerThread.run(ThreadPoolImpl.java:555)
Caused by: java.sql.SQLException: [Sybase][ODBC Driver][SQL Anywhere]Server 'FMEA': [Sybase][ODBC Driver][SQL Anywhere]Verbindung wurde beendet
        at ianywhere.ml.jdbcodbc.IIResultSet.next(Native Method)
        at ianywhere.ml.jdbcodbc.IResultSet.next(IResultSet.java:430)
        at oracle.toplink.essentials.internal.databaseaccess.DatabaseAccessor.basicExecuteCall(DatabaseAccessor.java:535)
        ... 44 more
|#]

> -----Original Message-----
> From: Jagadish.Ramu_at_Sun.COM [mailto:Jagadish.Ramu_at_Sun.COM]
> Sent: Mittwoch, 15. Oktober 2008 10:39
> To: users_at_glassfish.dev.java.net
> Subject: RE: Re: SQLException does not drop JDBC connection from pool
>
> pool config. seems fine.
> Can you post the exceptions from server.log too?
>
> Thanks,
> -Jagadish
>
>
> On Wed, 2008-10-15 at 08:45 +0200, Markus Karg wrote:
> > I think this is the part of domain.xml that you are interested in,
> corret?
> >
> > <jdbc-connection-pool allow-non-component-callers="false"
> associate-with-thread="false" connection-creation-retry-attempts="0"
> connection-creation-retry-interval-in-seconds="10" connection-leak-
> reclaim="false" connection-leak-timeout-in-seconds="0" connection-
> validation-method="table" datasource-
> classname="ianywhere.ml.jdbcodbc.jdbc3.ASADataSource" fail-all-
> connections="false" idle-timeout-in-seconds="300" is-connection-
> validation-required="true" is-isolation-level-guaranteed="false" lazy-
> connection-association="false" lazy-connection-enlistment="false"
> match-connections="false" max-connection-usage-count="0" max-pool-
> size="32" max-wait-time-in-millis="60000" name="QUIPSY4" non-
> transactional-connections="false" pool-resize-quantity="2" res-
> type="javax.sql.DataSource" statement-timeout-in-seconds="-1" steady-
> pool-size="8" validate-atmost-once-period-in-seconds="0" validation-
> table-name="VBFert" wrap-jdbc-objects="false">
> > <property name="URL" value="jdbc:ianywhere:DSN=QUIPSY 4
> Network"/>
> > <property name="Password" value="mypassword"/>
> > <property name="UserName" value="myusername"/>
> > </jdbc-connection-pool>
> >
> > Regards
> > Markus
> >
> > > -----Original Message-----
> > > From: Marina.Vatkina_at_Sun.COM [mailto:Marina.Vatkina_at_Sun.COM]
> > > Sent: Dienstag, 14. Oktober 2008 18:42
> > > To: users_at_glassfish.dev.java.net
> > > Subject: Re: SQLException does not drop JDBC connection from pool
> > >
> > > Copy-and-paste from the domain.xml.
> > >
> > > regards,
> > > -marina
> > >
> > > Markus Karg wrote:
> > > > Sure, but in what form do you want to get the config? I only know
> how
> > > to use admin GUI. Shall I sent all the single values, or do you
> want a
> > > file?
> > > >
> > > >
> > > >>-----Original Message-----
> > > >>From: Jagadish.Ramu_at_Sun.COM [mailto:Jagadish.Ramu_at_Sun.COM]
> > > >>Sent: Dienstag, 14. Oktober 2008 18:35
> > > >>To: users_at_glassfish.dev.java.net
> > > >>Subject: RE: Re: SQLException does not drop JDBC connection from
> pool
> > > >>
> > > >>Yes, relevant server.log & pool configuration (to see DB
> properties
> > > >>also) content should be fine.
> > > >>
> > > >>Thanks,
> > > >>-Jagadish
> > > >>
> > > >>
> > > >>On Tue, 2008-10-14 at 17:41 +0200, Markus Karg wrote:
> > > >>
> > > >>>Well, I wil do but... I don't think that you want me to send all
> the
> > > >>
> > > >>megabytes of server.log plus screenshots from the admin GUI. So
> what
> > > >>part of the server.log do you want, just the exception plus the
> > > minutes
> > > >>after it? And how to send the config? The config in fact is
> > > completely
> > > >>default plus "table check" enabled (including a table name).
> > > >>
> > > >>>Regards
> > > >>>Markus
> > > >>>
> > > >>>
> > > >>>>-----Original Message-----
> > > >>>>From: Jagadish.Ramu_at_Sun.COM [mailto:Jagadish.Ramu_at_Sun.COM]
> > > >>>>Sent: Dienstag, 14. Oktober 2008 16:57
> > > >>>>To: users_at_glassfish.dev.java.net
> > > >>>>Subject: Re: SQLException does not drop JDBC connection from
> pool
> > > >>>>
> > > >>>>Hi Markus,
> > > >>>>Could you post your pool configuration and the server.log ?
> > > >>>>
> > > >>>>Thanks,
> > > >>>>-Jagadish
> > > >>>>
> > > >>>>
> > > >>>>On Tue, 2008-10-14 at 16:13 +0200, Markus Karg wrote:
> > > >>>>
> > > >>>>>Dear Community,
> > > >>>>>
> > > >>>>>
> > > >>>>>
> > > >>>>>I have enabled "table" type connection check and added an
> > > >>
> > > >>existing
> > > >>
> > > >>>>>table. "DROP ALL" is DISABLED, so the failing connection only
> > > >>
> > > >>should
> > > >>
> > > >>>>>be dropped. Minimum pool size is 8, maximum is 32. Due to IDLE
> > > >>>>>settings, the DBMS drops the connections, so they result in
> > > >>>>
> > > >>>>exceptions
> > > >>>>
> > > >>>>>when trying to use them. The exceptions are shown in
> server.log
> > > >>
> > > >>from
> > > >>
> > > >>>>>GlassFish.
> > > >>>>>
> > > >>>>>
> > > >>>>>
> > > >>>>>But: I can try hundreds of times and never get a new
> connection,
> > > >>
> > > >>but
> > > >>
> > > >>>>>always get SQLException in the calling client. Neither are
> > > >>>>
> > > >>>>connections
> > > >>>>
> > > >>>>>dropped nor are new connections opened.
> > > >>>>>
> > > >>>>>
> > > >>>>>
> > > >>>>>What am I doing wroing? Or is that a bug?
> > > >>>>>
> > > >>>>>
> > > >>>>>
> > > >>>>>Thanks
> > > >>>>>
> > > >>>>>Markus
> > > >>>>>
> > > >>>>>
> > > >>>>>
> > > >>>>>QUIPSY QUALITY GmbH & Co. KG
> > > >>>>>
> > > >>>>>Ein Unternehmen der MES-Gruppe
> > > >>>>>
> > > >>>>>Stuttgarter Strasse 23
> > > >>>>>
> > > >>>>>D-75179 Pforzheim
> > > >>>>>
> > > >>>>>Tel: 07231-9189-52
> > > >>>>>
> > > >>>>>Fax: 07231-9189-59
> > > >>>>>
> > > >>>>>www.quipsy.de
> > > >>>>>
> > > >>>>>karg_at_quipsy.de
> > > >>>>>
> > > >>>>>Registergericht Mannheim HRA 701214
> > > >>>>>
> > > >>>>>Geschäftsführer: Nils Schroeder
> > > >>>>>
> > > >>>>>
> > > >>>>>
> > > >>>>>Diese E-Mail enthält persönliche, vertrauliche und vor
> Weitergabe
> > > >>>>>geschützte Informationen und ist ausschließlich für den
> > > >>
> > > >>vorgesehenen
> > > >>
> > > >>>>>o.g. Empfänger (Adressaten) bestimmt. Falls Sie diese E-Mail
> > > >>>>>versehentlich erhalten haben und nicht der vorgesehene
> Empfänger
> > > >>>>
> > > >>>>sind,
> > > >>>>
> > > >>>>>bitten wir Sie, die E-Mail und deren Anhänge nicht
> aufzubewahren,
> > > >>>>>nicht zu vervielfältigen, nicht zu nutzen und nicht
> > > >>
> > > >>weiterzugeben.
> > > >>
> > > >>>>>Bitte informieren Sie uns als Absender über diesen
> > > >>
> > > >>Zustellungsfehler
> > > >>
> > > >>>>>und löschen Sie die E-Mail.
> > > >>>>>
> > > >>>>>
> > > >>>>>
> > > >>>>>
> > > >>>>>
> > > >>>>>
> > > >>>>>
> > > >>>>>
> > > >>>>>
> > > >>>>>
> > > >>>>>--------------------------------------------------------------
> ---
> > > >>
> > > >>----
> > > >>
> > > >>>>>To unsubscribe, e-mail: users-
> unsubscribe_at_glassfish.dev.java.net
> > > >>>>>For additional commands, e-mail: users-
> > > >>
> > > >>help_at_glassfish.dev.java.net
> > > >>
> > > >>>>
> > > >>>>---------------------------------------------------------------
> ----
> > > >>
> > > >>--
> > > >>
> > > >>>>To unsubscribe, e-mail: users-
> unsubscribe_at_glassfish.dev.java.net
> > > >>>>For additional commands, e-mail: users-
> help_at_glassfish.dev.java.net
> > > >>>
> > > >>
> > > >>-----------------------------------------------------------------
> ----
> > > >>To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
> > > >>For additional commands, e-mail: users-
> help_at_glassfish.dev.java.net
> > > >
> > > >
> > >
> > >
> > > -------------------------------------------------------------------
> --
> > > To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
> > > For additional commands, e-mail: users-help_at_glassfish.dev.java.net
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: users-help_at_glassfish.dev.java.net