[JIRA] Created: (LBCORE-228) Syslog messages over 64K are discarded

Syslog messages over 64K are discarded -------------------------------------- Key: LBCORE-228 URL: http://jira.qos.ch/browse/LBCORE-228 Project: logback-core Issue Type: Bug Components: Appender Affects Versions: 0.9.30 Reporter: Pasi Eronen Assignee: Logback dev list SyslogAppenderBase truncates very long messages to 256k, which is not very useful limit, since SyslogOutputStream supports only UDP, which has maximum message size of 64k. Messages over 64k result in "java.io.IOException: Message too long" (from DatagramSocket.send, called from SyslogOutputStream.flush), but this exception is visible only in logger context status... Proposed fix: truncate long messages instead of discarding them. More specifically, change MSG_SIZE_LIMIT in SyslogAppenderBase to 65000. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira

[ http://jira.qos.ch/browse/LBCORE-228?page=com.atlassian.jira.plugin.system.i... ] Ralph Goers commented on LBCORE-228: ------------------------------------ http://tools.ietf.org/html/rfc3164 says the maximum length of a syslog message is 1024 bytes. To be compliant the appender should be truncating messages to that length. Consider yourself lucky if anything over that length works.
Syslog messages over 64K are discarded --------------------------------------
Key: LBCORE-228 URL: http://jira.qos.ch/browse/LBCORE-228 Project: logback-core Issue Type: Bug Components: Appender Affects Versions: 0.9.30 Reporter: Pasi Eronen Assignee: Logback dev list
SyslogAppenderBase truncates very long messages to 256k, which is not very useful limit, since SyslogOutputStream supports only UDP, which has maximum message size of 64k. Messages over 64k result in "java.io.IOException: Message too long" (from DatagramSocket.send, called from SyslogOutputStream.flush), but this exception is visible only in logger context status... Proposed fix: truncate long messages instead of discarding them. More specifically, change MSG_SIZE_LIMIT in SyslogAppenderBase to 65000.
-- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira

[ http://jira.qos.ch/browse/LBCORE-228?page=com.atlassian.jira.plugin.system.i... ] Pasi Eronen commented on LBCORE-228: ------------------------------------ Many Linux distros seem to use Rsyslog, where 65000 bytes works just fine (if you set $MaxMessageSize 65000), at least over the localhost interface (where MTU is typically large, so the message isn't split to dozens of fragments). (And RFC 3164 has been obsoleted by RFC 5424/5425, which recommend supporting much longer messages than 1024 bytes).
Syslog messages over 64K are discarded --------------------------------------
Key: LBCORE-228 URL: http://jira.qos.ch/browse/LBCORE-228 Project: logback-core Issue Type: Bug Components: Appender Affects Versions: 0.9.30 Reporter: Pasi Eronen Assignee: Logback dev list
SyslogAppenderBase truncates very long messages to 256k, which is not very useful limit, since SyslogOutputStream supports only UDP, which has maximum message size of 64k. Messages over 64k result in "java.io.IOException: Message too long" (from DatagramSocket.send, called from SyslogOutputStream.flush), but this exception is visible only in logger context status... Proposed fix: truncate long messages instead of discarding them. More specifically, change MSG_SIZE_LIMIT in SyslogAppenderBase to 65000.
-- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira

[ http://jira.qos.ch/browse/LBCORE-228?page=com.atlassian.jira.plugin.system.i... ] Ralph Goers commented on LBCORE-228: ------------------------------------ Yes, I'm well aware of RFC 5424 - you can reference the issue(s) I opened with Logback and SLF4J quite a while ago to get them supported. Logback doesn't support it directly and the message format of the two isn't quite compatible. SyslogAppender is designed to support only RFC 3164, which is still the dominant format used.
Syslog messages over 64K are discarded --------------------------------------
Key: LBCORE-228 URL: http://jira.qos.ch/browse/LBCORE-228 Project: logback-core Issue Type: Bug Components: Appender Affects Versions: 0.9.30 Reporter: Pasi Eronen Assignee: Logback dev list
SyslogAppenderBase truncates very long messages to 256k, which is not very useful limit, since SyslogOutputStream supports only UDP, which has maximum message size of 64k. Messages over 64k result in "java.io.IOException: Message too long" (from DatagramSocket.send, called from SyslogOutputStream.flush), but this exception is visible only in logger context status... Proposed fix: truncate long messages instead of discarding them. More specifically, change MSG_SIZE_LIMIT in SyslogAppenderBase to 65000.
-- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira

participants (2)
-
Pasi Eronen (JIRA)
-
Ralph Goers (JIRA)