Hi there,
Ever since I am using GLORP for my Seaside based work in VAST, I am getting into trouble with Session cleanup in GLORP. What happens? If a Seaside session expires, it is not instantly cleaned up. It will be cleaned up when a new one is created. So after my (not in production yet) application has been inactive for a while, the first access to the DB with GLORP results in a Primitive failed in: PlatformFunction>>#callWithArguments: due to General protection fault - read from invalid memory location The called primitive is: <c: int16 'odbc32':SQLEndTran uint16 uint32 uint16> And here is the relevant part of the Stack Trace: PlatformFunction>>#callWithArray: self=<c: int16 'odbc32':SQLEndTran uint16 uint32 uint16> parmArray=(2 24960872 1) AbtOdbcDatabaseManager>>#callPlatformFunction:withArray:useThreadPreference:threadKey: self=an AbtOdbcDatabaseManager aFunction=56 anArray=(2 24960872 1) aBool=true aThreadKey=an AbtWorkQueue rc=nil workQueue=an AbtWorkQueue AbtOdbc30DatabaseConnection(AbtDatabaseConnection)>>#callPlatformFunction:withArray:useThreadPreference:threadKey: self=an AbtOdbc30DatabaseConnection aFunction=56 anArray=(2 24960872 1) aBool=true aThreadKey=an AbtWorkQueue AbtOdbc30DatabaseConnection>>#rollbackTransactionIfError: self=an AbtOdbc30DatabaseConnection anErrorBlock=[] in VADatabaseAccessor>>#loginIfError: rc=nil AbtOdbc30DatabaseConnection(AbtOdbcDatabaseConnection)>>#rollbackUnitOfWorkIfError: self=an AbtOdbc30DatabaseConnection anErrorBlock=[] in VADatabaseAccessor>>#loginIfError: AbtOdbc30DatabaseConnection(AbtDatabaseConnection)>>#rollbackUnitOfWork self=an AbtOdbc30DatabaseConnection VADatabaseAccessor>>#rollbackTransaction self=a VADatabaseAccessor [] in GlorpSession>>#rollbackTransaction self=a GlorpSession My guess is that there is some problem between GLORP and the ODBC library because the connection that was used by the GLORP session is invalid in the meantime. And that is probably my fault, because I should check for *something* before I rollback my Transactions. But as I said, the point in time when this happens is determined by Seaside, and I have little chance to influence this. What can I do to check if there is something that can be rolled back "after such a long time" (we're speaking of 10, 15 or 20 minutes of inactivity)? And what about the OS resources? Do I have an obligation and chance to clean something up? It's no problem to terminate the process and click again, everything works fine after this error: a new GLORP session is established and the application works like a charm. Until a session gets cleaned up after a long time again... Sorry if this question is a bit open and blurry. Any pointers are welcome! Joachim -- You received this message because you are subscribed to the Google Groups "VA Smalltalk" group. To view this discussion on the web visit https://groups.google.com/d/msg/va-smalltalk/-/K1geNsif6H4J. To post to this group, send email to [hidden email]. To unsubscribe from this group, send email to [hidden email]. For more options, visit this group at http://groups.google.com/group/va-smalltalk?hl=en. |
Joachim,
I find it strange, that in a SQL environment, someone works with so long transactions !? I thought, that this is something like do-not under SQL. I would say, that your statements are running into a timeout of your db system (by the way: what DB are you using ?) Marten -- You received this message because you are subscribed to the Google Groups "VA Smalltalk" group. To view this discussion on the web visit https://groups.google.com/d/msg/va-smalltalk/-/4BEu9YaaXK4J. To post to this group, send email to [hidden email]. To unsubscribe from this group, send email to [hidden email]. For more options, visit this group at http://groups.google.com/group/va-smalltalk?hl=en. |
Hi Marten,
these typically aren't Transactions on the DB level, just on the Smalltalk level. GLORP forwards a rollback to the Database even if there's nothing to rollback (I guess it does so "just in case" - maybe current versions of GLORP don't, but this ancient version is what we have available in VAST). This is typically not a problem at all, only if the sessions are older than, say, 20 minutes. In my scenario it s MS ACCESS, because it's available on all machines I work on without any effort. Joachim
-- You received this message because you are subscribed to the Google Groups "VA Smalltalk" group. To view this discussion on the web visit https://groups.google.com/d/msg/va-smalltalk/-/fN8GWJuRfSYJ. To post to this group, send email to [hidden email]. To unsubscribe from this group, send email to [hidden email]. For more options, visit this group at http://groups.google.com/group/va-smalltalk?hl=en. |
In reply to this post by jtuchel
Hi again,
It seems I have found a solution/workaround: https://groups.google.com/d/msg/glorp-group/LlglTp3q-g8/UAyFeSAt0W0J I currently ask the GlorpSession if it currently is in a DB Transaction and only if it is (which it's not most of the time), I roll it back (so most likely never). Thus I can avoid the GPF error, and hope that Windows has done the right thing that lead to the invalid handle... Joachim -- You received this message because you are subscribed to the Google Groups "VA Smalltalk" group. To view this discussion on the web visit https://groups.google.com/d/msg/va-smalltalk/-/IpJlhpzF_iQJ. To post to this group, send email to [hidden email]. To unsubscribe from this group, send email to [hidden email]. For more options, visit this group at http://groups.google.com/group/va-smalltalk?hl=en. |
Free forum by Nabble | Edit this page |