[
https://issues.apache.org/jira/browse/SUREFIRE-1788?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17165246#comment-17165246
]
Tibor Digana commented on SUREFIRE-1788:
----------------------------------------
[~kriegaex]
I have found the root cause.
It was exactly the monitor object due to the normal logs go to std/out and
std/err but the native logs go to the SLF4J logger.
It would be worth to align both under std/out and std/err which would make no
difference the Byte Buddy logs and the logs from the tests.
All change has to be done in the class {{ForkStarter}}. See the variable
{{startupReportConfiguration}}.
Use the fields {{originalSystemOut}} and {{originalSystemErr}} in the class
{{StartupReportConfiguration}} and create two builder methods
{{instantiateNativeStdErrStreamConsumer}} and
{{instantiateNativeStdOutStreamConsumer}} for these two fields.
Then go to the class {{ForkStarter}} - Line 577 and extend the constructor of
{{ForkedNodeArg}} with {{NativeStdErrStreamConsumer}} and
{{NativeStdOutStreamConsumer}}.
Finally remove {{new NativeStdOutStreamConsumer()}} in {{SurefireForkChannel}}
and get (substitute) it from {{arguments}}.
Finally in {{ForkStarter}} remove the Line 651and substitute the object from
the getter in {{ForkedNodeArg}}.
> Unhandled native logs in SurefireForkChannel
> --------------------------------------------
>
> Key: SUREFIRE-1788
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1788
> Project: Maven Surefire
> Issue Type: Task
> Components: Maven Failsafe Plugin, Maven Surefire Plugin, process
> forking
> Reporter: Tibor Digana
> Assignee: Tibor Digana
> Priority: Major
> Fix For: 3.0.0-M5
>
>
> This is related only to the internal change of the version 3.0.0-M5 itself.
> The
> [stdOut|https://github.com/apache/maven-surefire/blob/master/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/extensions/SurefireForkChannel.java#L153]
> should be printed to INFO on the console.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)