#25203: Document changes to WSGI application loading sequence in 1.7
-------------------------------------+-------------------------------------
     Reporter:  yscumc               |                    Owner:  nobody
         Type:                       |                   Status:  new
  Cleanup/optimization               |
    Component:  Documentation        |                  Version:  1.7
     Severity:  Normal               |               Resolution:
     Keywords:  wsgi setup           |             Triage Stage:  Accepted
  application loading                |
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
Changes (by jdufresne):

 * cc: jon.dufresne@… (added)


Comment:

 FWIW, this unexpected change has occurred in a previous Django release as
 well. See ticket #21486. The response in that ticket was to avoid
 importing {{{settings.py}}} during a call to {{{get_wsgi_application()}}}
 such that the original pattern would continue to work. I'm not sure if
 this is still feasible today.

 I appreciate the expertise and knowledge Graham Dumpleton brings to the
 table. But it feels a tad limiting that one can't freely pass an arbitrary
 amount of environment variables from Apache to Django. Some deployment
 strategies, such as Twelve-Factor App (Not Django specific
 http://12factor.net/config) specifically recommend configuring web apps
 through environment variables. Is using environment variables really just
 not possible with mod_wsgi?

 If my application has exactly one variable to read, it is difficult to
 make multiple decisions on this. For example, my application loads
 settings slightly differently in production vs debug/development mode.
 This is to ease configuration for other, perhaps new, developers. With
 just one available variable that is '''always''' set it becomes difficult
 to do this.

--
Ticket URL: <https://code.djangoproject.com/ticket/25203#comment:12>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/064.96389db9de3057f8cc7113d9e7e546cd%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to