DEV Community

Cover image for Django REST Framework - WebSocket

Django REST Framework - WebSocket

Burak Yılmaz on January 21, 2022

In this article we will build an application which uses JWT Authentication that communicates to websocket with Django REST Framework. The main focu...
Collapse
 
selamet profile image
Selamet

it has been an important and understandable content on the subject, thank you

Collapse
 
buurak profile image
Burak Yılmaz

Thank you and you are welcome buddy, hope it helped! <3

Collapse
 
sherrydays profile image
Sherry Day

Nice post

Collapse
 
buurak profile image
Burak Yılmaz

thank you :)

Collapse
 
dhruvindev profile image
Dhruvin

Were you successfully able to push this in prod ?

Collapse
 
buurak profile image
Burak Yılmaz

Yes but some DevOps configurations needed on prod and I am using Uvicorn to serve it.

Collapse
 
dhruvindev profile image
Dhruvin

Do have any scaling issues ? I had implemented it in daphene and faced a lot of slowing down when scaling. Would really like to know more about your approach

Thread Thread
 
buurak profile image
Burak Yılmaz

docs.djangoproject.com/en/4.0/howt...
Take a look at this documentation daphne may not be enough by itself on production

Collapse
 
merveealpay profile image
Merve Alpay

wow! Great post

Collapse
 
buurak profile image
Burak Yılmaz

thanks a lot :)

Collapse
 
hakeem750 profile image
hakeem750

Hello everyone I'm having issue connecting my django channels to a flutter app, this is error I kept having "WebSocketException: Connection to 'http://77.68.92.98:8000/socket.io/?EIO=3&transport=websocket#' was not upgraded to websocket"

Collapse
 
mjarck profile image
Maurice

I'm new to all this and I just cant figure out how the request has to look like for get and post. I would really appreciate an example, thx.