Beware that this polyglot feature you've mentioned is not moving to OpenJDK.
Can someone play devil's advocate to explain how this news may actually favor this negative view of Oracle? The sentiment in this thread is praising Oracle's decision here, so I'm just curious if there's an alternative viewpoint that's skeptical or wary of this decision and Oracle's motivation to make it.
With that said, I'm not looking for reason to diminish the positives. I'm just curious. Good moves that benefit the community should absolutely be acknowledged and encouraged.
EDIT: It looks like another person commented how this may not be benevolent in the context of WebAssembly while I was slowly typing this comment up on mobile. I'd still be interested in this discussion though.
I've been at this long enough to have had my own experiences and they are indeed as bad as everyone has warned me, but it does feel like something you have to experience yourself (or at least through a trusted party like in my case) to totally believe.
The parent apologist was extremely precise in how they described Oracle. Oracle isn't in the "Be warm and fuzzy to developers" business: they're in the "Provide mission critical software to large enterprises" business. Logic for servicing the latter well makes things look screwy or sinister to people used to the former.
Which isn't to say the Oracle salespeople aren't scummy. But most salespeople are scummy. That's what happens when you incentivize closing sales, which is how almost all sales orgs are set up. So audit model + scummy salespeople = bad experiences. But to parent's point: what's a better model for their customer persona?
I'm a bit young to have ever known much about Sun, but I get the impression that they were very respected for their products and commitment to open source, and Oracle's purchase seems to have really rankled the community. Interestingly, the only Oracle products I use are all from the Sun era - MySQL, Java, Virtualbox, and ZFS.
I have no idea about this graal thing and I think it's rather niche application. I played with it but concluded that it's not ready for me yet.
The generalized dislike of Oracle you have seen really comes from a couple of different aspects, neither of which are relevant to this specific announcement:
1. License audits suck.
2. The Google lawsuit (about matters resolved long ago and which don't apply to anyone except Google, really).
A lot of ill will comes from people whose companies have been audited. The process is by all accounts very painful. However, what's rarely mentioned in such discussions is the alternatives and why Oracle does this. It's because their software is totally DRM free. It makes sense; you can't have a major airport or bank shutting down suddenly because a license key or credit card expired, can you? Oracle DB is mission critical stuff, it must be always available. That's why they use an audit model - it's "trust but verify". They make their stuff available for free download and you promise not to pirate it.
Every so often Oracle turn up and check to see if you're paying for what you're using. At this point there are usually two problems that crop up:
1. The company doesn't actually know if it's correctly paying for Oracle's stuff. It requires a lot of work to find out, maybe the right controls weren't in place and naughty developers just installed more copies because it was convenient etc. Then they discover they've unknowingly been pirating the DB.
2. And/or they discover they didn't understand the licensing model, which historically had some very sharp edges around virtualization (maybe still does).
Because the downloads are open and unrestricted by any form of DRM, it's easy to make these mistakes in a company that doesn't have good processes in place. At this point the users have a problem because it's just plain old copyright violation. Oracle prefers not to sue its own users for obvious reasons so at this point a third issue crops up - their sales guys like to cut deals. Buy more of our software and you'll have some useful stuff plus we'll forget about your non-compliance issues. Win/win, right? Not always for the people who aren't at the top of the firm of course, who may now be told to adopt some new product that they wouldn't otherwise have chosen and may not even be told why (it's embarrassing for the executives to admit they ended up in that situation!).
It's worth observing that with the cloud these problems go away. Use Oracle DB only in the cloud (or MS SQL etc) and the cloud provider will track your usage and ensure you're paying for it. In turn that means no need for audits.
It's very easy to criticize Oracle for the above outcomes. It's harder to come up with alternative approaches beyond really down in the weeds stuff like the exact ways virtualized cores are licensed, etc. The moment you have a commercial product there needs to be some way to ensure users are paying for it (because a lot simply won't if there's nothing in place to make them), but if you accept that outages cannot be caused by DRM or licensing errors, then you are almost forced to go with either the cloud or the audit+true-up approach. Many modern DB firms go hosted-only which brings its own problems (see the recent Azure leak). Plus Oracle DB predates the cloud, so ...
I guess my default (and flawed) heuristic is to assume that a big corporation has an ulterior motive with goodwill or community-focused announcements. I'll take this as a learning opportunity to not blindly adopt what I perceive as the general sentiment, to stop relying on such a heuristic, and to do my own research and evaluation. In addition to the detailed response, thank you for also indirectly kicking my butt into reevaluating how I approach the unknown both logically and emotionally.
This particular announcement isn't even meant to generate goodwill really, although I can see why it's interpreted that way. It's not like there's a new open source release coming. It's just resolving some duplication issues in the way these already open source projects are being developed by Oracle "donating" from one arm to the other :) The goodwill should instead come from the decade+ funding of this very advanced and large research project, which is teaching the world a lot about fundamental computer science (complete with large set of academic papers), and for which almost all the core cleverness is given away under liberal licenses.
Be aware that they do have a commercial offering built on top of Graal, the enterprise edition. It makes programs go faster, and has a few other useful features. But there's nothing nefarious about that of course.
A large part of Oracle's bad reputation comes from a history of entering markets, gaining a captive customer base, and then engaging in blatant rent-seeking that squeezes every last penny that they can out of their customers.
As a direct example, I'm in the healthcare space and specifically work in a Cerner shop. Our quotes from Cerner for routine integration projects have gone up literally 5-10x since Oracle acquired them. An EHR migration costs well into eight figures, so Oracle is fully aware that customers aren't easily going to be able to move away from them because things that were $15-30K (and still are with other vendors) are now running into the six figures, but it certainly doesn't leave a positive taste in the mouth.
And we knew this was coming as soon as the Oracle acquisition was announced. Because Oracle has built a reputation for doing exactly this across multiple markets over multiple decades.
Do you honestly think that all those libraries care about Pride or Black Lives Matters? Nope, they just had some calculations and as user-facing companies, marketing has a huge role on their profits. A logistic company won’t have done any such thing as they are likely not even known by the general public.
Oracle is not really an end-user facing company like Facebook or Google is, so they simply don’t care all that much about that (hence the lawnmower analogy). But.. that’s a good thing as well — you can use the lawnmower for its job, you’ll never be surprised. Graal and OpenJDK and other tech at the bottom of the tech stack are long term investments. Looking at the linux kernel, it is not developed primarily by some hacker in a basement, but by employees paid by Intel, Red Hat, Google, pretty much everyone.
This move is good for Graal, as it will help it compete, but there’s still a big question in my mind at least about if Graal is going to be able to compete long-term. Yes, I know Graal can also execute WASM generated binaries, so it may have a space in this environment, but will it outperform native WASM VMs? And will WASM become the de facto binary format for shipping things where JVM bytecode has been used in the past? What’s Graal’s place in the future?
Truffle is interesting because it says, no, we should not be trying to compile everything to a universal bytecode. Instead, we should JIT compile the source code directly, using the JVM as a runtime library but bypassing the bytecode layer. The language semantics can be expressed much more clearly, without needing to contort things to make them look like Java, whilst still benefiting from the JVM's core feature set.
So really I'd ask it the other way around. If it weren't for the politics of the browser world and the monolithic "Chrome is the OS" approach, would WASM be competitive? Because the Graal team already proved you can run lots of different languages at relatively insane speeds using partial evaluation and bypassing bytecode. The WASM world has proven it can run C++ and Rust at slower speeds than normal, which isn't particularly unexpected. If Chrome and Safari shipped GraalVM accessible via <script> tags, how many people would care about WASM? Remember that you can run WASM and LLVM bitcode on top of GraalVM too, it's not just about textual languages.
Arguably, if you wanted to give the web an instant free upgrade that'd make many developers rejoice, integrating Graal into Chrome would be an overnight way to do it. Python, Ruby, JVM bytecode and any other language you want at V8 like speeds, in a script tag? It's technically possible, it's just not politically possible.
Maybe you can:
"TeaVM is an ahead-of-time compiler for Java bytecode that emits JavaScript and WebAssembly that runs in a browser. Its close relative is the well-known GWT. The main difference is that TeaVM does not require source code, only compiled class files. Moreover, the source code is not required to be Java, so TeaVM successfully compiles Kotlin and Scala."
I have never had an opportunity to try out TeaVM, but it seems promising.
I should have clarified. Yes, you can probably do a native-image style "compile an app+embedded JVM to wasm" by pretending V8 is a CPU. There are programs that do that sort of thing, I think Leaning Technologies makes one. That wouldn't be of use in any existing Java project though. The only reason you'd ever want to do that is because browsers offer nothing else, even though they could and at that point why not compile to JS, at least that way your GC isn't being interpreted too. If you're not constrained by the WHATWG's decisions though it doesn't offer anything.
It looks like you mean CheerpJ: https://leaningtech.com/cheerpj/ https://github.com/leaningtech/cheerpj-meta
>> That wouldn't be of use in any existing Java project though. The only reason you'd ever want to do that is because browsers offer nothing else, even though they could and at that point why not compile to JS, at least that way your GC isn't being interpreted too. If you're not constrained by the WHATWG's decisions though it doesn't offer anything.
It is very use case and "what is the future of your Java application" dependent. Some organizations are looking into migrating off of Java due to a variety of reasons. These kind of "Java conversion" tools help to keep legacy Java applications running until the legacy Java applications can be replaced.
- run wasm interpreted on OpenJDK, similar to javascript running interpreted in nashorn, or now graalvm, you just need to add couple of graal sdk jars to your dependencies
- run wasm compiled, you need to run on GraalVM for this. This is supposed to provide around 50x speedup compared to previous point
https://www.graalvm.org/22.3/reference-manual/python/
or is that something different?
That’s a good question, and partly why I was pointing out that it’s not just benevolence for Oracle to OSS this. I don’t know if the browsers vendors could embed Graal, maybe they can, (license restrictions being some of the issues I’m sure) and then that could supplant the individual JS and WASM runtimes they support. But this wasn’t even an option until today.
> Remember that you can run WASM and LLVM bitcode on top of GraalVM too, it's not just about textual languages.
Which is exactly why I mentioned that in my original comment. Yes, Graal could be that runtime, will it? Seems like a gamble for anyone who’s not already in the JVM ecosystem to some degree.
Well, some GC'd languages support compilation to WASM, for example, you can compile go to WASM. The issue here is that for GC'd languages you have to bring your own runtime with GC in every module, so this doesn't really work.
* to run faster
* to get a better JIT compiler, better GC, sandboxing, etc
* to run using code from other JVM languages in the same process
* to get the JVM's monitoring tools
* to embed into a Java application
This may be more readable: https://github.com/oracle/graalpython/blob/master/docs/user/...