[Answered ]-Django's built in web server: Usage and Reliability Concerns


If you’re not using the development server for development of the django project, it sounds like production to me. Is deploying your application with Apache and mod WSGI worth the hassle? That’s up to you, but the advice of the Django developers is pretty unambiguous.

DO NOT USE THIS SERVER IN A PRODUCTION SETTING. It has not gone through security audits or performance tests. (And that’s how it’s gonna stay. We’re in the business of making Web frameworks, not Web servers, so improving this server to be able to handle a production environment is outside the scope of Django.)

For your second question, I’m not sure what you mean by ‘corrupted’. If two users are changing the same object at the same time, the second user to save can inadvertently revert the first user’s changes:

Consider two users editing the same Person. The first user changes the first name, then the second user changes the second name. Because the second user loaded the change page before the first user saved, the first name is changed back to Joe.

| Description   | First Name | Second Name  |
| initial value | Joe        | Smith        |
| first user    | Joseph     | Smith        |
| second user   | Joe        | Bloggs       |


Are you talking about corruption happening as a result of two separate instances of django running against the same database? If that’s the case, I can definitely see a possibility of data corruption as the Django’s ORM API and Forms API arn’t designed to be distributed in this manner.

As far as the definition of a “production” server. My understanding is that the dev server wasn’t designed for reliability, availability, security, or quality in general. For example, it can only serve a single request at a time. Having said that, every use case defines its own set of requirements that defines a production environment. What I consider “production” for my needs, will not satisfy Amazon’s definition of production 🙂

Leave a comment