We are hosting a django service for many clients using really really poor and intermittent connectivity. Satellite and GPRS connectivity in areas of Africa that haven't achieved positive results in the recent fiber cables making landfall.

I have consolidated the javascripts and used minificatied versions, attempted to wash in the stylesheets, and more...

Just like a good django implementer, I am letting apache offer all of the static information like css and JS along with other static media. I have enabled apache modules deflate (for gzip) and expired to try and minimize retransmission from the javascript packages (mainly jQuery's huge cost). I have also enabled django's gzip middleware (but that does not appear to complete much in conjunction with apache's deflate).

Primary question - what else can there be to complete to optimize bandwidth utilization?

  • Exist django optimizations in headers or more to make certain that "already seen data" won't travel within the network?
  • The django caching framework appears to become customized towards server optimisation (minimize striking the database) - so how exactly does that translate to actual bandwidth utilization?
  • the other tweaks on apache exist to make certain the browser will not attempt to get data it already has?

You can delegate jQuery to some CDN who have better connectivity with Africa, e.g., google (and, it is a free service!-). Beyond which i recommend anything every written (or spoken on video, there's lots of that!-) by Steve Souders -- while his talks and books and essays are invaluable to each webmaster I believe they are particularly precious to ones serving a minimal-bandwidth audience (e.g., among his tips in the latest books and talks is all about a considerable fraction from the world's browsers Not receiving compression advantages of deflate or gzip -- it's less concerning the browsers themselves, but about proxies and fire walls doing things wrong, so "manual compression" continues to be important then!).

A number of your optimizations are essential for wringing better performance from your server, try not to confuse all of them with optimizing bandwidth utilization. Quite simply gzip/deflate are relevant but Apache serving static submissions are not (despite the fact that it is necessary).

Now, for the problem you have to take a look at three things: just how much information is being sent, the number of connections are needed to obtain the data, and just how good would be the connections.

You mostly possess the first area included in using deflate/gzip, expires, minimization of javascript etc. in order to only add a couple of things you will possibly not learn about. First, you need to upgrade to Django 1.1, should you haven't already, since it has better support for ETags/Expires headers for the Django sights. You most likely curently have individuals headers working correctly for static data from Apache but when you are using older Django they (most likely) aren't being set correctly in your dynamic sights.

For the following area, quantity of connections, you have to consolidate your javascript and css files into as couple of files as you possibly can to lessen the amount of connections. Extremely useful could be bringing together your image files right into a single "sprite" image. You will find a couple of Django projects additional aspect: django-compress, django-media-bundler (the just one and build image sprites), and you will also see this SO answer.

During the last section of how good would be the connections you should think about global CDN as recommended by Alex, or at the minimum host your website in an Web service provider nearer to your customers. This may be tough for Africa, which in my opinion can't even get decent connectivity into European ISP's (a minimum of southern Africa... northern Africa may be better).