Commit 4fc71c1d by Jay Zoldak

Merge pull request #2977 from edx/zoldak/kill-perfstats

Kill the perfstats module, which is unused
parents 136f4388 1de5e565
......@@ -43,8 +43,6 @@ CC_MERCHANT_NAME = PLATFORM_NAME
COURSEWARE_ENABLED = True
ENABLE_JASMINE = False
PERFSTATS = False
DISCUSSION_SETTINGS = {
'MAX_COMMENT_DEPTH': 2,
}
......@@ -1096,7 +1094,6 @@ INSTALLED_APPS = (
# Our courseware
'circuit',
'courseware',
'lms.lib.perfstats',
'student',
'static_template_view',
'staticbook',
......
import json
import tempfile
import time
from django.conf import settings
from django.db import connection
import views
class ProfileMiddleware:
def process_request(self, request):
self.t = time.time()
print "Process request"
def process_response(self, request, response):
# totalTime = time.time() - self.t
# tmpfile = tempfile.NamedTemporaryFile(prefix='sqlprof-t=' + str(totalTime) + "-", delete=False)
# output = ""
# for query in connection.queries:
# output += "Time: " + str(query['time']) + "\nQuery: " + query['sql'] + "\n\n"
# tmpfile.write(output)
# print "SQL Log file: " , tmpfile.name
# tmpfile.close()
# print "Process response"
return response
# Create your models here.
# Create your views here.
import middleware
from django.http import HttpResponse
def end_profile(request):
names = middleware.restart_profile()
return HttpResponse(str(names))
......@@ -153,9 +153,6 @@ for key, value in settings.MKTG_URL_LINK_MAP.items():
{'template': template}, name=value),)
if settings.PERFSTATS:
urlpatterns += (url(r'^reprofile$', 'lms.lib.perfstats.views.end_profile'),)
# Multicourse wiki (Note: wiki urls must be above the courseware ones because of
# the custom tab catch-all)
if settings.WIKI_ENABLED:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment