Permalink
Browse files

It's working but messy

  • Loading branch information...
ask committed Mar 28, 2012
1 parent b6daa31 commit 77d6a1556cc349291abdbac13756acb8adc41d9b
Showing with 462 additions and 471 deletions.
  1. +8 −0 celery/abstract.py
  2. +41 −470 celery/worker/consumer.py
  3. +19 −0 celery/worker/heartbeat.py
  4. +108 −0 celery/worker/pidbox.py
  5. +72 −0 celery/worker/qos.py
  6. +1 −1 celery/worker/strategy.py
  7. +213 −0 celery/worker/tasks.py
View
@@ -78,6 +78,8 @@ def bind_component(self, name, parent, **kwargs):
"""Bind component to parent object and this namespace."""
comp = self[name](parent, **kwargs)
comp.namespace = self
+ comp.logger = self.logger
+ comp.app = self.app
return comp
def import_module(self, module):
@@ -169,6 +171,12 @@ class Component(object):
#: This provides the default for :meth:`include_if`.
enabled = True
+ #: The current app (set by namespace when bound)
+ app = None
+
+ #: Logger (set by namespace when bound)
+ logger = None
+
def __init__(self, parent, **kwargs):
pass
Oops, something went wrong.

0 comments on commit 77d6a15

Please sign in to comment.