diff --git a/taskflow/backends/celery/.celeryapp.py.swp b/taskflow/backends/celery/.celeryapp.py.swp deleted file mode 100644 index 09e4e67a..00000000 Binary files a/taskflow/backends/celery/.celeryapp.py.swp and /dev/null differ diff --git a/taskflow/backends/celery/.celeryconfig.py.swp b/taskflow/backends/celery/.celeryconfig.py.swp deleted file mode 100644 index db942e2d..00000000 Binary files a/taskflow/backends/celery/.celeryconfig.py.swp and /dev/null differ diff --git a/taskflow/backends/celery/celeryapp.py b/taskflow/backends/celery/celeryapp.py index 5fb6f881..c60088f3 100644 --- a/taskflow/backends/celery/celeryapp.py +++ b/taskflow/backends/celery/celeryapp.py @@ -19,14 +19,11 @@ import traceback as tb -from taskflow.tests import easy from celery.signals import task_failure, task_success from nova.openstack.common import log as logging LOG = logging.getLogger(__name__) -easy.register() - @task_failure.connect def task_error_handler(signal=None, sender=None, task_id=None, exception=None, args=None, kwargs=None, @@ -38,8 +35,8 @@ def task_error_handler(signal=None, sender=None, task_id=None, LOG.error('Trackeback: %s' % (tb.print_tb(traceback), )) wf = sender.name.split('.')[0] task = ('.').join(n for n in (sender.name.split('.')[1:]) if n) - logbook.update_task(wf, task, status="ERROR", args=args, kwargs=kwargs, - exception=exception, traceback=(tb.print_tb(traceback))) + #logbook.update_task(wf, task, status="ERROR", args=args, kwargs=kwargs, + # exception=exception, traceback=(tb.print_tb(traceback))) # TODO: Auto-initiate rollback from failed task @@ -48,8 +45,7 @@ def task_success_handler(singal=None, sender=None, result=None): """ Save task results to WF """ wf = sender.name.split('.')[0] task = ('.').join(n for n in (sender.name.split('.')[1:]) if n) - logbook.update_task(wf, task, status="SUCCESS", result=result) - pass + #logbook.update_task(wf, task, status="SUCCESS", result=result) diff --git a/taskflow/backends/celery/celeryconfig.py b/taskflow/backends/celery/celeryconfig.py index fe2b4ef8..63345bfc 100644 --- a/taskflow/backends/celery/celeryconfig.py +++ b/taskflow/backends/celery/celeryconfig.py @@ -27,12 +27,6 @@ from oslo.cfg import cfg LOG = logging.getLogger(__name__) -""" If ALWAYS_EAGER is set to true, Celery will execute synchronously """ -if '--eager' in sys.argv: - CELERY_ALWAYS_EAGER = True -else: - CELERY_ALWAYS_EAGER = False - BROKER_URL = cfg.CFG('celery_mq') - - +CELERY_RESULT_BACKEND = "database" +CELERY_RESULT_DBURI = cfg.CFG('celery_backend') diff --git a/taskflow/backends/sql.py b/taskflow/backends/sql.py deleted file mode 100644 index 3d91e7f4..00000000 --- a/taskflow/backends/sql.py +++ /dev/null @@ -1,33 +0,0 @@ -# -*- coding: utf-8 -*- - -# vim: tabstop=4 shiftwidth=4 softtabstop=4 - -# Copyright (C) 2012 Yahoo! Inc. All Rights Reserved. -# Copyright (C) 2013 Rackspace Hosting All Rights Reserved. -# -# Licensed under the Apache License, Version 2.0 (the "License"); you may -# not use this file except in compliance with the License. You may obtain -# a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT -# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. - -import logging -import sqlalchemy - -from oslo.cfg import cfg.CONF - -from taskflow import catalog -from taskflow import exceptions as exc -from taskflow import job -from taskflow import jobboard -from taskflow import logbook -from taskflow import states -from taskflow import utils - -LOG = logging.getLogger(__name__) diff --git a/taskflow/openstack/common/.timeutils.py.swp b/taskflow/openstack/common/.timeutils.py.swp deleted file mode 100644 index 52e7a58d..00000000 Binary files a/taskflow/openstack/common/.timeutils.py.swp and /dev/null differ diff --git a/taskflow/test.db b/taskflow/test.db deleted file mode 100644 index 7aa4e1b6..00000000 Binary files a/taskflow/test.db and /dev/null differ