Thursday, May 31, 2012

Re: Scaling django installation

I don't think anyone will be able to give you a good evaluation
without knowing more about the requests. Django itself could probably
handle 10k requests per second returning a simple "hello world"
response, or less than 10 if you are returning very large/difficult to
generate responses. It is what your app does that is going to make
all the difference.

The djangobook.com site has some good info on scaling, despite being
for a much older version of django. Ignore the code, and skip down
the the section on scaling:
http://www.djangobook.com/en/1.0/chapter20/

From my own experience, caching/memcache can make all the difference
in the world. Find out what is taking the time, and cache it.
Different approaches to your page design can help too. If the page is
95% identical for all users, cache the 95% and pull in the 5% with
javascript to personalize. Allowing something like varnish to sit in
front of those expensive to generate, but cachable pages is another
way to speed things up but it requires a bit of application specific
configuration to be useful (ignoring cookies for certain urls, making
sure you are setting the vary header correctly in your app, etc).

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

No comments:

Post a Comment