Mercurial > public > sg101
diff gpp/core/tasks.py @ 519:f72ace06658a
For #194, rework the who's online and max users functions.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Sat, 17 Dec 2011 19:29:24 +0000 |
parents | 5171a5e9353b |
children |
line wrap: on
line diff
--- a/gpp/core/tasks.py Fri Dec 16 01:17:35 2011 +0000 +++ b/gpp/core/tasks.py Sat Dec 17 19:29:24 2011 +0000 @@ -5,6 +5,8 @@ from celery.task import task import django.core.mail +import core.whos_online + @task def add(x, y): @@ -47,3 +49,13 @@ command = ForumCleanup() command.execute() + + +@task +def max_users(): + """ + Run the periodic task to calculate the who's online max users/visitors + statistics. + + """ + core.whos_online.max_users()