News for hackers. Stuff that matters.
Re:Removal of Unsafe in Java 9 – A disaster in the making by geofft on Monday July 13, 2015 @11:26AM (#9878698)
The quote stops short, and for someone like me who doesn't follow Java very much, it feels like it's misquoting via omission:

"Let me be blunt -- sun.misc.Unsafe must die in a fire. It is -- wait for it -- Unsafe. It must go. Ignore any kind of theoretical rope and start the path to righteousness _/now/_. It is still years until the end of public updates to JDK 8, so we have /years /to work this out properly. But sticking our heads in the collective sands and hoping for trivial work arounds to Unsafe is not going to work. If you're using Unsafe, this is the year to explain where the API is broken and get it straight....

"Please help us kill Unsafe, kill Unsafe dead, kill Unsafe right, and do so as quickly as possible to the ultimate benefit of everyone."

The quoted engineer understands that people use it, claims that there's no immediate risk (since Java 8 will stay around), and very very strongly implies that there is a plan to move from Unsafe to something better than Unsafe providing equivalent functionality in a stable way, and asks for help with that. Is this correct?

Re:Removal of Unsafe in Java 9 – A disaster in the making by colin_mccabe on Monday July 13, 2015 @10:18PM (#9882475)
I disagree that the article is "misquoting via omission." The article claims that "this engineer hates the Unsafe class for no real reason at all." The full quote which you reproduced doesn't offer any reasons for hating unsafe.

I also disagree that there is "no immediate risk." The end-of-life date for Java 8 is 2017, only 2 years from now. It can easily take a year or two to develop a product or internal tool. Would you sign off on a big new performance-critical project in Java, knowing that you might not be able to get the performance you want when these low-level APIs are removed?

Java has had a bunch of security problems in the last few years, but most of them have not been related to Unsafe at all. For example CVE-2013-0422 related to Java webapps, CVE-2013-4444 related to Tomcat, and so on. There were a bunch of bugs for POODLE and other SSL issues, similar to many other programming languages. Perhaps you could argue that CVE-2013-0422 was related to Unsafe, but since in this case it was an internal standard library class, presumably Oracle would continue to give itself permission to use whatever unsafe-equivalent they come up with.

If new APIs are needed are needed to replace uses of Unsafe, Oracle could simply add them gradually over time. This would be low-risk and easy for everyone. I can't see any reason why Unsafe needs to be "kill[ed]... as quickly as possible."

Re:Removal of Unsafe in Java 9 – A disaster in the making by pdeva1 on Monday July 13, 2015 @01:58PM (#9879788)
The post directly links to the full quote. If the intention was to misquote that would not be the case.

> there is a plan to move from Unsafe to something better than Unsafe

It is this plan and the implications of it that the post is discussing

Re:Removal of Unsafe in Java 9 – A disaster in the making by scott_s on Monday July 13, 2015 @02:22PM (#9879940)
The intention may not have been to misquote, but that is the effect that I saw. I had a similar reaction that geofft did when I read the whole email: it sounds like a reasonable effort to start the process of moving to something better than what is currently available. The submission here does not seem to take that into account.
Re:Removal of Unsafe in Java 9 – A disaster in the making by gclaramunt on Monday July 13, 2015 @02:16PM (#9879900)
Actually I don't see the post discussing anything, is just feels like "Unsafe is going away, the sky will fall!"
Re:Removal of Unsafe in Java 9 – A disaster in the making by BhavdeepSethi on Monday July 13, 2015 @01:21PM (#9879506)
Re:Removal of Unsafe in Java 9 – A disaster in the making by jryan49 on Monday July 13, 2015 @11:40AM (#9878804)
Yes you are.