Gosts objects

Norberto Manzanos nmanzanos at gmail.com
Fri Sep 21 19:30:48 UTC 2007


It's very difficult to replicate the whole situation. I just wanted to know
wether it could be somethig wrong in the files, not in the
objects in memory for this malcfunction. Could be a unfinished transaction
waiting in the files for return to live? Because I didn't  created any extra
transaction, just only one.
I was testing wether the problem could be in a session that remain in
memory.  I wrote this test.

test00OpenSessions

| session1 session2 |
MagmaSession disconnectAndCloseAllConnectedSessions.
MagmaSession cleanUp.
Smalltalk garbageCollect.
self assert: MagmaSession allInstances isEmpty.
session1:=  MagmaSession openLocal: '\Squeak 3.9\magma'.
session1 connectAs: 'User1' asString.
self assert: MagmaSession allInstances size = 2. "it fails. There is an
extra session with id=nil, user=nil. Is it normal? "
session2:=MagmaSession openLocal:  '\Squeak 3.9\magma'.
session2 connectAs: 'User2' asString.
self assert: MagmaSession allInstances size = 3. "idem"




Regards
Norberto

On 9/13/07, Chris Muller <asqueaker at gmail.com> wrote:
>
> Norberto, given the lack of specific information, I can only speculate
> from my gut that you were in a transaction more than one-level deep.
> In that case, all changes remain solely in memory until you execute
> the outermost #commit and you will not see any change in the
> repository files until then.
>
> You said it wasn't the first time you've encountered a problem, so
> would you please retrace your steps, documenting them into a script I
> can follow that demonstrates a problem?  I would be happy to be help.
>
> Regards,
>   Chris
>
>
>
> On 9/13/07, Norberto Manzanos <nmanzanos at gmail.com> wrote:
> > Hi Chris and people.
> >
> > Something really strange has just happened with Magma.
> >
> > I had a repository. One of its collections had about 11000 objects.
> > I made a massive adding of about 600 objects. 10 objects per
> > transaction, refreshPersistentObjects... seting to false, readStrategy
> > with depth 0.
> > When the process finished, the size of the collection was about 11600.
> > I noticed the files of the repository hadn't change. When I closed the
> > session the collection size was 11000 again. Where were the other? I
> > tried sending an #abort (but the whole process was inside
> > transactions,so, what for?), then I sent a #cleanUp to MagmaSession (I
> > don't known why, magic perhaps). Surprisingly, when I reconnected the
> > session and requested the size again, it was 600!. I swear I didn't
> > drink nothing but coffee, but when I closed and reconnected the
> > session one more time, the collection had the 11000 of the beginning.
> > The objects file hadn't changed and the size of the squeak image was
> > about 150 Mb. So, they were allways in memory ... but where exactly?
> > There was only one instance of MagmaRepositoryController and two
> > instances of MagmaSession, one my session, and a __system session.
> >
> > This is not the first time that many objects disapears in the air.
> > What I really want to understand is what could be the reason that
> > several #add: to the repository inside a transaction could not be
> > actually saved in the files and keeps in memory.
> >
> > Thanks in advance.
> > Norberto
> > _______________________________________________
> > Magma mailing list
> > Magma at lists.squeakfoundation.org
> > http://lists.squeakfoundation.org/mailman/listinfo/magma
> >
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/magma/attachments/20070921/47802a69/attachment.htm


More information about the Magma mailing list