Comments (5)
后续版本会考虑加入websocket会话重连功能。
目前可以考虑使用基于http的会话来防止休眠导致的会话断开,参考 pywebio.platform.flask.start_server()
, (可以将 session_expire_seconds
设置大一些)
from pywebio.
最新的 v1.2 版本中,Websocket连接可以通过在 start_server()
中设定 reconnect_timeout
参数来支持会话重连。
from pywebio.
看起来很赞!
是否有可能设置永不超时,随时可以重连呢?
from pywebio.
是否有可能设置永不超时,随时可以重连呢?
会话重连功能需要将连接断开的会话维护起来,如果永不超时,那些无人访问的会话将一直占用内存无法被清理。为了防止内存泄漏,一定要加上超时时间,应用可以根据需要调整超时时间大小。
from pywebio.
感谢回复~
转念一想,设置一个超大的超时时间也确实是与无限时间相比更优的选择。
我理解这个问题作为阻止休眠的替代方案已经足够了,就先擅自关闭issue了。
from pywebio.
Related Issues (20)
- put_table can not set style, override via css or anything else HOT 3
- [Feature Request] HOT 1
- 当使用手机浏览器访问pywebio生成的网页时,put_audio无法自动播放
- put_file_upload 问题 1.8.2version HOT 1
- Side margins are very large, space is wasted HOT 2
- [Feature Request] remove scope HOT 2
- [Feature Request]put_tabs HOT 1
- [Feature Request]Horizontal Tabs
- [Feature Request]Update popup content
- input_group action cancelable 表现错误 HOT 2
- Page not get inactive if there are buttons in the page HOT 2
- 使用put_file_upload时跳出的展示上传进度的toast中显示的百分比数字范围在0~1 HOT 1
- 渲染列表初始正常,后续渲染倒序 HOT 3
- 在 'pywebio.py' 中找不到引用 'input' HOT 2
- 关于put_datatable建立复杂的**式报表问题 HOT 1
- 静态资源托管不是所有资源都生效 HOT 5
- 如何修改网页图标 HOT 1
- In version 1.8 put_loading not work any more. HOT 1
- 按钮样式自定义生效不符合预期 HOT 1
- 请问table可不可以设置成全屏 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pywebio.