1,350 karma · joined Jul 1, 2021 (5y ago) · 1,370 submissions
comment 5y ago · link · parent
For a compiler that can compile even with errors in the code, look at ECJ.
If you take HotSpot and attach a debugger in your IDE, then you have some hotswap capabilities [1]. You can redefine the contents of methods, add methods and add classes (e.g. lambdas). This is OK as far as it goes. But this is no inherent limitation of Java. In fact the debugger protocol lets you request arbitrary changes, it's just not all JVMs support them.
One that does is called DCEVM [2]. It fleshes out the hotswap capabilities far more extensively and lets you do things like delete methods, change prototypes, alter the inheritance hierarchies etc, all on the fly whilst the app is loaded and running.
DCEVM is an open source patchset onto HotSpot, but it's not really a pro level tool. JRebel [3] is a company that makes hotswap tools as a commercial product. Many companies use it.
These are a neat capabilities and I've used them a few times, but even with that level of power, it's not always complete for every use case. The problem is that most apps have initialized state. Web servers often do not, because they throw away state at the end of every request, and there it works better, but if you're working on e.g. a GUI or a CLI tool with a shell, or really anything where the program has to maintain state for longer than a split second, changing code becomes of more limited use because you are going to end up changing initialization code that won't re-run. You can add various ad-hoc hooks to your app to let you force re-init whilst running, but it's not totally smooth. Note: this isn't a limitation of the language or runtime. It's inherent to the concept of hotswapping code.
There is work to resolve even this problem. The Espresso JVM has full hotswap support, and a callback interface that lets the app learn when its own code is being redefined. It can use those callbacks to trigger re-initialization of any state that's required. [4] Espresso is still new but this sort of thing lights the way to apps that perhaps never need to be shut down at all, not even for upgrades.
[1] https://www.jetbrains.com/help/idea/altering-the-program-s-e...
[3] https://www.jrebel.com/products/jrebel
[4] https://www.graalvm.org/reference-manual/java-on-truffle/hot...
comment 5y ago · link · parent
Also, over the past 20 years what you've seen is big advances in the 'semi-static' world like the JVM, where it runs statically typed languages but they have the ability to eval code, redefine their own code on the fly, reflect themselves, they're garbage collected etc. This is kind of a middle ground. It's worth remembering that when Python and Ruby were new, there weren't really any great options if you wanted lightweight syntax with garbage collection. Nowadays there is Kotlin and you can write code that looks very similar to say Ruby, but which often has the performance of entirely statically typed languages.
comment 5y ago · link · parent
To know how much memory you really need, you'd need to keep shrinking the Xmx max heap size setting until performance becomes unacceptably poor. However, that isn't done here.
comment 5y ago · link · parent
comment 5y ago · link · parent
A good enough DRM system does not have to be 100% unbeatable all the time. It's sufficient to:
a. Delay a hacked release until after most of the sales have already occurred. This is very often the case with successful game DRM. A crack after six months is irrelevant because virtually all the sales are in the first month or so. A crack that comes out after everyone with interest has already ponied up doesn't matter much, and in fact an unbeatable DRM that never gets cracked would suggest misallocation of resources!
b. Focus cracks on a handful of specialists who can then be investigated and potentially prosecuted or bought out. A DRM so easy 100,000 people can crack it is very different to a DRM that only 5 people have cracks for and where they keep their cracks private. The latter becomes amenable to non-technical approaches. Again, an unbeatable DRM would probably represent a waste of effort.
There are quite a few DRM schemes that have achieved this level of good-enough success which is why despite decades of people railing against it in online forums such as this one, it sticks around regardless.
comment 5y ago · link · parent
But, apparently not Widevine and not the kind of HN reader who wrote the article. They spent weeks trying to extract the key and failed. The article is a story of their failure.
comment 5y ago · link · parent
comment 5y ago · link · parent
This is a massive understatement. There's a lot of comments here by people who clearly want to like and support GDPR but have never actually tried to "comply" with it in a large business. GDPR is a textbook example of how not to write law (unless of course you're actually trying to create a despotic regime). It has so many problems when viewed from a law engineering perspective that it's really quite expected that a lot of companies will just give up, because the only plausible explanation for the way it's written is to be able to arbitrarily fine certain types of companies on demand.
1. Absolutely everything is maximally vague and subjective. Whoever wrote it never wanted to have to justify any decision made under its authority. Everything is defined with terms like "legitimate", "disproportionate", "significant", "likelihood", and the perennial favorite "reasonable effort". If you believe you have a legitimate need or made a reasonable effort and a regulator doesn't, or that your users are giving consent and then someone else claims it isn't explicit enough, who can say who's right? There are no standards on which to judge anything so it turns into a pure difference of arbitrary opinion. Merely being conservative is no use at all because you don't even have any idea, based on reading the law, whether what you're doing would be considered conservative or aggressively non-compliant. Nor does anyone else.
2. Compliance is basically impossible for any large institution. The EU Commission was itself non-compliant on the day GDPR came into effect, which was noticed immediately, and their response was that they had written themselves (and nobody else) an exception into the law so that they had more time to comply with it. When the government that writes a law acknowledges an inability to follow it by the deadline they set for everyone else, you know a law has problems.
3. Because the law is written so badly you can find plenty of people interpreting it in ways that would imply Amazon is doing nothing wrong, like this page [1] which purports to be busting GDPR myths and states that "processing is subject to stricter rules only if the profiling "produces legal effects" concerning the data subject or "similarly significantly affects" that individual. This will unlikely be the case for most advertising-related profiling and for the personalization of offerings".
4. GDPR theoretically requires every company in the world to comply, or does it? It's triggered by "offering" services to people in the EU, but what counts as "offering" is left undefined and like everything else, could be interpreted in dozens of different ways. Is having a website sufficient? Nobody knows. Here's PriceWaterhouseCoopers' advice on GDPR compliance for Switzerland [2] which starts by saying "My company is only Swiss-based, does it have to comply with GDPR? Alas, there is no simple answer to this.".
The fact that so many results when searching for GDPR are articles that claim to be debunking myths about it, and that so many such pages directly contradict each other, is indicative of the massive level of confusion this law has justifiably generated. It can be interpreted in any way any government wants to justify almost any level of fine imaginable, and governments are directly incentivized to do exactly that. Cynicism about GDPR and its motives will not go away by simply having lots of EU-loyal HN posters tell Americans that compliance is easy when it so obviously isn't.
[1] https://www.vischer.com/en/knowledge/blog/the-gdpr-and-switz...
[2] https://www.pwc.ch/en/insights/tax/gdpr-swiss-based-companie...
comment 5y ago · link · parent
comment 5y ago · link · parent
https://www.washingtonpost.com/health/2021/07/29/cdc-mask-gu...
Internal CDC documents have leaked. Here are some quotes from the report:
"It cites a combination of recently obtained, still-unpublished data from outbreak investigations and outside studies showing that vaccinated individuals infected with delta may be able to transmit the virus as easily as those who are unvaccinated. Vaccinated people infected with delta have measurable viral loads similar to those who are unvaccinated and infected with the variant."
"The breakthrough cases are to be expected, the CDC briefing states, and will probably rise as a proportion of all cases because there are so many more people vaccinated now. This echoes data seen from studies in other countries, including highly vaccinated Singapore, where 75 percent of new infections reportedly occur in people who are partially and fully vaccinated."
"The presentation highlights the daunting task the CDC faces. It must continue to emphasize the proven efficacy of the vaccines at preventing severe illness and death while acknowledging milder breakthrough infections may not be so rare after all, and that vaccinated individuals are transmitting the virus. The agency must move the goal posts of success in full public view."
There are some other points worth noting from the presentation:
1. The frequent and very US specific claim that "99% of hospitalizations are in the unvaccinated" isn't true. CDC stats show 15% of hospitalizations are from vaccinated people and the number is growing. Why are they claiming otherwise in public?
2. The confidential data is not really surprising, because it brings the USA into line with what every other country is seeing.
There's a good summary of some of the latest non-US data from UK and Israel here. Efficacy against infection and "mild illness" keeps falling:
comment 5y ago · link · parent
See for yourself. Google [iceland covid] and look at the graph. Cases go near vertical starting 16th July and are now the biggest wave they've ever had. Then click through to the vaccinations tab. They had vaccinated 70-75% of their population by that date (depending on whether you count first dose or second).
If 75% of the population are vaccinated yet case curves are bigger than before, the vaccination is not stopping transmission.
Edit: Also, recent data from the UK suggests effectiveness against infection has fallen to <20% in the over 50s. The calculations based on PHE data can be found here:
https://dailysceptic.org/2021/07/25/phe-data-shows-vaccine-e...
By the way, are you flagging all my posts? Do you realize that's against the rules? Nothing in my last three posts is a flaggable offence yet suddenly they are all flagged. Do you want me to do the same to you if so?
comment 5y ago · link · parent
Most people under the age of about 65 are being asked to take a vaccine for a disease that is extremely unlikely to hurt them, and the vaccine itself can have severe side effects, with deaths and injuries from these vaccines now greatly exceeding the deaths and injuries from every other vaccine programme in the last 10 years combined.
Over-simplifying this situation down to "people need to be protected [from themselves]" is exactly the sort of misinformation that Facebook believes it's fighting.
"This leaves the latter group stumped, because they can’t think of any non-selfish motives"
Non selfish motives? Their demands are incredibly selfish. They've convinced themselves, against all actual data and biological theory, that the unvaccinated people are dangerous to themselves, the vaccinated, and thus individual choice over people's own bodies must be removed by force. There is no basis for this belief but they apparently want to reach this conclusion via any means, fair or foul. Despite that they are the same people who are usually insistent that women be given choice over 'their own bodies' in abortion debates.
comment 5y ago · link · parent
Very few fact checking organizations appear to actually use critical thinking of any kind. They claimed they would be but they're just journalism interns normally, so they just degrade to assuming that whatever the government or ideologically aligned academics say, is the truth, and anything else is wrong.
comment 5y ago · link · parent
Regardless, I can see you already have your conclusion and will stick to it. So be it.
comment 5y ago · link · parent
No surprise, it appears to be staffed by people who were selected for their middle-of-the-road "you must censor a bit but not too much" type of views. It gave them a limp wristed rap on the knuckles when they banned Trump, said it was arbitrary and didn't follow the same rules enforced on everyone else, but that they still agreed with doing it.
I think what we're seeing here is what happens when you lack some sort of free speech libertarian fundamentalism. Facebook don't have to engage in "statecraft", whatever that is, no more than the designers of SMTP did. They could choose not to. They could say "we will shut down accounts when under court order to do so, end of story". Then governments who think a citizen is breaking a law about speech would have to go to court, win, and then the judge would say, here is an order requiring Facebook to shut down the account of this law breaker (which could automatically hide all content they created). All the evolved mechanisms, the checks and balances of the actual state would be in effect.
But Facebook is based in Silicon Valley and like most firms there, has systematically made deals with far-left devils in order to hire them and put them to work, often without really understanding if it's worth the cost. Does Google actually need 144,000 employees for example? It hardly seems more productive than when I started there and it had 10,000. Their "hire first ask questions later" approach inevitably leads to hiring lots of extremists and wingnuts, people who are there primarily to get closer to a nexus of power they can wield for their own political agendas. The constant dramas we see emanating from Mountain View, Palo Alto and San Francisco are the inevitable consequence.
Tech firms could fix this problem very quickly if they wanted to: just announce a renewed commitment to freedom of speech, platform principles and passive moderation. Any employee who doesn't like it can leave. Many would, but those companies are so over-staffed they'd barely notice, and the environment for those who remain would be drastically more pleasant.
comment 5y ago · link · parent
There's lots of debate about whether that's really how respiratory viruses spread, but more importantly, we know it can't be that simple because we can see the effect mask mandates had on case curves (there wasn't any). So however they're theorized to work, real world data disagrees. There can be lots of reasons for this that aren't even related to mask material, e.g. most transmission occurs in homes, care homes and hospitals, all places where you'd expect most transmission to take place because people have to be confined in a small space with other sick people for long periods, and also places where you can't make people wear masks all the time.
comment 5y ago · link · parent
https://www.covid19.admin.ch/en/hosp-capacity/total
As you can see, it never got above ~80% utilization, even though Switzerland's second wave peaked many weeks before restrictions were re-imposed. The Swiss system is well funded, but it's not an alien planet. If they can do it any developed country can. Also remember that lots of places built emergency hospitals. They were invariably never used.
Or look at Swedish data.
https://www.folkhalsomyndigheten.se/contentassets/4b4dd8c7e1...
Sweden started the pandemic with the lowest ICU capacity in the EU yet their age adjusted mortality only reached the same level as in 2012 - not even a "once in a decade" level problem.
https://softwaredevelopmentperestroika.wordpress.com/2021/01...