Skip to main content

All Questions

314 questions with no upvoted or accepted answers
21 votes
1 answer
4k views

Can django channels scale to handle big traffic?

I want to use django channels on an existing project to support websockets, but i'm having doubts about scalability i know daphne server can only handle so much opened connections 1-how many ...
Zingo's user avatar
  • 211
15 votes
0 answers
772 views

Django channels with Spring Boot Websockets (StompSession) do not work

Hey there we want to use Django just to execute python code and use channels for the results. Implemented everything the websockets are not working as they should. If I try to send something from our ...
CptDayDreamer's user avatar
11 votes
0 answers
1k views

websocket-client: socket.error: [Errno 104] Connection reset by peer

I am using Django channels to build an realtime chat application. I have installed websocket-client and when I try to connect using ws.connect(), it throws error 104. connection reset by peer. It ...
Streetway Fun's user avatar
8 votes
0 answers
5k views

How to send heartbeats / ping over django channels 1

We have Django Channels running with Daphne and redis. Before we had django-websocket-redis running and it supports a heartbeat (ping) message out of the box. Our client code depends on this heartbeat ...
ThaJay's user avatar
  • 1,864
6 votes
0 answers
682 views

Immediately sending messages using Django Channels

I have a long-running operation that is kicked off by a message from a websocket and I would like my server to send a confirmation to the client with when the operation was started and when it was ...
Aragorn Crozier's user avatar
6 votes
0 answers
2k views

Django channels rest framework don't return data of subscription in production environment (gunicorn/daphne/nginx)

Hi everyone I deployed django with channels via daphne for websocket and gunicorn for normal request http with reverse proxy nginx, I have a problem that has no answer, it works correctly locally. I ...
Egeo Minotti's user avatar
6 votes
2 answers
4k views

Mixing Websockets and REST

I'm writing a RESTfull api, where for example user can create new threads or new posts in a thread. This is where I would use normal POST request. My API also allows users to send messages to each ...
Blake Gibbs's user avatar
6 votes
1 answer
3k views

Listening to django channels channel_layer from outside of a consumer

The docs explain that it is possible to publish to the channel layer from outside of a consumer: https://channels.readthedocs.io/en/latest/topics/channel_layers.html#using-outside-of-consumers I need ...
Alex's user avatar
  • 2,360
5 votes
0 answers
1k views

How to manage cpu and memory with django channels

Is there a way to better manage cpu and memory usage with django channels? I am trying to stream data very quickly over websockets, which works well until my ubuntu server cpu hits 100% and memory ...
MattG's user avatar
  • 1,894
5 votes
0 answers
2k views

passing headers to Django channels using Javascript Websockets to authenticate user using Token

i have no idea how to connect and authenticate django channels using token authentication because javascript websockets doesnt support passing headers to the server class TokenAuthMiddleware: ""...
john's user avatar
  • 549
5 votes
0 answers
6k views

How to call async function inside a celery task

I have a web chat using websockets (AsyncWebsocketConsumer, django-channels). I'm using celery to parse a request but it halt with no debbugable (for me) errors every time I try to send the response ...
user1532587's user avatar
  • 1,013
5 votes
0 answers
1k views

django_channels "Reader at end of file" exception

I have implemented django_channels AsyncJsonWebsocketConsumer consumer which subscribes to "chat" group: from channels.generic.websocket import AsyncJsonWebsocketConsumer class CeleryTaskConsumer(...
niekas's user avatar
  • 8,779
5 votes
0 answers
932 views

How to architect a Group in Django Channels so that the 24 hour group_expiry time does not harm my communication?

In my infrastructure, I have a fleet of RPi devices that connect in to our webserver over a websocket. The websocket connection ideally remains open permanently and acts as the conduit where the ...
David L Ernstrom's user avatar
4 votes
0 answers
1k views

Why am I getting timeout error in Django Channels?

I have recently started learning Django Channels and found this very nice and detailed project: Real-Time Taxi App With Django Channels and React. However, this project uses Django Channels v2.3.1 and ...
Ayush Gupta's user avatar
  • 1,208
4 votes
1 answer
2k views

Send real time data to Django frontend

I've been making some questions about this topic but i still did not come to a conclusion and i'm still completely uncertain on what approach should i take here, so i decided to make a new question ...
Jack022's user avatar
  • 1,097

15 30 50 per page
1
2 3 4 5
21