uber / RemoteShuffleService

Remote shuffle service for Apache Spark to store shuffle data on remote servers.
Other
321 stars 100 forks source link

Remove use of String format in favor of SLF4J anchor #52

Open belugabehr opened 3 years ago

belugabehr commented 3 years ago

There is no need to use String#format with SLF4J as SLF4J supports its own formatting mechanism called an "anchor."

http://www.slf4j.org/faq.html#logging_performance

Remove a bunch of instances of this practice for clarity and it actually hurts performance for debug level logging as SLF4J is able to perform that anchor-substitution lazily, only if debug mode is enabled.

belugabehr commented 3 years ago

Note: I didn't hit every instance, just some of the easier ones and don't want to commit to doing them all without some hope that this will be accepted. :)