NewsBlur/apps/monitor/views/newsblur_loadtimes.py
2021-03-26 13:28:03 -05:00

12 lines
379 B
Python
Executable file

from django.http import JsonResponse
from django.views import View
class LoadTimes(View):
def get(self, request):
from apps.statistics.models import MStatistics
return JsonResponse({
'feed_loadtimes_avg_hour': MStatistics.get('latest_avg_time_taken'),
'feeds_loaded_hour': MStatistics.get('latest_sites_loaded'),
})