Geo: LogCursor `--debug` option does not work
Summary
gitlab-org/build/CNG!220 (comment 193308763)
It remains, that even with the addition of the
mkdir /var/log/gitlab/gitlab-rails
& touch ofgeo.log
there-in, nothing is logged, even with--debug
.
The --debug
option doesn't work, because it's always overridden by Rails.logger.level
. This was intentional: #4497 (closed)
Steps to reproduce
- Run Rails not in development or manually set
Rails.logger.level = ::Logger::INFO
- Run
ee/bin/geo_log_cursor --debug
What is the current bug behavior?
No debug logs are output anywhere.
What is the expected correct behavior?
If --debug
option is set, debug logs should appear, regardless of Rails.logger.level
.
Possible fixes
- We could make
--debug
option work by settingRails.logger.level
with it, though that will increase Rails output toproduction.log
as well as increasing output togeo.log
. - We could make
--debug
option work without modifyingRails.logger.level
. This is more work. Not sure if worth it. - We could remove
--debug
option and tell people how to modify theRails.logger.level
: !4066 (comment 55638670)
Proposal
I vote for Option 1 above
Edited by Michael Kozono