Async processes accumulate until failure with sqlite in-memory
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 35/100
调研方向
使用 logging.database=sqlite:///:memory: 和 server.parallelprocesses=5 重现该问题,然后检查 dblog.py 中运行计数附近的代码,以及 Process.py 中相关队列和状态处理的代码。确认已完成的异步任务不再占用进程限制,并确认后续请求会收到适当的排队状态和响应。
由索引模型根据 Issue 内容生成。
描述
Description
This relates to running processes in async mode, with logging.database=sqlite:///:memory:
When an async process completes, i.e. (pywps_requests.percent_done: 100.0, pywps_requests.status: 4) the running_count reported by dblog never seems to reflects this.
So if I set parallelprocesses=5 I can execute 5 successful jobs, however each job increments this running count, which is never decremented on completion, meaning I can only run 5 before all I get is ‘PyWPS Process GetSubset accepted’ response for a process which never runs.
This issue only seems to happen when using in-memory sqlite (i.e. does not occur when supplying my own sqlite db string).
Environment
- operating system: Debian
- Python version: 3.6.5
- PyWPS version: 4.2.2
- source/distribution
- git clone
- Debian
- PyPI
- zip/tar.gz
- other (please specify):
- web server
- Apache/mod_wsgi
- CGI
- other (please specify): nginx/gunicorn
Steps to Reproduce
- Run pywps configured with
logging.database=sqlite:///:memory:server.parallelprocesses=5
- Submit 5 async requests
- i.e. with
storeExecuteResponse=true&status=true
- i.e. with
- should work as expected, then on 6th request:
- Gets put in the stored queue
- despite status being set to PyWPS Process stored in job queue, the response document still says ‘PyWPS Process GetSubset accepted’
- nothing else can run now
Additional Information
This is being run in a docker container from macos host, don’t think it should affect this 🤔
- 主要语言
- Python
- 星标
- 186
- 派生
- 116
- 平均合并
- 11 天 20 小时
- 30 天内合并 PR
- 1
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
geopython/pywps 的其他 Issue
-
ReadTheDocs OAuth App Installation可能重新可做 @tomkralidis 于 71 天前认领,目前没有进行中的 PR。 未关闭documentation
-
Modernizing the packaging of the library可能重新可做 @Zeitsperre 于 284 天前认领,目前没有进行中的 PR。 未关闭documentation enhancement packaging
-
难度 2/5 1-3 小时 新手友好度 45/100
-
难度 3/5 1-2 天 新手友好度 45/100
-
难度 3/5 1-2 天 新手友好度 35/100
相似的 Issue
-
customer-reported
难度 2/5 1-3 小时 新手友好度 68/100
Azure/azure-cli#34150 · 1 条评论 ·
维护者通常 1 天内回复
-
community-request
难度 1/5 1 小时以内 新手友好度 95/100
NVIDIA-NeMo/Curator#2464 · 1 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 88/100
WeblateOrg/translation-finder#1099 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 68/100
trezor/trezor-firmware#7997 ·
维护者通常 2 天内回复
-
难度 2/5 1-3 小时 新手友好度 88/100
维护者通常 1 天内回复