Configure logging for Triggerer#54992
Conversation
This will ensure logging configuration such as colored_console_log are respected by the Triggerer processes.
|
CC @ashb |
|
Unless this is pressing, I'm working on a complete overhaul of logging in #52651 |
ashb
left a comment
There was a problem hiding this comment.
Okay yes, I see. We were using an unconfigured/wrongly configured
Yupp, it was just being used unconfigured, so much of the configuration wasn't being applied to the logger. Are you happy to approve after the test change? |
There was a problem hiding this comment.
Though now I think about it, I wonder if this should be called much earlier in the trigger_job process, not just here?
Doesn't this affect the " triggers running" log message too?
I guess not since that comes from the subprcoess. Still, I think it should be moved much earlier, like in the TriggerJobRunner.execute or similar.
|
So far I see all the logs I expect to be configured doing so in the Triggerer (though tracebacks in all processes still don't respect the colour configuration). Let's merge this for now since it's tested and at least solving the issues I know of in the Triggerer. We can always continue iterate further if necessary. |
This will ensure logging configuration such as colored_console_log are respected by the Triggerer processes.
The way this was detected was Trigger logs not respecting the
logging.colored_console_logconfig (see #54962). With this change the logs now respect that setting:^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named
{pr_number}.significant.rstor{issue_number}.significant.rst, in airflow-core/newsfragments.