> I'd like to use something like the Django sessions middleware, > but I don't want to involve cookies or HTTP request headers > at all. Does anyone have a good way to do this?
Why not? You've got to use some kind of transport to get the XML there anyway, and django is built with HTTP in mind. I've been doing json-rpc over http using django (and cookie based sessions) and it has been working well. I don't know if it would help, but my approach with json-rpc was to: Create the methods to expose, and 'register' them in a similar way to how template tags are registered. Registering pretty much just associated a string name with the actual function and some meta data for permission checks in a singleton. Create a single view per app that receives the rpc request (post data), determines the exposed method name and extracts the arguments and then passes that to a dispatcher function along with the current user. The dispatcher function checks the exposed function registry for that method name and the meta for authentication/permission requirements and if met calls the function requested and returns the result which is return in a JSONRPCResponse object (subclassed HttpResponse) that handles packaging/serializing to json-rpc form, or if there were errors the dispatcher catches them and converts python exceptions to json-rpc form that reponse instead. The core logic for the app is in the registered functions which return python types so they can be used in normal views too. --~--~---------~--~----~------------~-------~--~----~ 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?hl=en -~----------~----~----~----~------~----~------~--~---