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

SLF4J-256: Fluent API improvement #272

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

adrianshum
Copy link

  • adding message() in event builder, to allow message to be provided before arguments
  • adding arg() as alias of addArgument()
  • some typo fixes

- adding message() in event builder, to allow message to be provided before arguments
- adding arg() as alias of addArgument()
- some typo fixes

Signed-off-by: Adrian Shum <adrianshum@gmail.com>
@ceki
Copy link
Member

ceki commented Dec 27, 2021

@adrianshum Thank you for this PR.

The log() method with no arguments adds flexibility to the API. However, I am afraid that users will forget to call log() after populating the event. That is the reasons it was not added in the first place. (I forgot about this reasoning until recently. Sorry about that.)

@pedrolamarao
Copy link

@adrianshum Thank you for this PR.

The log() method with no arguments adds flexibility to the API. However, I am afraid that users will forget to call log() after populating the event. That is the reasons it was not added in the first place. (I forgot about this reasoning until recently. Sorry about that.)

If static analysis was provided to warn users of incorrect usage, would you consider this to have enough usability?

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

3 participants