so I have been playing around with django for a bit and I really do like this framework. However, I would like to understand better how it actually works 'under the covers'.
Here is my current view of client-server-django world, which is very rough and will probably make your toenails curl (sorry)...
- The browser sends a Http request to the server.
- The server does its magic and dumps the request via the CGI to django (?)
- Some part of django (which?) receives the request and turns it into a django request object.
- The request object wanders on some nebulous paths through the middleware which does strange things with it.
- The request object finally ends up in some function (which?) which looks at the urls, takes the patterns out of urls.py and calls up a view function.
- The view functions do their magic (with models and templates as partners in vice) , this is probably where I have the strongest illusion of understanding (well, apart from the database abstraction magic, that is... ;)
- The view functions returns an HttpResponse object, I guess this is returned on some nebulous paths to the CGI.
- Webserver takes over again and sends the Http response to the client.
Ok, so what the heck is my question you ask? Well, how does this all work, really? I am not expecting that you spoon-feed me everything... I suspect that the answer will ultimately be to "read the source, luke", however, I would be grateful if
- You could clear up my grosses misconseptions
- tell me where to start? What I would like to do is grap a debugger and just walk through the process a couple of times, but I don't really know where to get started
- you could point me to any documents that explain this well... yes, I have heard of this google thing but haven't really found anything super-useful.
thanks a lot Paul