Java Devs Go! the Wrong Way 7 Times
summary
Seven concrete migration mistakes from Java to Go, with fixes and numbers: treating every error like an exception is wrong — return errors as values, reserve panic for unrecoverable cases; pointer misuse requires dereferencing and assigning to struct fields, not reassigning addresses; avoid Java-style getters/setters and needless pointer receivers; stop faking inheritance — prefer interfaces and composition; don’t call runtime.Gosched or copy Java threading idioms, use channels; using buffered channels cuts the example runtime from 10s to 5s.
AI-written summary · about
chapters (9)
- 0:00Introduction and background
- 2:29Treating errors as exceptions
- 4:36Misusing pointers
- 5:41Overusing OOP design
- 7:50Imposing Java inheritance
- 9:39Misusing goroutines
- 10:43Java concurrency patterns
- 12:06Inadequate channel understanding
- 13:54Closing and resources
related talks
52mGo Go Java Developer
42mGo Go Java Developer
17mFrom Java to Go: I Have a Hammer and See Nails Everywhere
01h 02mGo for Java Developers
45mWhat Can a Java Developer Learn from Golang?
49mGo, Java, Go!
28m"Common tips & mistakes" in Go — and How to Fix Them
46mWhy you can't use GO! (away from anti-patterns)
