← Back to team overview

mugle-dev team mailing list archive

Re: Delete UserGameProfile

 

Well I've dug a bit. You were quite right. It does seem to be the UGP
getter. But I'm confused. What do you know about the persistencemanager and
transactions? See the bug:
https://bugs.launchpad.net/mugle/+bug/788592

The error I am getting is this:
can't operate on multiple entity groups in a single transaction. found both
Element { type: "UserGameProfileData" id: 389 } and Element { type:
"GameData" id: 3 }

So this means there is a single transaction which is writing to both UGP and
Game. That makes perfect sense, except that *we never asked for a
transaction*.

In GAE, transactions are only allowed to refer to a single entity group, but
we aren't using transactions. So I'm confused. If you look, the exception is
actually coming up on the line where the pm is closed, all the way up in the
key value manager.

Do you think that JDO is saving up all the changes made to that persistence
manager and then committing them all at once in a single transaction? If
that's the case, I'm shocked we haven't run into this before. What that
means is that each PM is only allowed to touch a single element, and if you
want to touch more, you need to open more PMs. Do you think that could be
it? I'm sure we've touched multiple elements with a single PM before.

References