Django Framework

  1. Advanced Topics
    1. Middleware
      1. How Middleware Works
        1. Request Processing
          1. Response Processing
            1. Exception Handling
            2. Built-in Middleware Classes
              1. `SecurityMiddleware`
                1. `SessionMiddleware`
                  1. `CommonMiddleware`
                    1. `CsrfViewMiddleware`
                      1. `AuthenticationMiddleware`
                        1. `MessageMiddleware`
                          1. `XFrameOptionsMiddleware`
                          2. Writing Custom Middleware
                            1. Middleware Classes
                              1. Middleware Functions
                                1. Middleware Methods
                                2. Middleware Order and Configuration
                                  1. Middleware Stack
                                    1. Order Dependencies
                                  2. Signals
                                    1. Built-in Signals
                                      1. Model Signals
                                        1. `pre_save`
                                          1. `post_save`
                                            1. `pre_delete`
                                              1. `post_delete`
                                                1. `m2m_changed`
                                                2. Request/Response Signals
                                                  1. `request_started`
                                                    1. `request_finished`
                                                      1. `got_request_exception`
                                                      2. Database Signals
                                                        1. `connection_created`
                                                      3. Defining and Sending Custom Signals
                                                        1. Creating Signal Objects
                                                          1. Sending Signals
                                                          2. Connecting Receivers to Signals
                                                            1. Using `connect()`
                                                              1. Using Decorators
                                                                1. Receiver Functions
                                                                2. Disconnecting Receivers
                                                                  1. Signal Dispatch
                                                                    1. Weak References
                                                                    2. Caching
                                                                      1. Setting Up Caching
                                                                        1. Cache Settings in `settings.py`
                                                                          1. Choosing a Cache Backend
                                                                          2. Cache Backends
                                                                            1. Dummy Cache
                                                                              1. Local Memory Cache
                                                                                1. File-Based Cache
                                                                                  1. Database Cache
                                                                                    1. Memcached
                                                                                      1. Redis
                                                                                      2. Cache Levels
                                                                                        1. Per-Site Caching
                                                                                          1. Per-View Caching
                                                                                            1. Template Fragment Caching
                                                                                              1. Low-Level Cache API
                                                                                              2. Cache Keys
                                                                                                1. Key Generation
                                                                                                  1. Key Versioning
                                                                                                    1. Key Prefixes
                                                                                                    2. Cache Invalidation
                                                                                                      1. Manual Invalidation
                                                                                                        1. Time-Based Expiration
                                                                                                          1. Conditional Invalidation
                                                                                                          2. Cache Strategies
                                                                                                            1. Cache-Aside
                                                                                                              1. Write-Through
                                                                                                                1. Write-Behind
                                                                                                              2. Custom Management Commands
                                                                                                                1. Creating a Management Command
                                                                                                                  1. Command Structure
                                                                                                                    1. Command Location
                                                                                                                    2. Command Options and Arguments
                                                                                                                      1. Positional Arguments
                                                                                                                        1. Optional Arguments
                                                                                                                          1. Argument Types
                                                                                                                          2. Command Base Classes
                                                                                                                            1. `BaseCommand`
                                                                                                                              1. `AppCommand`
                                                                                                                                1. `LabelCommand`
                                                                                                                                2. Registering and Running Commands
                                                                                                                                  1. Command Output
                                                                                                                                    1. Command Testing
                                                                                                                                    2. Database Optimization
                                                                                                                                      1. Query Optimization
                                                                                                                                        1. Database Indexes
                                                                                                                                        2. Database Transactions
                                                                                                                                          1. Atomic Transactions
                                                                                                                                            1. Transaction Management
                                                                                                                                              1. Savepoints
                                                                                                                                              2. Database Connections
                                                                                                                                                1. Connection Pooling
                                                                                                                                                  1. Multiple Databases
                                                                                                                                                    1. Database Routing
                                                                                                                                                  2. Internationalization and Localization
                                                                                                                                                    1. Enabling Internationalization
                                                                                                                                                      1. `USE_I18N` Setting
                                                                                                                                                        1. `USE_L10N` Setting
                                                                                                                                                          1. `USE_TZ` Setting
                                                                                                                                                          2. Marking Strings for Translation
                                                                                                                                                            1. `gettext()` and `_()` Functions
                                                                                                                                                              1. `ngettext()` for Pluralization
                                                                                                                                                                1. `gettext_lazy()` for Lazy Translation
                                                                                                                                                                2. Using Locale Middleware
                                                                                                                                                                  1. Language Detection
                                                                                                                                                                    1. Language Selection
                                                                                                                                                                    2. Translating Templates
                                                                                                                                                                      1. `{% trans %}` Tag
                                                                                                                                                                        1. `{% blocktrans %}` Tag
                                                                                                                                                                          1. Template Context Variables
                                                                                                                                                                          2. Managing Translation Files
                                                                                                                                                                            1. Creating Message Files
                                                                                                                                                                              1. Compiling Messages
                                                                                                                                                                                1. Translation Workflow
                                                                                                                                                                                2. Formatting
                                                                                                                                                                                  1. Date and Time Formatting
                                                                                                                                                                                    1. Number Formatting
                                                                                                                                                                                      1. Locale-Specific Formatting
                                                                                                                                                                                      2. Time Zones
                                                                                                                                                                                        1. Time Zone Support
                                                                                                                                                                                          1. Time Zone Conversion
                                                                                                                                                                                            1. User Time Zones