Earlier quoted context omitted.
That's right, but it seems like it's fashionable to bash Java inventing example code that noone uses in prodcution. If I would see the code like this, I would ask the one that has written it to justify why he didn't just use IOUtils.copyStream method. Is there some performance reason he wanted to specify buffer size manually? Maybe he wanted to handle exceptions properly instead of wiling silently? Or he was on extre…
It's not just Java that is bashed with this tactic. For example, the TechEmpower benchmarks that keep getting reposted here do the same thing, except with languages other than Java, in order to make Java come out looking better.
That's getting a little off topic, but the TechEmpower benchmarks are open source and open to submissions. If you see a problem and you haven't submitted a pull request then you have no excuse for complaining.