Question 1: Would this work with views, or for that matter, anything
else in Django, assuming you're using a WSGI server like gunicorn?
http://code.activestate.com/recipes/578078/  Specifically, will it
cache across HTTP requests, or not?

I guess the one thing I don't understand well in Django is when
modules are re-loaded.  I know it's different in a "full-fledged"
setup vs. the test server, but is there a rule one can follow? Is it
different on WSGI vs. FastCGI?

And finally, if I delete a module from sys.modules, does that
effectively delete it from the cache or is there something else I need
to do to make sure it's reloaded the next time someone makes a
request?  I would assume that deleting the module from sys.modules
would only delete it from one worker process.  Is there an accepted
way to get a module to reload across all processes?

What I'm trying to do is allow a user to create models on the fly by
uploading data.  One answer is just to have a post_save signal call
supervisorctl and restart the webservices, but that seems nonportable
and rather broken.  There's got to be a better way.

-- 
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 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to