Skip to content

Conversation

@dumbbell
Copy link
Collaborator

Otherwise debug messages are quickly dropped by Lager.

Otherwise debug messages are quickly dropped by Lager.
Copy link
Collaborator

@lukebakken lukebakken left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will this have an effect when the log level is debug from the start?

@lukebakken
Copy link
Collaborator

What do you think of 13f4117 ?

Copy link
Collaborator

@michaelklishin michaelklishin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When the node starts with debug level, it now uses the HWM value of 5000. That's fine.
If I then set log level to debug with

rabbitmqctl set_log_level debug

the value is bumped to 500K. Setting it to info after that with

rabbitmqctl set_log_level info

sets the value back to 5000 instead of 50.

@dumbbell
Copy link
Collaborator Author

Hmm when I start the node with the log level set to debug, the lager application env. still has a high watermark of 50 for me. I used the new config format.

@michaelklishin: how did you configure the initial log level?

@lukebakken
Copy link
Collaborator

I see what @dumbbell describes. HWM is 50 to start, then running set_log_level debug increases it to 5000. Running set_log_level info sets it back to 50.

Config file is as follows:

$ cat ~/issues/misc/rabbitmq.conf 
# Logging
log.console = true
log.console.level = debug
log.file.level = debug

@michaelklishin
Copy link
Collaborator

I start a node with gmake run-broker, that's it. No custom config file involved.

@michaelklishin
Copy link
Collaborator

It works as expected with an explicitly provided config. Could be something specific to my environment.

@michaelklishin michaelklishin merged commit 5b2e000 into master Mar 15, 2019
@michaelklishin michaelklishin deleted the bump-lager-high-watermark-if-level-is-debug branch March 15, 2019 02:55
michaelklishin added a commit that referenced this pull request Mar 15, 2019
…evel-is-debug

rabbit_lager: Multiply high watermark by 100 when log level is debug

(cherry picked from commit 5b2e000)
@lukebakken
Copy link
Collaborator

@michaelklishin I'm just now testing withmake run-broker and I see something similar to what you report. I'm investigating.

@lukebakken
Copy link
Collaborator

False alarm, run-broker is affected by this change: rabbitmq/rabbitmq-common@c049442

@michaelklishin
Copy link
Collaborator

With this PR I suggest that rabbitmq/rabbitmq-common@c049442 is reverted.

@dumbbell
Copy link
Collaborator Author

Thank you! I will take care of reverting the change in rabbitmq-common.

@dumbbell
Copy link
Collaborator Author

The problem with the initial patch is that setting the log level from the configuration does not change the high watermark on startup if that level is set to debug. I prepared another patch to help with this, so we can revert the change in rabbitmq-common.

dumbbell added a commit that referenced this pull request Mar 18, 2019
... if the log level is set to `debug` in the configuration.

This allows us to revert commit rabbitmq/rabbitmq-common@c04944235b.

References #1912.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants