SlideShare a Scribd company logo
The future of server side JavaScript @olegpodsechin #froscon 20.08.2011
Why use JavaScript on the server? Language of the browser Competition amongst browser vendors means increased performance Code reuse between the server and client, no need for context switching Dynamic language No unnecessary constraints, allows one to mix procedural, object oriented and functional styles Allows for meta programing Data in JSON, no marshalling reduces amount of code
Why use JavaScript on the server? Lingua franca of the web Widely accessible, even to beginning developers Widely available in terms of platforms Decent IDE support Closures work well with asynchronous, real time web Diverse, active,  growing community – http://communityjs.org We are stuck with it for the foreseeable future
It's Trendy
ServerJS != Node Engines Environments Platforms Frameworks
Engines 1996 SpiderMonkey (Mozilla) 1998 Rhino (Mozilla) 2008 Nitro/SquirrelFish (Apple) 2008 V8 (Google) 2011 Chakra (Microsoft) 2012 Nashorn (Oracle)
Rhino JavaScript 1.7 Interpreted or compiled to Java bytecode, allows for continuations Includes new and old features like destructuring assignment (var {a, b} = x) and E4X Easy access to Java classes Recent patches improve performance, e.g. InvokeDynamic in Java7
V8 EcmaScript 5 Compiles to native code – fast! Extended via native libraries Primarily targets the web browser
CommonJS Modules - 1.0,  1.1 , Async/A Packages - 1.0,  1.1 Console System Unit Testing –  1.0 Binary - A,  B , C, D, E, Lite, F IO -  A , B, C Filesystem -  A , B JSGI - 0.2,  0.3 HttpClient –  A , B
CommonJS modules // math.js exports.add = function(a, b) {  return a + b; } // server.js var add = require('math').add; console.log(add(2, 2)); // client.js ???
CommonJS packages // package.json { &quot;name&quot;: &quot;hello&quot;, &quot;version&quot;: &quot;0.1.0&quot;, &quot;description&quot;: &quot;Hello world package&quot;, &quot;keywords&quot;: [&quot;hello&quot;, &quot;world&quot;], &quot;author&quot;: &quot;John Smith <john@smith.com>&quot;, &quot;main&quot;: &quot;./lib/hello.js&quot;, &quot;dependencies&quot;: {&quot;whatever&quot; : &quot;1&quot;}, &quot;engines&quot; : [&quot;v8&quot;, &quot;node&quot;, &quot;rhino&quot;], }
Future of CommonJS http://groups.google.com/group/commonjs Node mostly ignored CommonJS AMD split out into separate mailing list UncommonJS https://github.com/kriskowal/uncommonjs
Environments 1996 Netscape Livewire  1998 Helma (Rhino) 2007 AppJet (Rhino) 2008 CouchDB / Couch Apps (SpiderMonkey) 2008 RingoJS (Rhino) 2009 Narwhal (Rhino, V8, SpiderMonkey) 2009 Node (V8) 2010 Akshell (V8) 2011 Wakanda (Nitro) Over 30 in total http://wiki.commonjs.org/wiki/Implementations
Sync  vs. Async http.get(url1) + http.get(url2)
Sync vs.  Async function add(callback) { http.get(url1, function(response1) { var part1 = response1.data; http.get(url2, function(response2) { var part2 = response2.data; callback(part1 + part2); } } }
Interoperability Pure JavaScript CommonJS modules can run in any environment Templating, parsing, formatting, encoding – what else? Anything that does I/O must expose either a synchronous or an asynchronous API Dictates the style of interface exposed by higher level packages, e.g. database driver, ORM
API vs. Implementation Asynchronous, implement Node API Node RhiNodeII - https://github.com/lhofhansl/RhiNodeII SpiderNode - https://github.com/zpao/spidernode Node.NET - https://github.com/dnewcome/Node.net Synchronous, implement CommonJS API Ringo - https://github.com/ringo/ringojs Narwhal - https://github.com/280north/narwhal Common Node – https://github.com/olegp/common-node
Common Node Implements a number of  synchronous  CommonJS specifications on top of Node Uses node-fibers  Uses co routines or multiple stacks within the same process not a fork or a hack Google's Traceur to support latest language features Bridges the gap between Ringo and Node, sync and async Fibers, HTTP proxy code examples & benchmarks
 
 
 
Platforms Node Joyent, Heroku, Nodejitsu, Nodester, Nodesocket, CloudFoundry Ringo Erbix, AppEngine & any other Java platform Akshell
Frameworks ServerJS is missing a Rails like framework Asynchronous DIY using Connect, Express etc. with Node Less of a problem, since Node is often used as glue  Synchronous DIY using JSGI, Stick etc. with RingoJS Lack of a solid framework more of an issue
Trends Wider adoption Front end developers First time developers - http://www.codecademy.com Enterprises moving off legacy systems Java, PHP New operating systems Windows, mobile devices (but not WebOS)
Trends Web IDEs, XaaS Cloud9 – http://www.cloud9ide.com Akshell – http://www.akshell.com Compile to JavaScript languages CoffeeScript, AltJS http://altjs.org & http://notjs.org Extensible systems, crowd sourced functionality Think WordPress plugins + platform Locker Project http://lockerproject.org
Thank you! Questions? @olegpodsechin

More Related Content

What's hot (20)

PPSX
Webpack & EcmaScript 6 (Webelement #32)
srigi
 
PDF
Fix: static code analysis into our project
noelchris3
 
PDF
Python for IoT, A return of experience
Alexandre Abadie
 
PPTX
3 Things Everyone Knows About Node JS That You Don't
F5 Buddy
 
PDF
Golang Project Layout and Practice
Bo-Yi Wu
 
PDF
markedj: The best of markdown processor on JVM
takezoe
 
PDF
A Look at Command Line Swift
JoshuaKaplan22
 
PDF
CBDW2014- Intro to CommandBox; The ColdFusion CLI, Package Manager, and REPL ...
Ortus Solutions, Corp
 
PDF
An Introduction of Node Package Manager (NPM)
iFour Technolab Pvt. Ltd.
 
PDF
The Parenscript Common Lisp to JavaScript compiler
Vladimir Sedach
 
PDF
Building GUI App with Electron and Lisp
fukamachi
 
PDF
Cache in Chromium: Disk Cache
Chang W. Doh
 
PPTX
Data Management and Streaming Strategies in Drakensang Online
Andre Weissflog
 
PPTX
Mongo db - How we use Go and MongoDB by Sam Helman
Hakka Labs
 
PDF
蔡学镛 Rebol漫谈
d0nn9n
 
PDF
Understanding how concurrency work in os
GenchiLu1
 
PDF
The Future of library dependency management of Ruby
Hiroshi SHIBATA
 
PDF
Introduction to protocol buffer
Tim (文昌)
 
PDF
Lunch and Learn - FFmpeg
Nuruddin Ashr
 
PDF
Calling java from a bash script 5
idrsolutions
 
Webpack & EcmaScript 6 (Webelement #32)
srigi
 
Fix: static code analysis into our project
noelchris3
 
Python for IoT, A return of experience
Alexandre Abadie
 
3 Things Everyone Knows About Node JS That You Don't
F5 Buddy
 
Golang Project Layout and Practice
Bo-Yi Wu
 
markedj: The best of markdown processor on JVM
takezoe
 
A Look at Command Line Swift
JoshuaKaplan22
 
CBDW2014- Intro to CommandBox; The ColdFusion CLI, Package Manager, and REPL ...
Ortus Solutions, Corp
 
An Introduction of Node Package Manager (NPM)
iFour Technolab Pvt. Ltd.
 
The Parenscript Common Lisp to JavaScript compiler
Vladimir Sedach
 
Building GUI App with Electron and Lisp
fukamachi
 
Cache in Chromium: Disk Cache
Chang W. Doh
 
Data Management and Streaming Strategies in Drakensang Online
Andre Weissflog
 
Mongo db - How we use Go and MongoDB by Sam Helman
Hakka Labs
 
蔡学镛 Rebol漫谈
d0nn9n
 
Understanding how concurrency work in os
GenchiLu1
 
The Future of library dependency management of Ruby
Hiroshi SHIBATA
 
Introduction to protocol buffer
Tim (文昌)
 
Lunch and Learn - FFmpeg
Nuruddin Ashr
 
Calling java from a bash script 5
idrsolutions
 

Similar to The future of server side JavaScript (20)

PDF
CommonJS Frameworks
Janne Kuuskeri
 
PPT
JS everywhere 2011
Oleg Podsechin
 
PDF
Node.js
Matt Simonis
 
PDF
State of the art: Server-Side JavaScript - WebWorkersCamp IV - Open World For...
Alexandre Morgaut
 
PDF
Developing realtime apps with Drupal and NodeJS
drupalcampest
 
PPT
Node js presentation
martincabrera
 
PDF
Appenginejs (old presentation)
Panagiotis Astithas
 
PDF
Nodejs - A quick tour (v5)
Felix Geisendörfer
 
PPT
Server side JavaScript: going all the way
Oleg Podsechin
 
PDF
Nodejs - Should Ruby Developers Care?
Felix Geisendörfer
 
PDF
Node.js for Rubists
Sagiv Ofek
 
KEY
Dcjq node.js presentation
async_io
 
PDF
JavaScript Modules Done Right
Mariusz Nowak
 
KEY
Node.js - A practical introduction (v2)
Felix Geisendörfer
 
KEY
NodeJS
.toster
 
PPTX
Introduction to Node.js
Vikash Singh
 
PPTX
Beginners Node.js
Khaled Mosharraf
 
PDF
Matthew Eernisse, NodeJs, .toster {webdev}
.toster
 
PDF
JavaScript is the new black - Why Node.js is going to rock your world - Web 2...
Tom Croucher
 
PDF
JSLab.Руслан Шевченко."JavaScript как платформа компиляции"
GeeksLab Odessa
 
CommonJS Frameworks
Janne Kuuskeri
 
JS everywhere 2011
Oleg Podsechin
 
Node.js
Matt Simonis
 
State of the art: Server-Side JavaScript - WebWorkersCamp IV - Open World For...
Alexandre Morgaut
 
Developing realtime apps with Drupal and NodeJS
drupalcampest
 
Node js presentation
martincabrera
 
Appenginejs (old presentation)
Panagiotis Astithas
 
Nodejs - A quick tour (v5)
Felix Geisendörfer
 
Server side JavaScript: going all the way
Oleg Podsechin
 
Nodejs - Should Ruby Developers Care?
Felix Geisendörfer
 
Node.js for Rubists
Sagiv Ofek
 
Dcjq node.js presentation
async_io
 
JavaScript Modules Done Right
Mariusz Nowak
 
Node.js - A practical introduction (v2)
Felix Geisendörfer
 
NodeJS
.toster
 
Introduction to Node.js
Vikash Singh
 
Beginners Node.js
Khaled Mosharraf
 
Matthew Eernisse, NodeJs, .toster {webdev}
.toster
 
JavaScript is the new black - Why Node.js is going to rock your world - Web 2...
Tom Croucher
 
JSLab.Руслан Шевченко."JavaScript как платформа компиляции"
GeeksLab Odessa
 
Ad

More from Oleg Podsechin (11)

PDF
Why SaaS (in Helsinki)?
Oleg Podsechin
 
PDF
Staying safe in the cloud
Oleg Podsechin
 
PDF
Tips from angular js users anonymous
Oleg Podsechin
 
PPT
AngularJS - the folly of choice
Oleg Podsechin
 
PDF
Lean and mean MongoDB
Oleg Podsechin
 
PPT
RingoJS
Oleg Podsechin
 
PPT
What every developer can learn from startups
Oleg Podsechin
 
PPT
Current State of Server Side JavaScript
Oleg Podsechin
 
PPT
On Platforms
Oleg Podsechin
 
PPT
RingoJS
Oleg Podsechin
 
PPT
Grid and Cloud Computing Intro
Oleg Podsechin
 
Why SaaS (in Helsinki)?
Oleg Podsechin
 
Staying safe in the cloud
Oleg Podsechin
 
Tips from angular js users anonymous
Oleg Podsechin
 
AngularJS - the folly of choice
Oleg Podsechin
 
Lean and mean MongoDB
Oleg Podsechin
 
What every developer can learn from startups
Oleg Podsechin
 
Current State of Server Side JavaScript
Oleg Podsechin
 
On Platforms
Oleg Podsechin
 
Grid and Cloud Computing Intro
Oleg Podsechin
 
Ad

Recently uploaded (20)

PDF
UiPath DevConnect 2025: Agentic Automation Community User Group Meeting
DianaGray10
 
PDF
Future-Proof or Fall Behind? 10 Tech Trends You Can’t Afford to Ignore in 2025
DIGITALCONFEX
 
PPTX
MuleSoft MCP Support (Model Context Protocol) and Use Case Demo
shyamraj55
 
PPTX
Seamless Tech Experiences Showcasing Cross-Platform App Design.pptx
presentifyai
 
PPTX
New ThousandEyes Product Innovations: Cisco Live June 2025
ThousandEyes
 
PDF
[Newgen] NewgenONE Marvin Brochure 1.pdf
darshakparmar
 
PDF
“Computer Vision at Sea: Automated Fish Tracking for Sustainable Fishing,” a ...
Edge AI and Vision Alliance
 
PDF
SIZING YOUR AIR CONDITIONER---A PRACTICAL GUIDE.pdf
Muhammad Rizwan Akram
 
PPTX
AI Penetration Testing Essentials: A Cybersecurity Guide for 2025
defencerabbit Team
 
PDF
Transcript: Book industry state of the nation 2025 - Tech Forum 2025
BookNet Canada
 
PDF
Staying Human in a Machine- Accelerated World
Catalin Jora
 
PDF
Bitcoin for Millennials podcast with Bram, Power Laws of Bitcoin
Stephen Perrenod
 
PPTX
Future Tech Innovations 2025 – A TechLists Insight
TechLists
 
PDF
Go Concurrency Real-World Patterns, Pitfalls, and Playground Battles.pdf
Emily Achieng
 
DOCX
Cryptography Quiz: test your knowledge of this important security concept.
Rajni Bhardwaj Grover
 
PDF
“NPU IP Hardware Shaped Through Software and Use-case Analysis,” a Presentati...
Edge AI and Vision Alliance
 
PDF
CIFDAQ Market Wrap for the week of 4th July 2025
CIFDAQ
 
PDF
The 2025 InfraRed Report - Redpoint Ventures
Razin Mustafiz
 
PPTX
COMPARISON OF RASTER ANALYSIS TOOLS OF QGIS AND ARCGIS
Sharanya Sarkar
 
PDF
POV_ Why Enterprises Need to Find Value in ZERO.pdf
darshakparmar
 
UiPath DevConnect 2025: Agentic Automation Community User Group Meeting
DianaGray10
 
Future-Proof or Fall Behind? 10 Tech Trends You Can’t Afford to Ignore in 2025
DIGITALCONFEX
 
MuleSoft MCP Support (Model Context Protocol) and Use Case Demo
shyamraj55
 
Seamless Tech Experiences Showcasing Cross-Platform App Design.pptx
presentifyai
 
New ThousandEyes Product Innovations: Cisco Live June 2025
ThousandEyes
 
[Newgen] NewgenONE Marvin Brochure 1.pdf
darshakparmar
 
“Computer Vision at Sea: Automated Fish Tracking for Sustainable Fishing,” a ...
Edge AI and Vision Alliance
 
SIZING YOUR AIR CONDITIONER---A PRACTICAL GUIDE.pdf
Muhammad Rizwan Akram
 
AI Penetration Testing Essentials: A Cybersecurity Guide for 2025
defencerabbit Team
 
Transcript: Book industry state of the nation 2025 - Tech Forum 2025
BookNet Canada
 
Staying Human in a Machine- Accelerated World
Catalin Jora
 
Bitcoin for Millennials podcast with Bram, Power Laws of Bitcoin
Stephen Perrenod
 
Future Tech Innovations 2025 – A TechLists Insight
TechLists
 
Go Concurrency Real-World Patterns, Pitfalls, and Playground Battles.pdf
Emily Achieng
 
Cryptography Quiz: test your knowledge of this important security concept.
Rajni Bhardwaj Grover
 
“NPU IP Hardware Shaped Through Software and Use-case Analysis,” a Presentati...
Edge AI and Vision Alliance
 
CIFDAQ Market Wrap for the week of 4th July 2025
CIFDAQ
 
The 2025 InfraRed Report - Redpoint Ventures
Razin Mustafiz
 
COMPARISON OF RASTER ANALYSIS TOOLS OF QGIS AND ARCGIS
Sharanya Sarkar
 
POV_ Why Enterprises Need to Find Value in ZERO.pdf
darshakparmar
 

The future of server side JavaScript

  • 1. The future of server side JavaScript @olegpodsechin #froscon 20.08.2011
  • 2. Why use JavaScript on the server? Language of the browser Competition amongst browser vendors means increased performance Code reuse between the server and client, no need for context switching Dynamic language No unnecessary constraints, allows one to mix procedural, object oriented and functional styles Allows for meta programing Data in JSON, no marshalling reduces amount of code
  • 3. Why use JavaScript on the server? Lingua franca of the web Widely accessible, even to beginning developers Widely available in terms of platforms Decent IDE support Closures work well with asynchronous, real time web Diverse, active, growing community – http://communityjs.org We are stuck with it for the foreseeable future
  • 5. ServerJS != Node Engines Environments Platforms Frameworks
  • 6. Engines 1996 SpiderMonkey (Mozilla) 1998 Rhino (Mozilla) 2008 Nitro/SquirrelFish (Apple) 2008 V8 (Google) 2011 Chakra (Microsoft) 2012 Nashorn (Oracle)
  • 7. Rhino JavaScript 1.7 Interpreted or compiled to Java bytecode, allows for continuations Includes new and old features like destructuring assignment (var {a, b} = x) and E4X Easy access to Java classes Recent patches improve performance, e.g. InvokeDynamic in Java7
  • 8. V8 EcmaScript 5 Compiles to native code – fast! Extended via native libraries Primarily targets the web browser
  • 9. CommonJS Modules - 1.0, 1.1 , Async/A Packages - 1.0, 1.1 Console System Unit Testing – 1.0 Binary - A, B , C, D, E, Lite, F IO - A , B, C Filesystem - A , B JSGI - 0.2, 0.3 HttpClient – A , B
  • 10. CommonJS modules // math.js exports.add = function(a, b) { return a + b; } // server.js var add = require('math').add; console.log(add(2, 2)); // client.js ???
  • 11. CommonJS packages // package.json { &quot;name&quot;: &quot;hello&quot;, &quot;version&quot;: &quot;0.1.0&quot;, &quot;description&quot;: &quot;Hello world package&quot;, &quot;keywords&quot;: [&quot;hello&quot;, &quot;world&quot;], &quot;author&quot;: &quot;John Smith <[email protected]>&quot;, &quot;main&quot;: &quot;./lib/hello.js&quot;, &quot;dependencies&quot;: {&quot;whatever&quot; : &quot;1&quot;}, &quot;engines&quot; : [&quot;v8&quot;, &quot;node&quot;, &quot;rhino&quot;], }
  • 12. Future of CommonJS http://groups.google.com/group/commonjs Node mostly ignored CommonJS AMD split out into separate mailing list UncommonJS https://github.com/kriskowal/uncommonjs
  • 13. Environments 1996 Netscape Livewire 1998 Helma (Rhino) 2007 AppJet (Rhino) 2008 CouchDB / Couch Apps (SpiderMonkey) 2008 RingoJS (Rhino) 2009 Narwhal (Rhino, V8, SpiderMonkey) 2009 Node (V8) 2010 Akshell (V8) 2011 Wakanda (Nitro) Over 30 in total http://wiki.commonjs.org/wiki/Implementations
  • 14. Sync vs. Async http.get(url1) + http.get(url2)
  • 15. Sync vs. Async function add(callback) { http.get(url1, function(response1) { var part1 = response1.data; http.get(url2, function(response2) { var part2 = response2.data; callback(part1 + part2); } } }
  • 16. Interoperability Pure JavaScript CommonJS modules can run in any environment Templating, parsing, formatting, encoding – what else? Anything that does I/O must expose either a synchronous or an asynchronous API Dictates the style of interface exposed by higher level packages, e.g. database driver, ORM
  • 17. API vs. Implementation Asynchronous, implement Node API Node RhiNodeII - https://github.com/lhofhansl/RhiNodeII SpiderNode - https://github.com/zpao/spidernode Node.NET - https://github.com/dnewcome/Node.net Synchronous, implement CommonJS API Ringo - https://github.com/ringo/ringojs Narwhal - https://github.com/280north/narwhal Common Node – https://github.com/olegp/common-node
  • 18. Common Node Implements a number of synchronous CommonJS specifications on top of Node Uses node-fibers Uses co routines or multiple stacks within the same process not a fork or a hack Google's Traceur to support latest language features Bridges the gap between Ringo and Node, sync and async Fibers, HTTP proxy code examples & benchmarks
  • 19.  
  • 20.  
  • 21.  
  • 22. Platforms Node Joyent, Heroku, Nodejitsu, Nodester, Nodesocket, CloudFoundry Ringo Erbix, AppEngine & any other Java platform Akshell
  • 23. Frameworks ServerJS is missing a Rails like framework Asynchronous DIY using Connect, Express etc. with Node Less of a problem, since Node is often used as glue Synchronous DIY using JSGI, Stick etc. with RingoJS Lack of a solid framework more of an issue
  • 24. Trends Wider adoption Front end developers First time developers - http://www.codecademy.com Enterprises moving off legacy systems Java, PHP New operating systems Windows, mobile devices (but not WebOS)
  • 25. Trends Web IDEs, XaaS Cloud9 – http://www.cloud9ide.com Akshell – http://www.akshell.com Compile to JavaScript languages CoffeeScript, AltJS http://altjs.org & http://notjs.org Extensible systems, crowd sourced functionality Think WordPress plugins + platform Locker Project http://lockerproject.org
  • 26. Thank you! Questions? @olegpodsechin