Explores the evolution of URL handling in Java, questioning whether generic URL APIs like URL.openConnection() were a good design choice. The author argues that Java 11's HttpClient, being protocol-specific rather than generic, represents better API design. Generic URL handling introduces security risks, performance unpredictability, and forces lowest-common-denominator APIs. Modern applications typically handle a single URL scheme and benefit from specialized, focused implementations rather than attempting universal URL support.
Post #1993
15.1K

Were URLs a bad idea?
- ❤ 14
- 👍 3