Incorrect synchronization leading to org.hsqldb.HsqlException: statement is closed

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Incorrect synchronization leading to org.hsqldb.HsqlException: statement is closed

lewis john mcgibbney
Hi Everyone,

First post on this list, so looking forward to learning a good bit from you guys.
I'm currently trying to resolve a particular Jira issue [1] within the Apache Gora project and could really do with some guidance from the community as to where I should be focusing my attention and effort.

Currently, the gora-sql module in question can be found here [2] and a comprehensive description of the problem can be found in [1] above N.B. the SqlUtils.close() method can be found here [3]. Additionally. The problem I'm having when looking at our SqlStore [4] implementation is that I can't, for the life of me, see how to fix the synchronization logic which is obviously ignorant of the fact that closed statements are still trying to execute.

I fully understand that this is not 100% hsqldb specific, however I'm hoping that by reaching out to the community maybe someone can provide detail on how this can be overcome, or at least to suggest some points of views based on the problem.

Thank you very much in advance for any help.

Lewis

[1] https://issues.apache.org/jira/browse/GORA-84
[2] http://svn.apache.org/viewvc/gora/trunk/gora-sql/
[3] http://svn.apache.org/viewvc/gora/trunk/gora-sql/src/main/java/org/apache/gora/sql/util/SqlUtils.java?view=markup
[4] http://svn.apache.org/viewvc/gora/trunk/gora-sql/src/main/java/org/apache/gora/sql/store/SqlStore.java?view=markup
--
Lewis


------------------------------------------------------------------------------
Virtualization & Cloud Management Using Capacity Planning
Cloud computing makes use of virtualization - but cloud computing
also focuses on allowing computing to be delivered as a service.
http://www.accelacomm.com/jaw/sfnl/114/51521223/
_______________________________________________
Hsqldb-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/hsqldb-user
Reply | Threaded
Open this post in threaded view
|

Re: Incorrect synchronization leading to org.hsqldb.HsqlException: statement is closed

Fred Toussi-2
Please use HSQLDB 2.2.8 as there was a problem fixed after 2.2.4 was released (the problem was identical statements belonging to different connections would all get closed if one of them was closed).
 
If you still have a problem, then make sure your code is using one connection per thread and each statement is used exclusively by the thread+connection that created the statement.
 
Fred
 
 
On Sun, Feb 12, 2012, at 13:27, Lewis John Mcgibbney wrote:
Hi Everyone,

First post on this list, so looking forward to learning a good bit from you guys.
I'm currently trying to resolve a particular Jira issue [1] within the Apache Gora project and could really do with some guidance from the community as to where I should be focusing my attention and effort.

Currently, the gora-sql module in question can be found here [2] and a comprehensive description of the problem can be found in [1] above N.B. the SqlUtils.close() method can be found here [3]. Additionally. The problem I'm having when looking at our SqlStore [4] implementation is that I can't, for the life of me, see how to fix the synchronization logic which is obviously ignorant of the fact that closed statements are still trying to execute.

I fully understand that this is not 100% hsqldb specific, however I'm hoping that by reaching out to the community maybe someone can provide detail on how this can be overcome, or at least to suggest some points of views based on the problem.

Thank you very much in advance for any help.

Lewis

[1] https://issues.apache.org/jira/browse/GORA-84
[2] http://svn.apache.org/viewvc/gora/trunk/gora-sql/
[3] http://svn.apache.org/viewvc/gora/trunk/gora-sql/src/main/java/org/apache/gora/sql/util/SqlUtils.java?view=markup
[4] http://svn.apache.org/viewvc/gora/trunk/gora-sql/src/main/java/org/apache/gora/sql/store/SqlStore.java?view=markup
--
Lewis

------------------------------------------------------------------------------
Virtualization & Cloud Management Using Capacity Planning
Cloud computing makes use of virtualization - but cloud computing 
also focuses on allowing computing to be delivered as a service.
http://www.accelacomm.com/jaw/sfnl/114/51521223/
_______________________________________________
Hsqldb-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/hsqldb-user

 

------------------------------------------------------------------------------
Try before you buy = See our experts in action!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-dev2
_______________________________________________
Hsqldb-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/hsqldb-user
Reply | Threaded
Open this post in threaded view
|

Re: Incorrect synchronization leading to org.hsqldb.HsqlException: statement is closed

lewis john mcgibbney
In reply to this post by lewis john mcgibbney
Hi Fred,

Thsi is great feedbacl thank you for the heads up. I'll upgrade, replicate the case and post pack with our results.
Thanks again

Lewis
Please use HSQLDB 2.2.8 as there was a problem fixed after 2.2.4
was released (the problem was identical statements belonging to
different connections would all get closed if one of them was
closed).

If you still have a problem, then make sure your code is using
one connection per thread and each statement is used exclusively
by the thread+connection that created the statement.

Fred


------------------------------------------------------------------------------
Try before you buy = See our experts in action!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-dev2
_______________________________________________
Hsqldb-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/hsqldb-user