codeceptjs run-workers X can do with sequencing improvements
还没有人认领这个 Issue。
评估
这个 Issue 还没有评估数据。
描述
What are you trying to achieve?
codeceptjs run-workers 5 should be more performant and pull tests from a pool instead of having each test pre-assigned to a thread
What do you get instead?
Currently run-workers will create a pool of all tests when codeceptjs run-workers 5 is executed.
It then pre-assigns each test to a CPU thread and starts running all tests assigned to each thread.
This creates an even distribution of tests per thread. The problem is that not all tests are equal in terms of runtime
Small sample from end of test execution
[01] ✔ in 4354ms
[04] ✔ in 4794ms
[02] ✔ in 3328ms
[04] ✔ in 7131ms
[03] ✔ in 13437ms
[01] ✔ in 11558ms
[05] ✔ in 21881ms
[02] ✔ in 7051ms
[02] ✔ in 4259ms
[03] ✔ in 15055ms
[02] ✔ in 5372ms
[03] ✔ in 5274ms
[03] ✔ in 17304ms
If all tests in thread 1 would complete in 2 minutes, then thread 1 would not pick up any more tests even if thread 2 - 5 have 6 tests all still waiting in their queue. This means that tests are only as fast as the slowest thread rather than allowing tests to be picked up by an idle thread.
In the example above thread 02 and 03 were slower than others. thread 01, 04 and 05 were waiting in idle while 02 and 03 were continuing with their queue.
In an ideal world, thread 01, 04 or 05 would see this incomplete queue and pick up a task to speed up test performance.
Details
- CodeceptJS version: 3.5.3
- NodeJS Version: 18
- Operating System: MacOS / Linux
- puppeteer
- 主要语言
- JavaScript
- 星标
- 4.2k
- 派生
- 756
- 平均合并
- 2 天 9 小时
- 30 天内合并 PR
- 16
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
codeceptjs/CodeceptJS 的其他 Issue
-
stale
难度 2/5 1-3 小时 新手友好度 72/100
codeceptjs/CodeceptJS#5420 · 1 条评论 ·
-
stale
难度 2/5 1-3 小时 新手友好度 76/100
codeceptjs/CodeceptJS#5358 · 1 条评论 ·
-
stale
难度 2/5 1-3 小时 新手友好度 78/100
codeceptjs/CodeceptJS#4958 · 10 条评论 · 2 个 reaction ·
-
stale
难度 1/5 1 小时以内 新手友好度 72/100
codeceptjs/CodeceptJS#4778 · 3 条评论 ·
-
stale
难度 4/5 3-5 天 新手友好度 38/100
codeceptjs/CodeceptJS#5618 · 1 条评论 ·
查看 codeceptjs/CodeceptJS 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 65/100
-
难度 2/5 1-3 小时 新手友好度 75/100
docToolchain/docToolchain#1705 ·
-
Timezone select lists one option per character; duplicate "Failed" reason; shared tracker popover id 未关闭bug
难度 2/5 1-3 小时 新手友好度 75/100
nightscout/nocturne#1414 ·
-
bug v2
难度 2/5 1-3 小时 新手友好度 75/100
modelcontextprotocol/inspector#2458 · 1 条评论 ·
-
Mend: dependency security vulnerability status: needs triage 🕵️♀️
难度 2/5 1-3 小时 新手友好度 70/100
carbon-design-system/ibm-products#9907 ·