Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove info log showing Slf4jLogger started to avoid slf4j warning at the top #31395 #32039

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

dongxuwang
Copy link
Contributor

References #31395

This would significantly enlarge the change to get slf4j warning silent

@dongxuwang dongxuwang changed the title have a tiny buffer for slf4j to get initialized #31395 remove info log showing Slf4jLogger started to avoid slf4j warning at the top #31395 Aug 15, 2023
@dongxuwang
Copy link
Contributor Author

Hi @patriknw , I updated the pr, do you think we also need to un-extend Slf4jLogger with SLF4JLogging?

@@ -104,7 +104,6 @@ class Slf4jLogger extends Actor with SLF4JLogging with RequiresMessageQueue[Logg
}

case InitializeLogger(_) =>
log.info("Slf4jLogger started")
Copy link
Member

Choose a reason for hiding this comment

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

I think this should anyway touch the log because that is a lazy val and if we don't touch it we haven't really started the intiialization yet, and next real log message will do that.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

How about let Slf4jLogger NOT to extend SLF4JLogging

Copy link
Member

Choose a reason for hiding this comment

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

That would be fine, but it would still have to create the logger at some point.

Well, there is a problem with compatibility if removing SLF4JLogging, because Slf4jLogger is public api and not final. Someone may have extended it and expect that log.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yes, that's also another point.

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.

None yet

2 participants