You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@logging.apache.org by "Peter Lauko (JIRA)" <ji...@apache.org> on 2017/07/05 11:58:00 UTC

[jira] [Created] (LOG4J2-1968) GelfLayout/SocketAppender does not append frame delimiter null byte when using TCP

Peter Lauko created LOG4J2-1968:
-----------------------------------

             Summary: GelfLayout/SocketAppender does not append frame delimiter null byte when using TCP
                 Key: LOG4J2-1968
                 URL: https://issues.apache.org/jira/browse/LOG4J2-1968
             Project: Log4j 2
          Issue Type: Bug
          Components: Appenders, Layouts
    Affects Versions: 2.8
            Reporter: Peter Lauko


Hi,

According to GELF specification, when using TCP protocol a '\0' null byte must be appended at the end of message as frame delimiter.
http://docs.graylog.org/en/latest/pages/gelf.html#gelf

Using below config  messages do not appear in Graylog.
Everything is fine when using UDP, or when using GELF appender (https://github.com/graylog-labs/log4j2-gelf), so logging config itself is ok.
I can see the packets in Wireshark, only Graylog ignores them.

{code:xml}
        <Socket name="SocketTcp" protocol="TCP" host="dit17mpc029.dorsum.intra" port="12201" ignoreExceptions="false">
            <GelfLayout host="jenkins-sock-tcp" compressionType="OFF"/>
        </Socket>
{code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)