After switching threadsafe to true in my app.yaml, I had some concurrency 
issues (detailed in this SO question, here 
:http://stackoverflow.com/questions/16966365/in-python-does-dummythread-uniquely-identify-the-current-thread).
 
Using threading.currentThread() with a thread-local storage approach got 
rid of my immediate problem, but raised an issue that I'm not sure about :

The threads AppEngine creates are outside of threading.py's control, so 
Python creates these immortal DummyThread objects to represent them when 
you call threading.currentThread.

My thinking on this was that even if DummyThread objects never die and thus 
create a memory leak, AppEngine probably doesn't create enough threads and 
our application is updated frequently enough (once per week, on average), 
that the number of DummyThreads will be unlikely to grow beyond a certain 
point and thus any memory leak resulting from DummyThreads will be 
insignificant.

I'm really not sure whether I'm in for a world of hurt eventually here or 
whether I should be ok. I'd love to hear some opinions/comments on why this 
is a good/bad idea, or maybe some suggestions of an alternate approach.

-- 
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