22. Integration-Oriented
• Rhino
- Interaction with Java (APIs and objects)
- Helma, Persevere, Narwhal, RingoJS, Sun Phobos...
• JScript .Net
- Interaction with MS .NET (APIs and objects)
- IronJS, Node.NET
23. Common JavaScript
• Working Groups:
- CommonJS
- WHATWG
- W3C
- ECMA TC39
• Ubiquity not only for ECMAScript
• HTML5 is also known as: “Web Applications 1.0”
• Asynchronous & Synchronous APIs
24. Async. Event-based
Node.js like
• Browser Event-Loop on the Server
• An Event Loop in one single thread
• Cooperative («one at a time») with async. callbacks
• Node.js (V8), SpiderNode, RhiNodeII, Node.NET
25. Single & multi threading
One context per thread
SINGLE MULTI
• Low memory usage • Vertical scalability (multi-core)
• Potentially handle lot of requests • Thread-safety for concurrent access
• Cooperative • Preemptive: Parallel code execution
• Shared context • Allow Synchronous APIs
• Use mostly one core • Uses easily all available cores
Notes:
- an event loop can generate some other threads
- multi-thread architectures can run event loops in some of their threads
32. State of the Art
Server-Side JavaScript
The End
or... the beginning....
@amorgaut 4d.com
@thibarg Wakanda.org
@wakanday Wakanday.org
Thanks to the CommonJS community
Editor's Notes
When we started to define the Wakanda project, we did a lot of research and tests before concluding what would be the best language for it on the server and with which engine. We then decided to share with the others what we knew and what we learned. And here come this presentation.\n
\n
Brendan Eich creates JavaScript for NetScape.\n1 year after, he puts it on the server.\nEach time Microsoft followed just one year after.\nThe Server-Side JavaScript is 15 years old.\nBackend developers were not much convinced and mostly choose to ignore it.\n
JavaScript long growing maturity.\nMozilla Rhino and Microsoft IIS were the only ones running JavaScript/JScript on the server.\nJavaScript finally had respected standards, development tools, libraries, frameworks, performances.\n\n
Aptana was well respected for its support of JavaScript and JS frameworks in its Studio.\nWhen they tried to launch their Cloud solution with JS on the server via Jaxer, lot of JS experts were enthusiastic. John Resig immediately shared its own experiences on its blog.\nIn 2008, first presentation of Wakanda at The Ajax Experience ;-)\nA group called ServerJS were created from the Mozilla Developper Tools community with Kevin Dangoor.\nIt became more independent and choose to be renamed CommonJS to create standard server-side & client-side JS APIs.\nNode.js proposed an Async Event-Loop model on the server via the Google V8 JS engine. V8 had good reputation, and the concept looked quite revolutionary to JS developers.\nThe Long time running Helma choose to rename Helma NG for a new brand: RingoJS\n
Aptana was well respected for its support of JavaScript and JS frameworks in its Studio.\nWhen they tried to launch their Cloud solution with JS on the server via Jaxer, lot of JS experts were enthusiastic. John Resig immediately shared its own experiences on its blog.\nIn 2008, first presentation of Wakanda at The Ajax Experience ;-)\nA group called ServerJS were created from the Mozilla Developper Tools community with Kevin Dangoor.\nIt became more independent and choose to be renamed CommonJS to create standard server-side & client-side JS APIs.\nNode.js proposed an Async Event-Loop model on the server via the Google V8 JS engine. V8 had good reputation, and the concept looked quite revolutionary to JS developers.\nThe Long time running Helma choose to rename Helma NG for a new brand: RingoJS\n
Aptana was well respected for its support of JavaScript and JS frameworks in its Studio.\nWhen they tried to launch their Cloud solution with JS on the server via Jaxer, lot of JS experts were enthusiastic. John Resig immediately shared its own experiences on its blog.\nIn 2008, first presentation of Wakanda at The Ajax Experience ;-)\nA group called ServerJS were created from the Mozilla Developper Tools community with Kevin Dangoor.\nIt became more independent and choose to be renamed CommonJS to create standard server-side & client-side JS APIs.\nNode.js proposed an Async Event-Loop model on the server via the Google V8 JS engine. V8 had good reputation, and the concept looked quite revolutionary to JS developers.\nThe Long time running Helma choose to rename Helma NG for a new brand: RingoJS\n
\n
\n
Spidermonkey now looks more C++ now but its API are still in C\nComplex Webkit naming\nTrident: Windows only\n
The growth of WebApps with Ajax Frameworks requires more powerful engines \n-> Browsers War II.\n
COmparing js with other technologies. Here, persevere is the best.\n
Who understood those stats ? ;-)\n
Benchmark results depends on use cases and context\n
\n
The core engines running on the server have finally reach acceptable performances, with quite comparable results.\nThey all actively continue their own performance enhancement.\nECMAScript 5 in strict mode also help to provide better internal optimizations.\n \n
\n
These solutions were mostly the ones which made JavaScript survive on the server\nAll missing stuff were covered by the environment in which they are running.\nIt’s then easy to make it’s application platform dependent which often what front-end JavaScript developers want to prevent.\n-> so then came the work on standards for the “missing stuff” ;-)\n
“JavaScript” is available in all modern mobile phones, tablets, Internet box, and even some remote control and TVs.\n- It is quite everywhere, but, back on the server, the JS engines only provide the Core of the language, mostly as defined by ECMAScript with ongoing features. \n- Ajax, Web 2.0, & HTML5 provided a very large & active open source community (first community on Github)\n- At least 4 important Working Groups are doing their best to make it better and better.\n- Common JavaScript oriented implementations want to enhance interoperability between each of them, hopefully more quickly than how it came on client-side.\n
\n
\n
\n
\n
\n
\n
\n
\nNPM: Author ?\nCPM: by Kris Zyp\nPINF: by Christoph Dorn\n