Hack with Django middlewares
Jaysinh shukla (~jaysinh) |
Abstract: This proposal will introduce the concept of Django middlewares to the audience. It adheres to discuss existing Django middlewares and guides to writing custom middlewares.
Description: Django middlewares are stackable code for processing over incoming requests and responses. It is observed that developer are not aware of this feature of Django and end with repetitive code either at view or model level. This proposal tries to explain the importance of Django middlewares and introduce audience with the available APIs for writing their own custom Django middleware.
- Introduction to Django middleware
- How to activate, de-activate Django middlewares
- Explanation of Django middleware stack.
- Explanation of Django auth middleware, gzip middleware and few other internal middlewares
- API Django exposes for writing custom middleware
- How Django calls various middleware methods.
- Which method to hack on for getting the desired customization.
- Demonstration of custom JSON Web Token authentication middleware the author has written for his company.
- Basic knowledge of Django framework
A Full-stack developer by profession, A Computer scientist by heart, An Actor by gene. I am Speaker, Vimmer, Blogger and Organizer. Core member of PyKutch.