Open mrahul17 opened 2 years ago
Thank you for posting about this! I have been wondering about this for years (but not enough to actually look deeply into this apparently) and was very confused why the Rails log level was not being respected. I agree that falling back to Rails.logger.level would be a more expected default behavior.
Agree. cc @petergoldstein
@shadabahmed Sure. I agree that's a more sensible default behavior.
For packaging my suggestion would be:
That'll get this change in, properly signal breaking, and shrink the support matrix for future versions/changes.
This is a follow up on this issue https://github.com/shadabahmed/logstasher/issues/59 This gem expects a log level to be explicitly provided in the yaml/environment.rb files failing which it assumes the
WARN
level as seen here https://github.com/shadabahmed/logstasher/blob/aca28431ae476061739a78cdc9b8a522b0b63eb1/lib/logstasher.rb#L116 Will it better if we fallback toRails.logger.level
if nothing is specified? I think users would expect LogStasher to use the same severity level as configured for Rails. I am willing to make this change if it sounds good, or atleast add the current way to documentation because I suspect this is going to be a breaking change