Tuesday, July 10, 2012

Re: These features would make CloudSQL a killer solution: replicated n-instances for reads and async queries

Probably not since these queries are part of handling a user request.  

However async URLFetches could do the trick.  I might give that a try soon; my query result objects are fairly simple (DataStore keys + a couple measures) and I suppose if I return as json I can marshal back to java fairly efficiently.  Maybe not a huge optimization yet since my tables are small and each of the 4 queries is taking under 5 ms, but as they grow each might start taking 30, 50 or even 100ms and then parallelizing will really pay off.

-m


On Mon, Jul 9, 2012 at 10:06 PM, Joe Faith <joefaith@google.com> wrote:
Hi Mauricio

On Thu, Jul 5, 2012 at 4:17 PM, Mauricio Aristizabal <aristim@gmail.com> wrote:

Some searches will involve querying multiple shards.  Right now this is done sequentially.  It would be great if I could send n number of queries asynchronously to execute in parallel, just like in GAE's datastore.  I suppose I could create a light wrapper and then use n async URLFetches against my own app, but I'd have to serialize and deserialize my resultsets somehow.  That's my backup plan, but it would be great for this to be supported right in the API.

Has anyone dealt with these issues already? I couldn't find open issues for these in the tracker, is this something I should open a new issue on?

Would it be possible to execute the queries in parallel using task queues?

j


No comments:

Post a Comment