hawk_ 2 days ago

This is incredible. Kudos to the team behind it. This requires knowing both the browser and JVM quite well.

I do wonder though why Oracle doesn't seem interested in building or acquiring some JVM in the browser.

3
maratc 2 days ago

> I do wonder though why Oracle doesn't seem interested

And then what? Everybody would write Java code and run their ... not quite "apps" but we can call it app-lets -- in the browser, so that "write once run everywhere" could be achieved?

mooreds 2 days ago

Nooo! I spent a summer in college writing physics education applets. The scars are still there.

Seriously, I do wonder what the real value of some of this WASM stuff is. I mean, seems cool to run a java (or rust or <insert language here>) app in the browser, but what is the real world use case? If I run an app in the browser, I still have to do all the server side business validation because "you should never trust the client".

What am I missing?

Edit: on reading other comments, apparently this is direct-to-js compilation, not WASM. The intent of the comment still stands.

mickael-kerjean 2 days ago

For my use case of building Filestash, WASM is a game changer in those 2 areas:

1. use libraries from ecosystem outside JS. In the past few months, I've added support for file types like psd, dbf, arrow, parquet and about 50 more. To give a concrete example: https://www.filestash.app/tools/parquet-viewer.html WASM open up a very exciting door. In the same idea, I stumbled upon a couple JAVA only libraries which I would love to ship on a browser and not have to create web service to interact with those.

2. enable third party to make plugin that can run in my app in a safe way. In my case, plugins are zip files containing a bunch of assets and the WIP piece is to be able to put wasm in there that will run server side without giving those plugins a blank check for acting crazy.

mooreds 2 days ago

Thanks, that's super helpful. For #2, do you run the WASM plugins in a sandboxed browser?

devrandoom 2 days ago

> why Oracle doesn't seem interested

It doesn't come with any lucrative extortion options to squeeze millions out of enterprises.

hawk_ 2 days ago

There ought be a fair amount of legacy Java code sitting in enterprises that they would be willing to pay for an Oracle® seal of approval for running parts in the browser.

May be they are aiming for graalvm to be the answer eventually. (actually I don't know whether graalvm in the browser is effectively aot and brings all the reflection/dynamic code issues with it.) Curious if someone knowledgeable in that ecosystem knows.

jeffreportmill1 2 days ago

I totally agree with this! Oracle still spends time and money promoting Java client, and the browser is now the largest client platform. They could really revitalize Java client by backing CheerpJ.