why celery, rabbitmq needed in django-channel when it can do their job?
Asked Answered
A

1

7

I was reading the documentation of django-channels for the first time today and found the following line Channels will take care of scheduling them and running them all in parallel. Does this mean, it does the celery task as well? I used to get confuse with the celery, rabbitmq, mqtt. I thought I was clear and my understanding of celery, rabbitmq and mqtt was

celery - background job, task scheduling

rabbitmq - message broker, sends message to worker

mqtt - it's also another message queuing

in my understanding, celery does both background job tasks as well as of rabbitmq task or mqtt task.

so my question is, when using django-channel, will we need to use those listed stacks(celery, rabbitmq) ? If needed, why it is needed? I look over several articles but could not get the insight clearly. I feel their usecase are somewhat similar. Can anyone clear my confusion with real life examples?

Allegra answered 25/5, 2018 at 1:37 Comment(0)
C
0

This question is quite old, but I asked myself the same question, so here is an answer : as stated in the official Django Channels documentation, the layer backend (redis in the example, but it could be RabbitMQ, or PostGres, etc.), is optional.

Django Channel can indeed handle ASGI requests by itself, but specifying another layer backend might be useful to interact with other applications that might already be pushing messages to a RabbitMQ engine for instance, depending on your architecture.

Chaotic answered 12/8 at 14:28 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.