In one of my Django projects, I use the dispatcher and signals to  
notify various apps that the front page has been viewed. Some of  
these apps run a method on the raising of this signal to see if it's  
been more than X minutes since the last time the method has been run.  
If the method was run over X minutes ago, it calls another method  
which calls on various API services on the internet (flickr,  
Ma.gnolia, etc) and synchronizes some of my database tables with  
random junk.

Sometimes, the API calls can take some time (Ma.gnolia, I'm talking  
to you!), which ends up making the user visiting my front page wait  
until all the API calls are done running before the front page loads.

Is there a way to avoid this by executing the synchronization methods  
in another thread or by somehow backgrounding them?

Regards,
Tyson Tate

-- 
Tyson Tate
- CalPoly Graphic Design Student
- Work: Graphic Designer (CalPoly Library)
- Play: Mustang Band, CalPoly Triathlon Team, Kappa Kappa Psi (Iota Pi)



--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users
-~----------~----~----~----~------~----~------~--~---

Reply via email to