-
Notifications
You must be signed in to change notification settings - Fork 38
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
Add SLF4J Simple Binding to sample application #835
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thank you!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thank you!
As for your concern, slf4j-simple
would be enough for the simple CLI application. I think users will consider which logging library to use in their application and update the dependency when they want to output log messages to files or something (e.g. using Logback's FileAppender.)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thank you!
Taking care of logging libraries (including those used in dependencies) is the user's responsibility, so let's move forward with this change. Thank you.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thank you.
Adding a logging framework for a sample app makes sense to me too. As you said, it's more user-friendly for a sample app to see log messages of ScalarDB out of the box.
Thank you all for your opinions! |
This PR adds
slf4j-simple
to the sample application for Getting Started with ScalarDB.The current sample application doesn't include any logging libraries. So, it outputs some WARNING messages of SLF4J as follows.
Sometimes, these messages make users confusing. Users think "Any problem occurs?" by seeing these messages.
(Actually, I got such inquiry/feedback from a user.)
So, I added
slf4j-simple
to remove these WARNING messages. After this fixing, the sample application doesn't output some WARNING messages as follows.I think this fixing can reduce users' confusion.
However, I would like to discuss this fix a little. I think there are some pros/cons as follows.
If we don't include some logging libraries, the sample application outputs WARNING messages. Those messages can tell users "ScalarDB uses SLF4J". In other words, we can tell users "You need to use some logging libraries that SLF4J supports in your application".
If we include some logging libraries in the sample application, there is a possibility that users cannot notice that "ScalarDB uses SLF4J". But, the same WARNING messages will be output when users create their own application with ScalarDB. So, finally, I think users can notice that when they create their own applications.
Regarding the above two patterns, I couldn't judge which is better. (We should output these WARNING messages or not.)
So, I would like to know your opinions.
What do you think?
(If we should not include some logging libraries in the sample application, I will close this PR.)