fractal3000 commented on issue #1674:
URL: 
https://github.com/apache/logging-log4j2/issues/1674#issuecomment-1685907810

   
   Hi, Volkan!
   Thanks a lot for your answer!
   But I see the problem in your log that you have sent.
    
   The «exeption» parameter in your log messages is empty.
   <134>1 2023-08-16T22:06:03.290+02:00 tahta 
/home/vy/Projects/log4j/2/log4j-layout-template-json-test/target/test-classes/syslog.xml
 845631 - ***@***.*** 
category="org.apache.logging.log4j.layout.template.json.SyslogTest" 
exception="" priority="INFO" thread="main"] foo
    
   And this was the main problem — to show exception stack trace in log.
   Will be thankfull if you can comment this problem.
    
   Thank in advance, Pavel Aleksandrov.
    
   --
   Павел Александров
    
     
   >Четверг, 17 августа 2023, 0:10 +04:00 от Volkan Yazıcı ***@***.***>:
   > 
   > 
   >Hey  @fractal3000 !
   >[As indicated in  the Log4j support policy , please use  ***@***.*** for 
questions next time.]
   >Your configuration works just fine for me. My test log4j2.xml:
   ><?xml version="1.0" encoding="UTF-8"?>
   ><Configuration status="OFF">
   >  <Appenders>
   >    <Syslog name="syslog" format="RFC5424" host="127.0.0.1" port="51400" 
protocol="UDP" newLine="true" includeMDC="true">
   >      <LoggerFields>
   >        <KeyValuePair key="thread" value="%t"/>
   >        <KeyValuePair key="priority" value="%p"/>
   >        <KeyValuePair key="category" value="%c"/>
   >        <KeyValuePair key="exception" value="%ex{full}"/>
   >      </LoggerFields>
   >    </Syslog>
   >  </Appenders>
   >  <Loggers>
   >    <Root level="trace">
   >      <appender-ref ref="syslog"/>
   >    </Root>
   >  </Loggers>
   ></Configuration>
   >
   >And my nc output:
   >$ nc -v -u -l 51400
   >Bound on 0.0.0.0 51400
   >Connection received on localhost 50429
   ><134>1 2023-08-16T22:06:03.290+02:00 tahta 
/home/vy/Projects/log4j/2/log4j-layout-template-json-test/target/test-classes/syslog.xml
 845631 - ***@***.*** 
category="org.apache.logging.log4j.layout.template.json.SyslogTest" 
exception="" priority="INFO" thread="main"] foo
   ><134>1 2023-08-16T22:06:03.296+02:00 tahta 
/home/vy/Projects/log4j/2/log4j-layout-template-json-test/target/test-classes/syslog.xml
 845631 - ***@***.*** 
category="org.apache.logging.log4j.layout.template.json.SyslogTest" 
exception="" priority="INFO" thread="main"] bar
   >
   >—
   >Reply to this email directly,  view it on GitHub , or  unsubscribe .
   >You are receiving this because you were mentioned. Message ID:  
<apache/logging-log4j2/issues/1674/1681207387 @ github . com>
    


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to