# Path: invenio_stats/proxies.py



from celery import shared_task
from dateutil.parser import parse as dateutil_parse
from .proxies import current_stats
# -*- coding: utf-8 -*-
#
# This file is part of Invenio.
# Copyright (C) 2016-2018 CERN.
#
# Invenio is free software; you can redistribute it and/or modify it
# under the terms of the MIT License; see LICENSE file for more details.

"""Celery background tasks."""

from __future__ import absolute_import, print_function




@shared_task
def process_events(event_types):
    """Index statistics events."""
    results = []
    for event_name in event_types:

# Path: invenio_stats/proxies.py



# Path: invenio_stats/tasks.py
from celery import shared_task
from dateutil.parser import parse as dateutil_parse
from .proxies import current_stats

# -*- coding: utf-8 -*-
#
# This file is part of Invenio.
# Copyright (C) 2016-2018 CERN.
#
# Invenio is free software; you can redistribute it and/or modify it
# under the terms of the MIT License; see LICENSE file for more details.

"""Celery background tasks."""

from __future__ import absolute_import, print_function




@shared_task
def process_events(event_types):
    """Index statistics events."""
    results = []
    for event_name in event_types:

        event_cfg = current_stats.events[event_name]