So I have ported the websockets_echo example to django.
I have redis running and I can happily chat between to python shells.

When I try to implement it in the websockets_echo script I do the following.
I spawn to Greenlets, one listen to my redis channel and one listening to my 
client.

The redis listener gets messages from redis channel and pushes them to client.
The client listener get messages from client and publishes them to redis 
channel.

Both use the uwsgi api , to push to client (uwsgi.websocket_send()) and to 
listen to client (uwsgi.websocket_recv())

I get an error saying the uwsgi api can only be called form main callable.
How can I work around this?

-----Original Message-----
From: [email protected] [mailto:[email protected]] On 
Behalf Of Roberto De Ioris
Sent: 14 May 2013 18:38
To: uWSGI developers and users list
Subject: Re: [uWSGI] Websocket channels


> Or in an older build?


This is the last commit before they got removed:

https://github.com/unbit/uwsgi/commit/e50a7c518f6ba352e276b326da17310f4cc4fab8



>
> -----Original Message-----
> From: [email protected] 
> [mailto:[email protected]]
> On Behalf Of Alexandro G.S. Mancusi
> Sent: 14 May 2013 18:24
> To: uWSGI developers and users list
> Subject: Re: [uWSGI] Websocket channels
>
> The Europython talk got me interested in uwsgi, too bad I can't make 
> it to Florence.
>
> Are they also disabled in the current master-branch?
>
> -----Original Message-----
> From: [email protected] 
> [mailto:[email protected]]
> On Behalf Of Roberto De Ioris
> Sent: 14 May 2013 18:21
> To: uWSGI developers and users list
> Subject: Re: [uWSGI] Websocket channels
>
>
>> Hi,
>>
>> It seems the python api exposed when running uwsgi does not include 
>> the
>> websockets_channel_join() method in version 1.9.10 Am I doing 
>> something wrong?
>>
>> What would be a good alternative strategy to communicate between 
>> websockets?
>>
>> Cheers,
>>
>> Alexandro
>> _______________________________________________
>> uWSGI mailing list
>> [email protected]
>> http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi
>>
>
> Channels are temporarily disabled, they will be back in the next few 
> weeks as they are a core component of my europython talk, so i need to 
> hurry up
> :)
>
> Currently redis is a good approach (be sure to use a gevent-friendly 
> module for it if you use coroutines)
>
> --
> Roberto De Ioris
> http://unbit.it
> _______________________________________________
> uWSGI mailing list
> [email protected]
> http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi
> _______________________________________________
> uWSGI mailing list
> [email protected]
> http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi
> _______________________________________________
> uWSGI mailing list
> [email protected]
> http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi
>


--
Roberto De Ioris
http://unbit.it
_______________________________________________
uWSGI mailing list
[email protected]
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi
_______________________________________________
uWSGI mailing list
[email protected]
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi

Reply via email to