Forked executor discards the output it grabbed when an execution times out
Los mantenedores suelen responder en 3 días
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
- Error
- Claridad
- Bastante claro
- Estado de actividad
- Activo
- Stack tecnológico
- java
- Área
- build-system
Línea de trabajo
Start in maven-executor/src/main/java/org/apache/maven/executor/support/ProcessBuilderExecutorSupport.java around lines 93-96 and trace how timeout handling discards the two ByteArrayOutputStreams before throwing ExecutorException. Review the ExecutorException API and existing callers; done means a timed-out execution still exposes the captured stdout and stderr, while callers supplying their own streams retain the partial output.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Affected version
1.0.0
Bug description
With grabOutputAsString(true) and an executionTimeout, ProcessBuilderExecutorSupport pumps stdout and stderr into two ByteArrayOutputStreams. When the timeout expires it destroys the process and throws ExecutorException("Process timeout: " + execution) (ProcessBuilderExecutorSupport.java#L93-L96), and both buffers are dropped. The caller learns that the build stalled, but not where. Without a timeout the call blocks for as long as the build does, so a caller that wants a bounded run cannot also keep the log of a run that hangs.
A hang is the case where an integration-test harness most needs the log. Found while moving eclipse-tycho/tycho's integration tests from maven-verifier to maven-executor (eclipse-tycho/tycho#6383): one test stalled on a macOS runner until GitHub's 6-hour job limit, and nothing shows where. maven-verifier 1.8.0 wrote the forked build's output to its log file as it arrived, so a stalled run still left a partial log.
Proposal: on timeout, throw an exception that carries what was grabbed so far, for example an ExecutorException subclass with stdOutString() and stdErrString(), or include the tail of the output in the message. Callers that pass their own stdOut() and stdErr() streams instead of grabbing already get the partial output, since it is written as it arrives.
- Lenguaje dominante
- Java
- Estrellas
- 5
- Forks
- 2
- Merge medio
- 2 d 5 h
- PR fusionados (30 d)
- 2
Preparar el entorno
Aún no hemos revisado los archivos de configuración de este proyecto. Empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de apache/maven-executor
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 88/100
apache/maven-executor#46 ·
Los mantenedores suelen responder en 3 días
-
bug
Dificultad 4/5 3-5 días Aptitud para principiantes 68/100
apache/maven-executor#50 ·
Los mantenedores suelen responder en 3 días
-
enhancement priority:major
Dificultad 5/5 Más de una semana Aptitud para principiantes 25/100
apache/maven-executor#49 · 1 comentario ·
Los mantenedores suelen responder en 3 días
-
bug
Dificultad 3/5 1-2 días Aptitud para principiantes 78/100
apache/maven-executor#48 ·
Los mantenedores suelen responder en 3 días
-
bug
Dificultad 3/5 1-2 días Aptitud para principiantes 68/100
apache/maven-executor#45 ·
Los mantenedores suelen responder en 3 días
Todos los issues de apache/maven-executor
Issues similares
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
-
feature triaged
Dificultad 1/5 Menos de una hora Aptitud para principiantes 75/100
Graylog2/graylog2-server#27549 ·
Los mantenedores suelen responder en 1 día
-
component/zeebe kind/bug
Dificultad 1/5 Menos de una hora Aptitud para principiantes 90/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
UniversalMediaServer/UniversalMediaServer#6356 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 85/100
googleapis/google-cloud-java#14533 ·
Los mantenedores suelen responder en 1 día