Java is a great programming language but has some known flaws, common pitfalls. This workshop is based on Joshua Bloch’s “Effective Java.” 3rd edition book. It contains 40 sections, called “Items”, that give the attendees valuable advice on different aspects of the language. Prerequisite knowledge: Basic Java language knowledge is needed. All attendees should bring their own Laptop Minimum Java 21 should be installed Workshop Outline: This workshop consists of several “items,” each presented in the form of a short, stand-alone essay that provides specific advice, insight into Java platform subtleties, and updated code examples. The comprehensive descriptions and explanations for each item illuminate what to do, what not to do, and why. Details of the workshop ITEM 02: Builder Patterns when faced with many constructors ITEM 06: Avoid creating unnecessary objects – Performance issues ITEM 08: Should we use finalizers? ITEM 09: The try-with-resources statement - ITEM 11: Why implementing Hashcode and equals is very critical and how HashMap is working? ITEM 14: Consider implementing Comparable ITEM 17: Minimize mutability ITEM 18: Favor composition over inheritance ITEM 19: Design and document for inheritance or else prohibit it ITEM 22: Use interfaces only to define types ITEM 23: Prefer class hierarchies to tagged classes ITEM 25: Limit source files to a single top-level class ITEM 26: Don’t use raw types ITEM 28: Prefer lists to arrays ITEM 29: Favor generic types ITEM 30: Favor generic methods ITEM 32: Combine generics and varargs judiciously ITEM 34: Use enums instead of int constants ITEM 35: Use instance fields instead of ordinals ITEM 36: Use EnumSet instead of bit fields ITEM 39: Prefer annotations to naming patterns ITEM 40: Consistently use the Override annotation ITEM 42: Functional interfaces, Prefer lambdas to anonymous classes ITEM 48: Use caution when making streams parallel ITEM 49: Check parameters for validity ITEM 50: Make defensive copies when needed ITEM 52: Use overloading judiciously ITEM 53: Use varargs judiciously ITEM 54: Return empty collections or arrays, not nulls ITEM 55: Return optionals judiciously ITEM 57: Minimize the scope of local variables ITEM 58: Prefer for-each loops to traditional for loops ITEM 59: Know and use the libraries ITEM 60: What is the best practices while using currency (money) in Java? ITEM 63: Beware the performance of string concatenation ITEM 69: Use exceptions only for exceptional conditions ITEM 71: Avoid unnecessary use of checked exceptions ITEM 73: Throw exceptions appropriate to the abstraction ITEM 71: Avoid unnecessary use of checked exceptions ITEM 78: Synchronize access to shared mutable data ITEM 84: Don’t depend on the thread scheduler New coverage includes Recording of a previous talk https://www.youtube.com/watch?v=imqK-fsK5ns
Talk Level:
BEGINNER
Bio:
Altuğ Bilgin Altıntaş is a Business Agility Engineer based on Istanbul/Türkiye. He is the co-founder of JUG Istanbul and co-orginizer of Java Day Istanbul. He previously worked at Koç.net, Hakia, and Toyota Motor Europe at various technical leadership and coaching roles. He has been actively programming with Java since 1999. He is a active practitioner and coach in Java architecture and Lean software development and Toyota Kata as problem solving approach.
He has already spoke at 40+ conferences (like JJUG Tokyo, JCON Germany, Lean Kanban France, TokyoTestFest, Java Day Istanbul, and many others) organized 100+ meetups,