Better Java – Resources for Writing Modern Java
1–10 of 192 posts
Re: Better Java – Resources for Writing Modern Java
#2Re: Better Java – Resources for Writing Modern Java
#3While I agree with most things, overuse of Optional like this is an antipattern IMO. Having done a lot of Java 8 development, I find Optional is best for return types, but otherwise forcing callers to wrap values in Optional is unnecessary as opposed to something like Scala. Those that work on the JDK feel the same [1][2] and I think [2] is even overuse with the prevalence of static analysis tools and @Nullable.
Although a tad dated, I find [3] to be a good guide to modern Java all around.
1 - http://stackoverflow.com/questions/26327957/should-java-8-ge... 2 - http://blog.joda.org/2015/08/java-se-8-optional-pragmatic-ap... 3 - http://blog.paralleluniverse.co/2014/05/01/modern-java/
Re: Better Java – Resources for Writing Modern Java
#4Re: Better Java – Resources for Writing Modern Java
#5Re: Better Java – Resources for Writing Modern Java
#6For one - some performance examples (specifically, integer array iteration) is 15 times slower with streams.
Angelika Langer's analysis:
https://jaxenter.com/java-performance-tutorial-how-fast-are-...
Re: Better Java – Resources for Writing Modern Java
#7Re: Better Java – Resources for Writing Modern Java
#8Spring has had code-based configurations since 2009[1]; seems a little disingenuous to recommend Guice/Dagger due to this non-existent limitation.
[1] http://spring.io/blog/2009/12/22/configuration-simplificatio...
Re: Better Java – Resources for Writing Modern Java
#9I'm in agreement with the first few comments already - at least some parts of this advice is dubious. For one - some performance examples (specifically, integer array iteration) is 15 times slower with streams. Angelika Langer's analysis: https://jaxenter.com/java-performance-tutorial-how-fast-are-...
That's a very misleading example, and even the linked post itself explains why it is so (e.g. not much is done with the integers in the first place).