Repository navigation
feat(logging): allow akka-apps and bbb-web to log to stdout only - #26172
Conversation
The second appender of the root logger is now ${BBB_LOG_FILE_APPENDER:-FILE}.
Unset, both keep writing their log file as before. Set to STDOUT, logback skips
the unreferenced FILE appender and no log file is opened, e.g. in a container.
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. 🗂️ Base branches to auto review: 4
Please check the settings in the CodeRabbit UI or the ⚙️ Run configuration
You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
🚨 Automated tests failed |
|
Checked both files and their runtime paths: the |
|
Thanks for checking the lookup order and the fallback, and that Grails picks up the classpath logback.xml in the packaged service. |
cc4fed1
into
bigbluebutton:v4.1.x-develop
akka-apps and bbb-web can now log to stdout only, without opening a log file, by setting
BBB_LOG_FILE_APPENDER=STDOUT.Change
logback.xmlof bbb-apps-akka and bbb-web, the second appender of the root logger becomes${BBB_LOG_FILE_APPENDER:-FILE}.STDOUT, logback skips the unreferenced FILE appender, opens no log file, and attaches STDOUT only once.<if>.Package installs
FILEand both services write their log file as before.Tested
bbb-apps-akka.log/bbb-web.logas before;STDOUTwrites no log file and each message appears once on stdout./bigbluebutton/api.Question
akka-bbb-fseslhas the same FILE appender (src/universal/conf/logback.xml,src/main/resources/logback.xml) and is not changed here. Do you want the same change there?BBB_LOG_FILE_APPENDERa good name?LOG_FILEandLOGBACK_*were avoided because Spring Boot's logging system uses them.Image follow-up: v4.1.x-develop...tibroc:bigbluebutton:images/logback-stdout, which removes the build-time
sedthat deletes<appender-ref ref="FILE"/>from both files. Images: #26141.Details
value "FILE" substituted for "${BBB_LOG_FILE_APPENDER:-FILE}". It shows only because both files already trigger a status dump (the existing "layout instead of encoder" WARNs).STDOUTthere is also an extra "Appender named [FILE] not referenced" line.