Option quarkus.log.syslog.max-length
ignores text of the message #41166
Open
Description
Describe the bug
I have an application, which writes its logs into syslog. I use option quarkus.log.syslog.max-length
to limit the length of the message. Despite that, when I log very long message (which contains more chars, than max-length), the message is not filtered.
Expected behavior
The long message is filtered.
Actual behavior
The message goes to syslog
How to Reproduce?
git clone git@github.com:fedinskiy/reproducer.git -b syslog && cd reproducer
. You can notice, that fileapplication.properties
contains this line:quarkus.log.syslog.max-length=64
- Start a syslog server, which will output received logs to the console:
podman run -p 8514:514 -v $(pwd)/syslog.conf:/etc/syslog-ng/syslog-ng.conf:z --rm -it balabit/syslog-ng
- Start the app:
mvn clean quarkus:dev
curl localhost:8080
— syslogs console now contains a short message "Jun 12 16:40:43 localhost quarkus[111635]: INFO Root access"curl localhost:8080/long
syslogs now contains a long message "Jun 12 16:42:18 localhost quarkus[111635]: INFO Message, which is very long and is not expected to fit into 64 bytes"- Check the length of the message:
$ echo "Message, which is very long and is not expected to fit into 64 bytes" | wc --chars --bytes
69 69
- If we use more verbose logging format (
mvn clean quarkus:dev -Dquarkus.profile=format
), both short and long messages are not shown, which is more or less expected
Output of uname -a
or ver
6.7.3-200.fc39.x86_64
Output of java -version
Java version: 21.0.1, vendor: Eclipse Adoptium
Quarkus version or git rev
3.11.1
Build tool (ie. output of mvnw --version
or gradlew --version
)
Apache Maven 3.9.6 (bc0240f3c744dd6b6ec2920b3cd08dcc295161ae)
Additional information
No response