users@glassfish.java.net

Problem with Glassfish 2.1, Hibernate and MySQL on Windows XP

From: Elad Mallel <themellel_at_gmail.com>
Date: Sat, 21 Feb 2009 14:53:31 +0200

Hey everyone,

 

I'm using Glassfish v2.1 with Hibernate against a MySQL database on Windows
XP. I'm using the 5.1.7 version of the MySQL JDBC library.

I'm having trouble performing the simplest task of selecting an object from
the database.

The exception I get is this:

Caused by: java.lang.IllegalArgumentException: null source

            at java.util.EventObject.<init>(EventObject.java:38)

            at javax.sql.StatementEvent.<init>(StatementEvent.java:39)

            at
com.mysql.jdbc.jdbc2.optional.JDBC4PreparedStatementWrapper.close(JDBC4Prepa
redStatementWrapper.java:70)

            at
org.hibernate.jdbc.AbstractBatcher.closePreparedStatement(AbstractBatcher.ja
va:534)

            at
org.hibernate.jdbc.AbstractBatcher.closeStatement(AbstractBatcher.java:269)

            at
org.hibernate.jdbc.AbstractBatcher.closeQueryStatement(AbstractBatcher.java:
285)

            at
org.hibernate.jdbc.AbstractBatcher.closeQueryStatement(AbstractBatcher.java:
212)

            at org.hibernate.loader.Loader.doQuery(Loader.java:726)

            at
org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.ja
va:236)

            at org.hibernate.loader.Loader.doList(Loader.java:2220)

            at
org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2104)

            at org.hibernate.loader.Loader.list(Loader.java:2099)

            at
org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:378)

            at
org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:338)

            at
org.hibernate.engine.query.HQLQueryPlan.performList(HQLQueryPlan.java:172)

            at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1121)

            at org.hibernate.impl.QueryImpl.list(QueryImpl.java:79)

            at
org.hibernate.ejb.QueryImpl.getSingleResult(QueryImpl.java:81)

            at
application.ApplicationManagerBean.createApplicationResponse(ApplicationMana
gerBean.java:30)

            ... 56 more

 

 

It's important to mention that if I run the exact same code on Glassfish
2ur1, it works perfectly.

 

Can anyone tell me what's up with this? Is this a known issue? When will a
solution be available?

 

Thanks,

Elad.