jmeter-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "glinius@live.com" <glin...@live.com>
Subject Re: Jmeter & application logging concern
Date Mon, 11 Mar 2019 17:49:52 GMT
I don't fully understand why you're asking questions not related to JMeter in
JMeter mailing list, however just in case other person will make the same
mistake:

1. You're going into wrong direction, instead of redirecting STDOUT to
jmeter.log file you should be doing the opposite thing: copying messages
which should be going to the jmeter.log file to STDOUT. Given the nature of
your query I strongly doubt you will be capable of do this yourself so here
you go:


> <Configuration status="WARN" packages="org.apache.jmeter.gui.logging">
>     
> <Appenders>
>         
> <File name="jmeter-log" fileName="${sys:jmeter.logfile:-jmeter.log}"
> append="false">
>             
> <PatternLayout>
>                 
> <pattern>
> %d %p %c{1.}: %m%n
> </pattern>
>             
> </PatternLayout>
>         
> </File>
>         
> <GuiLogEvent name="gui-log-event">
>             
> <PatternLayout>
>                 
> <pattern>
> %d %p %c{1.}: %m%n
> </pattern>
>             
> </PatternLayout>
>         
> </GuiLogEvent>
>         
> <Console name="OUT" target="SYSTEM_OUT" ignoreExceptions="false">
>             
> <PatternLayout pattern="%d{HH:mm:ss.SSS} [%t] %-5level %logger{36} -
> %msg%n"/>
>         
> </Console>
>         
> <Console name="ERR" target="SYSTEM_ERR" ignoreExceptions="false">
>             
> <PatternLayout pattern="%d{HH:mm:ss.SSS} [%t] %-5level %logger{36} -
> %msg%n"/>
>         
> </Console>
>     
> </Appenders>
>     
> <Loggers>
>         
> <Root level="info">
>             
> <AppenderRef ref="jmeter-log"/>
>             
> <AppenderRef ref="gui-log-event"/>
>             
> <AppenderRef ref="OUT"/>
>             
> <Appenderref ref="ERR"/>
>         
> </Root>

2. The above step will give you the output in "Jenkins console". If you
additionally want to have it in the file - you can use the underlying OS
shell  redirection operator
<https://www.gnu.org/software/bash/manual/html_node/Redirections.html>   to
save the STDOUT / STDERR outputs into the file. Again looking into your
question I expect you will post the next one right here so kindly find an
example (this is for  Bash <https://en.wikipedia.org/wiki/Bash_(Unix_shell)>  
shell):


> jmeter -n -t test.jmx -l result.jtl > jmeter.out >file.txt 2>&1 

3. Executing JMeter tests in Jenkins:  Continuous Integration 101: How to
Run JMeter With Jenkins
<https://www.blazemeter.com/blog/continuous-integration-101-how-run-jmeter-jenkins>
 





--
Sent from: http://www.jmeter-archive.org/JMeter-User-f512775.html

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@jmeter.apache.org
For additional commands, e-mail: user-help@jmeter.apache.org


Mime
View raw message