| 172 | @app.task(name=&class="cm">#x27;celery.chord', bind=True, ignore_result=False, |
| 173 | shared=False, lazy=False) |
| 174 | def chord(self, header, body, partial_args=(), interval=None, |
| 175 | countdown=1, max_retries=None, eager=False, **kwargs): |
| 176 | app = self.app |
| 177 | class="cm"># - convert back to group if serialized |
| 178 | tasks = header.tasks if isinstance(header, group) else header |
| 179 | header = group([ |
| 180 | maybe_signature(s, app=app) for s in tasks |
| 181 | ], app=self.app) |
| 182 | body = maybe_signature(body, app=app) |
| 183 | ch = _chord(header, body) |
| 184 | return ch.run(header, body, partial_args, app, interval, |
| 185 | countdown, max_retries, **kwargs) |
| 186 | return chord |