5 ms·
yup... I think browser need to come with some type of bytecode or vm that supports concurrency so we can finally have a true app platform.
by annon23 9y ago
yup... I think browser need to come with some type of bytecode or vm that supports concurrency so we can finally have a true app platform.
- andrewguenther 9y agoDon't you already have this with WebWorkers? This isn't a limitation of the environment per se as much as it is a limitation of the DOM.
- annon23 9y agowe should develop software using different languages as well, web workers are part of the solution
- pmontra 9y agoThe DOM wants to be accessed sequentially by a single thread, then we ended up to say single threading is good because we don't have alternatives and because we're using the same frontend technology for backend jobs (v8.) It's a kind of Stockholm syndrome. Sequential access to the DOM can be ok because we are the only user of the browser. Single processing is not so ok on the backend because there could be thousands of users there. We scale Ruby, Python and Node with multiple processes (I'm doing it.) I'm also developing an Elixir application using Phoenix. The approach is similar to writing Rails or Django code (I never sent a single message in all the application) with the convenience of not having to manage sidekiq or celery for background jobs (they're in the language) and autoscaling.
- rixed 9y agoBrowser need to come with a bytecode that would run into the local container on the local operating system running on the VM on another operating system running on top of real hardware, so we can finally have a true app platform.
- icebraining 9y agoWhat's your point, exactly? Shipping bytecode is essentially the leanest way you can achieve platform-independent code execution, no?
- rixed 9y agoMy point is that we could ship bytecode long before browser were even invented, therefore I doubt that the explosion of complexity is caused by us trying to solve that problem. This is easy to test: we just have to wait until we can ship byte code through the browser, and see how long it takes for another layer of abstraction missing some important feature to pop up on top of it.
- EdSharkey 9y agoAssuming you're not being snarky, hold on to your pants ... As a baseline, you have Asm.js[1] + Web Workers[2] today in most browser places (actually, all places, if you creatively polyfill.) For newer-fangled browsers only, you have Web Assembly[3] + Web Workers, which takes in-browser performance to a whole 'nother level. Now, the Web Assembly spec isn't stopping at replacing Asm.js. There's going to be support added for SIMD and vectors and whatever cool stuff newer processors can do. The big deal will be once Web Assembly gets the ability to do syscall-like thunks to DOM API and the other myriad JavaScript API. At that point, the browser's a full OS platform capable of hosting most applications. This new thing will then be able to go beyond any previous application platform in terms of reach and ultimately, capability. Just forget about the term "browser" when the thunks appear. This will be a new "Platform 1.0" that will span all modern operating systems and devices. Node.JS will implement a compatible "Platform 1.0" subset for server-side platforming where client and server will be able to share binary libraries. This is coming soon. If you've got some great idea for a next generation online app, it's time to start working hard and have it target "Platform 1.0"! [1] http://asmjs.org/ http://asmjs.org/ [2] https://developer.mozilla.org/en-US/docs/Web/API/Web_Workers_API/Using_web_workers https://developer.mozilla.org/en-US/docs/Web/API/Web_Workers... [3] http://webassembly.org/ http://webassembly.org/
- solarengineer 9y agoJava Applets - run bytecode in a VM (called the JVM) in the browser, and use multi-threading supported by the JVM.