You will not have the delay if you query for your data with an
ancestor query. This page explains: 
http://code.google.com/appengine/docs/java/datastore/hr/overview.html

"Ancestor queries work because entity groups are a unit of
consistency: all operations are applied to the entire group. Ancestor
queries won't return data until the entire entity group is up to date.
Thus, the data returned from ancestor queries on entity groups is
strongly consistent.

If your application relies on strongly consistent results for certain
queries, you may have to change the way your application stores
entities."

And at the bottom of that page it adds...

"Remember, if you do a get(), put(), or a transaction, you will always
see the most recently written data."

Note that a query in a transaction must be an ancestor query.

Broc



On Oct 27, 12:34 pm, markabrucey <[email protected]> wrote:
> Hi,
>
> I have been doing a lot of reading on Ancestor queries because we are
> currently trying to transfer from Master / Slave to the High Replication
> datastore.
>
> We have noticed while testing on the HRDS, that sometimes when adding an
> entity and redirecting the view to show that entity (or maybe a list
> containing others as well), it can take a while for it to update because it
> is eventually consistent. (which is sometimes inconvenient)
>
> I understand that you can not put an entity into an entity group once
> already created, the process of creating that entity so it is in a group
> has to be done the first time round.
>
> I was just wondering that if we kept our older entities and started doing
> ancestor queries to insert new ones, can we merge the results to produce
> and output? I think if we can, it will have to be done in 2 queries, and if
> it can, will we no longer see a delay in data being updated?
>
> Thanks,
> Mark

-- 
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 [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.

Reply via email to