refactor celery tasks. refs #243