Websockets on AppEngine Python 3.7 standard enviro

2019-07-21 05:21发布

The use of websockets in AppEngine's Python 2.7 standard environment is pretty limited (see the docs here), and the example code is 6 years old.

I'm wondering if the new Python 3.7 standard environment offers better websocket support?

Since I cannot find any documentation on this (the 3.7 runtime is still in beta, so fair enough), does anybody have any experience using websockets on AppEngine with Python 3.7, and can provide some direction, as to which libraries are compatible, and how to wire things up?

2条回答
一夜七次
2楼-- · 2019-07-21 05:52

As I mentioned here, the use of Websockets in App Engine Flexible will be available soon, but, for Standard, it will need, at least, a year more.

My post linked is related to .NET, but it's the same: no language available for either Flexible or Standard has access to websockets yet.

查看更多
老娘就宠你
3楼-- · 2019-07-21 05:52

I found out this quite cool api, called Pusher that claims to work with GAE.

Link:

https://cloud.google.com/community/tutorials/appengine-pusher https://pusher.com

For who uses Django:

https://pusher.com/tutorials/read-receipts-django/

Pusher is not free if your traffic is big, but if you wanna try or you thinks your app won't reach many user it's ideal for you.

Anyway this is an unofficial channels library from Pusher community (I think it's completely free): https://github.com/nlsdfnbch/Pysher/blob/master/README.md

查看更多
登录 后发表回答