Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

[DX] choose optimal job size to reach best speed

Abierto
#8,494 1 comentario 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
48/100
Tipo de issue
Nueva funcionalidad
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
php
Área
performance

Línea de trabajo

Start by tracing where the default jobSize and timeoutSeconds values are defined and how worker chunks are scheduled. Reproduce the reported benchmarks for small and large file sets, including the timeout case with heavier rules. Done means choosing and documenting defaults that improve throughput without causing the reported child-process timeouts.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

13 111 files

jobSize wall
16 218 s
150 86 s
300 75 s

279 files (a single module of the same project)

jobSize chunks workers wall
16 18 14 14.1 s
50 6 6 8.9 s
100 3 3 9.5 s
150 2 2 10.9 s
300 1 1 12.2 s

On 279 files even a single worker - jobSize: 300, no parallelism at all - beats the current default running on 14, because starting 14 processes costs more than the parallelism returns.

The optimum does move with corpus size (~50 for 279 files, 300+ for 13 111), but 100 is close to both, and anything in 100-200 beats 16 everywhere I measured.

So yes, increasing default job size to 100 might be a good idea, but:

jobSize and timeoutSeconds interact. A worker has to finish a whole chunk inside the per-job timeout, and 16 -> 150 multiplies the work per chunk by ~10. With a heavy rule set and a cold cache I hit exactly that - Child process timed out after 120 seconds, exit 1 - at jobSize: 150, where 16 completed. If the default goes up, the default timeout likely needs to go up with it, otherwise the failure mode moves from "slow" to "red build".

Originally posted by @webard in https://github.com/rectorphp/rector-src/issues/8489#issuecomment-5662569618

Lenguaje dominante
PHP
Estrellas
137
Forks
451
Merge medio
7 h 11 min
PR fusionados (30 d)
129

Guía de contribución

Abrir la guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de rectorphp/rector-src

Todos los issues de rectorphp/rector-src

Issues similares

Más issues de PHP

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.