Hi,
    I'm trying to write a Message Subscription, so I did these:
    1. choose Channels and it''s WebsocketConsumer as my websocket-server
    2. write a while loop, querying my message center every second
    3. running the loop after websocket connected

    and I find that:
    1. I can't send a message because of the loop still running
    2. daphne received the DISCONNECT signal, but the connection didn't 
close(still output something in loop)

    so I want to know if I could:
    1. kill DISCONNECTED websocket
    or 2. get websocket status, so I can break the loop when status change
    or 3. receive message inside the loop

    I've found the dwebsocket which can receive message manually, but I 
prefer to use channels.

    Many thanks if anyone can give me some suggestions!

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/52260d4a-f9d8-48bc-a450-8f9ecc68c4ba%40googlegroups.com.

Reply via email to