Be sure also that modifyObject does not make indirectly calls to
datastore.
It was the case in one of my handlers, where the call to modify
checked users authorizations, and those were occasionally read from
datastore when memcache expired.
That resulted in an exception in entity group handling.

Logs are usually useful to detect some of these behaviors.

regards
Lorenzo


On Jul 22, 3:07 am, "Ikai L (Google)" <ika...@google.com> wrote:
> Can you start the transaction before you do the fetch? The way you're
> writing it won't result in what you want to do.
>
> If that still doesn't work, just retrieve a new instance of the
> PersistenceManager. This is cheap so it won't cost you significant
> additional CPU.
>
>
>
> On Mon, Jul 19, 2010 at 5:59 AM, coltsith <conla...@gmail.com> wrote:
> > Here's the psudo-code for one of my methods:
>
> > 1. Get PersistenceManager (pm)
>
> > 2. pm.fetchObject1
>
> > 3. pm.beginTransaction
>
> > 4. pm.modifyObject1
>
> > 5. pm.commit
>
> > 6. pm.fetchObject2
>
> > 7. pm.beginTransaction
>
> > 8. pm.modifyObject2
>
> > 9. pm.commit
>
> > however I get this error "can't operate on multiple entity groups in a
> > single transaction..."
>
> > Do I have to put another line in between step 5 and 7 saying that I'm
> > 'done' with object1, like to close it?
>
> > Thanks
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Google App Engine for Java" group.
> > To post to this group, send email to
> > google-appengine-j...@googlegroups.com.
> > To unsubscribe from this group, send email to
> > google-appengine-java+unsubscr...@googlegroups.com<google-appengine-java%2bunsubscr...@googlegroups.com>
> > .
> > For more options, visit this group at
> >http://groups.google.com/group/google-appengine-java?hl=en.
>
> --
> Ikai Lan
> Developer Programs Engineer, Google App Engine
> Blog:http://googleappengine.blogspot.com
> Twitter:http://twitter.com/app_engine
> Reddit:http://www.reddit.com/r/appengine

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to google-appengine-j...@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.

Reply via email to