I have a batch processing Backend (B4) which does a bunch of 
unpickle/pickle and Numpy/array stuff. Recently I noticed that I was 
getting much higher backend charges, which would hit quota almost every 
time, so I migrated to Modules (also B4), thinking that might solve it.
However, I still see the same issue:

2013-08-05 15:23:33.962 /BatchRankings 500 19413478ms 0kb instance=0 
AppEngine-Google; (+http://code.google.com/appengine)

I 2013-08-05 10:00:04.118
mem usage at start of meleerumble: 24.55078125MB

... lots more logs ...

I 2013-08-05 10:01:03.549
mem usage after zipping: 157.08984375MB

I 2013-08-05* 10:01:03.550*
split bots into 18 sections

I 2013-08-05 *15:23:03.086*
wrote 564 bots to memcache

E 2013-08-05 15:23:33.962
Process terminated because the backend took too long to shutdown.

Look at the timestamp between splitting and writing to memcache.

In addition, in my logs just below the actual request handler, I see this:
2013-08-05 *15:23:02.938* /_ah/stop 200 5ms 0kb instance=0 

So, from what I can tell, it looks like the backend hangs inside of the 
memcache writing, and the /_ah/stop wakes it up when I hit my quota.

Here is the relevant code between those two logging points:

                client = memcache.Client()
                if len(botsdict) > 0:
                    splitlist = dict_split(botsdict,32)
                    logging.info("split bots into " + str(len(splitlist)) + 
" sections")
                    
                    for d in splitlist:
                        rpcList.append(client.set_multi_async(d))
                    
                    logging.info("wrote " + str(len(botsdict)) + " bots to 
memcache")

I don't see how 18 set_multi_async calls can take 5h23m. Can the logs be 
trusted here? Could it be that the actual code is finished but somehow the 
exit never registered and the logging was the problem? I'm having to 
disable my backend processing because of this, since it just eats as much 
quota as I throw at it.

Any help regarding what on earth is happening here would be much 
appreciated.

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-appengine.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to