From 995dd6f99a414fa2e28d22689b97d659ed65958a Mon Sep 17 00:00:00 2001 From: Rob Austein Date: Fri, 6 Apr 2012 17:06:52 +0000 Subject: Disable Django debugging and add warning comment. svn path=/branches/tk161/; revision=4410 --- rpkid/rpki/irdbd.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/rpkid/rpki/irdbd.py b/rpkid/rpki/irdbd.py index d3cfbb55..28e26b07 100644 --- a/rpkid/rpki/irdbd.py +++ b/rpkid/rpki/irdbd.py @@ -150,8 +150,17 @@ class main(object): cfg.set_global_flags() + # Do -not- turn on DEBUG here except for short-lived tests, + # otherwise irdbd will eventually run out of memory and crash. + # + # If you must enable debugging, use django.db.reset_queries() to + # clear the query list manually, but it's probably better just to + # run with debugging disabled, since that's the expectation for + # production code. + # + # https://docs.djangoproject.com/en/dev/faq/models/#why-is-django-leaking-memory + settings.configure( - DEBUG = True, DATABASES = { "default" : { "ENGINE" : "django.db.backends.mysql", -- cgit v1.2.3