Uploaded image for project: 'mod_python'
  1. mod_python
  2. MODPYTHON-142

Make req.no_cache and req.no_local_copy writable.

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.2.8
    • Fix Version/s: 3.3.1
    • Component/s: core
    • Labels:
      None

      Description

      If a handler sets req.no_cache to be true, then Apache will internally add appropriate "Expires" header. Also the req.no_cache attribute is consulted by mod_cache to know when not to cache. The alternative is that a handler must know to set both:

      req.headers_out['Cache-Control'] = 'no-cache'
      req.headers_out['Expires'] = '-1'

      It would be better to allow handlers to set req.no_cache as it isolates them from any future changes in respect of special headers that may need to be additionally set if standards change in any way.

      Not entirely sure if req.no_local_copy attribute is somehow related. It somehow affects whether 304 errors are returned in some cases. Certain modules such as mod_include set this, so no reason that a mod_python handler wouldn't want to set it also.

        Activity

        Hide
        grahamd Graham Dumpleton added a comment -

        Attached "MP142_20060305_grahamd_1.diff" containing proposed changes.

        Show
        grahamd Graham Dumpleton added a comment - Attached "MP142_20060305_grahamd_1.diff" containing proposed changes.

          People

          • Assignee:
            grahamd Graham Dumpleton
            Reporter:
            grahamd Graham Dumpleton
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development