Seaside icon indicating copy to clipboard operation
Seaside copied to clipboard

notTranlogged feature for GemStone

Open dalehenrich opened this issue 9 years ago • 5 comments

With GemStone 3.3 and Seaside3.2.x I plan to introduce a not tranlogged option for session state using the NotTranloggedGlobals persistent root. NotTranloggedGlobals are persistent objects that are not written to the tranlogs and do not survive a stone shutdown/restart.

The thought is that one can afford to lose seaside session state if the stone crashes or is shutdown - similar to what happens when a pharo vm is cycled. For systems with high commit volume, reducing the volume of data written to tranlogs can result in higher commit rates, since disk i/o can be a limiting factor. For systems with low commit rates, reducing the volume of data written to disk can minimize the headaches of managing large tranlogs....

dalehenrich avatar Jul 17 '15 19:07 dalehenrich

In order to root session state in NotTranloggedGlobals it is necessary to break the direct reference link from the tranlogged (normal) objects and the notTranlogged objects. In my experiments to date, I've broken the link at the continuations instance variable in WASession ... the gotcha is that the continuations instance variable is directly referenced ... it would be more convenient if the continuations instance variable was referenced by message sends so that I could create a WANotTranloggedSession subclass and simply override the setter/getter methods for continuations.

So I'm curious if this change can be made for Seaside3.2 or not...

The other candidate is the cache instance variable in WARegistry (for a WANotTranloggedApplication), but WARegistry does not directly access cache quite as much, but again it would be more convenient to intercept the cache setter so that I could arrange to hooke the cache into NotTranloggedGlobals ...

barring these changes I could consider creating specialized WAHashCache and WABulkReapingCache classes, but I think that it would be cleaner to not have to monkey with the implementation of the cache and change roots at the spot where the notTranlogged session state touches the tranlogged state ...

Thoughts?

dalehenrich avatar Jul 17 '15 19:07 dalehenrich

Here's a link to diffs for the work that I had done so far for Seaside 3.1 ... ignore the WANotTranloggedCache as that was my initial starting point and it turned out that I had to make way too many changes to the implementation of WACache due to direct instance variable refs and changes needed for NotTranloggedGlobals purposes.

dalehenrich avatar Jul 17 '15 19:07 dalehenrich

I think that this change in WASnapshot was the only change that I needed to make outside of the WASession class, so far, but I had not completed the implementation ...

dalehenrich avatar Jul 17 '15 19:07 dalehenrich

In order for NotTranloggedGlobals to work, there is a rule that tranlogged objects cannot reference notTranlogged objects, while it is legal for notTranlogged objects to reference tranlogged objects....

The change made to WASnapshot was necessary to avoid having tranlogged objects reference notTranlogged objects ... but as I said the work is not really close to finished, so I might be able to addresss the WASnapshot problem in different ways ...

It is important to note that I have yet to prove that I can isolate a significant enough fraction of the session state to make using NotTranloggedGlobals worthwhile..

dalehenrich avatar Jul 17 '15 19:07 dalehenrich

With 3.2 all the necessary pieces are in place. Remove from milestone.

marschall avatar Aug 26 '16 13:08 marschall