SlideShare a Scribd company logo
1 of 100
Download to read offline
Chris Bailey – IBM Runtime Monitoring and Diagnostics 
1st October 2014 
Java vs JavaScript 
Head to Head 
Document number 
© 2014 IBM Corporation
© 2014 IBM Corporation 
Important Disclaimers 
THE INFORMATION CONTAINED IN THIS PRESENTATION IS PROVIDED FOR INFORMATIONAL PURPOSES ONLY. 
WHILST EFFORTS WERE MADE TO VERIFY THE COMPLETENESS AND ACCURACY OF THE INFORMATION 
CONTAINED IN THIS PRESENTATION, IT IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 
IMPLIED. 
ALL PERFORMANCE DATA INCLUDED IN THIS PRESENTATION HAVE BEEN GATHERED IN A CONTROLLED 
ENVIRONMENT. YOUR OWN TEST RESULTS MAY VARY BASED ON HARDWARE, SOFTWARE OR 
INFRASTRUCTURE DIFFERENCES. 
ALL DATA INCLUDED IN THIS PRESENTATION ARE MEANT TO BE USED ONLY AS A GUIDE. 
IN ADDITION, THE INFORMATION CONTAINED IN THIS PRESENTATION IS BASED ON IBM’S CURRENT PRODUCT 
PLANS AND STRATEGY, WHICH ARE SUBJECT TO CHANGE BY IBM, WITHOUT NOTICE. 
IBM AND ITS AFFILIATED COMPANIES SHALL NOT BE RESPONSIBLE FOR ANY DAMAGES ARISING OUT OF THE 
USE OF, OR OTHERWISE RELATED TO, THIS PRESENTATION OR ANY OTHER DOCUMENTATION. 
NOTHING CONTAINED IN THIS PRESENTATION IS INTENDED TO, OR SHALL HAVE THE EFFECT OF: 
- CREATING ANY WARRANT OR REPRESENTATION FROM IBM, ITS AFFILIATED COMPANIES OR ITS OR THEIR 
SUPPLIERS AND/OR LICENSORS 
2
A Quick Survey 
© 2014 3 IBM Corporation
What languages do you program in? 
Java JavaScript Both 
60 
50 
40 
30 
20 
10 
0 
Percentage of Audience 
© 2014 4 IBM Corporation
What runtimes do you use? 
Server Java Applets JS in Browser Node.js Rhino Nashorn Avatar.js 
100 
90 
80 
70 
60 
50 
40 
30 
20 
10 
0 
Percentage of Audience 
© 2014 5 IBM Corporation
Introduction to the speaker 
 Chris Bailey 
IBM Runtime Monitoring and Diagnostics Architect 
- 14 years working with Java and JVM technologies 
- 6 months working with Node.js and V8 
 Recent work focus: 
- Java monitoring, diagnostics and troubleshooting 
- Java integration into the cloud 
- JavaScript monitoring, diagnostics and troubleshooting 
 My contact information: 
- baileyc@uk.ibm.com 
- http://www.linkedin.com/in/chrisbaileyibm 
- http://www.slideshare.net/cnbailey/ 
- @Chris__Bailey 
© 2014 6 IBM Corporation
Goals of this talk 
● Langage Adoption 
● Deployment Modes 
● Introduction to Node.js 
● Asynchronous IO 
● WebApplication Performance 
● Under the Hood of Node.js 
● JavaScript on the JVM 
© 2014 7 IBM Corporation
Language Adoption 
© 2014 8 IBM Corporation
GitHub Adoption: Java 
© 2014 9 IBM Corporation
GitHub Adoption: JavaScript 
GitHut Adoption 
© 2014 10 IBM Corporation
Modulecounts.com 
© 2014 11 IBM Corporation
StackOverFlow Survey 
© 2014 12 IBM Corporation
Tiobe Programming Community Index 
● Ratings based on the number of skilled engineers, courses and third party vendors. 
© 2014 13 IBM Corporation
Indeed.com Job Trends 
© 2014 14 IBM Corporation
Indeed.com Job Trends 
© 2014 15 IBM Corporation
Language Adoption 
 JavaScript has a large developer base 
- #1 on GitHub with 48.8% more active repositories than Java 
- #1 on modulecounts.com with 10% more NPM modules than Maven 
- #1 used language by StackOverflow survey responders 
- #9 language on the Tiobe index 
 Java remains a hugely relevant language, particularly on the server 
- #2 on GitHub with xx% more than the next language 
- #3 on modulecounts.com with 73.8% more modules than the next language 
- #2 language on the Tiobe index 
- #1 on indeed.com for developer jobs 
© 2014 16 IBM Corporation
Deployment Modes 
© 2014 17 IBM Corporation
Usage in the Browser 
● JavaScript is ubiquitous in the browser 
- Supported in every browser 
- Full integration with HTML and CSS 
● Not affected by negative publicity.... 
Unless it is absolutely necessary to run Java in web browsers, disable it as described 
below, even after updating to 7u11. This will help mitigate other Java vulnerabilities that 
may be discovered in the future. 
This and previous Java vulnerabilities have been widely targeted by attackers, and 
new Java vulnerabilities are likely to be discovered. To defend against this and future 
Java vulnerabilities, consider disabling Java in web browsers… 
© 2014 18 IBM Corporation
Usage on the Server 
● Java has a long history on the server 
- JPE launched in 1998 
● Java has rich platform support: 
- Linux x86, Linux POWER, zLinux 
- Windows, Mac OS, Solaris, AIX, z/OS 
 JavaScript is a nascent language on the server 
- Limited platform support – although its growing 
- No API support to interact with the OS 
 Part of the browser security model 
- Frameworks like Node.js have changed that. 
© 2014 19 IBM Corporation
Introduction to Node.js 
 Single Threaded Event based JavaScript framework 
– Uses non-blocking asynchronous I/O 
 Wraps the Chrome V8 JavaScript engine with I/O interfaces 
– Libuv provides interaction with OS/system 
● Designed to build scalable network applications 
– Suited for real time delivery of data to distributed client 
 Available on a growing set of platforms 
- Windows, Linux x86, Linux ARM, Mac OS, Solaris 
- Linux POWER, zLinux, AIX 
Node Standard Library 
Node Bindings 
V8 libuv 
JavaScript 
C 
© 2014 20 IBM Corporation
Async I/O Model 
© 2014 21 IBM Corporation
Typical approach to IO 
 One thread (or process) per connection 
- Each thread waits on a response 
- Scalability determined by the number of threads 
 Each thread: 
- consumes memory 
- is relatively idle 
 Number of concurrent customers determined by number 
of depot workers 
 Additional customers wait in a queue with no response 
© 2014 22 IBM Corporation
Asynchronous non-blocking IO 
 One thread multiplexes for multiple requests 
- No waiting for a response 
- Handles return from I/O when notified 
 Scalability determined by: 
- CPU usage 
- “Back end” responsiveness 
 Number of concurrent customers determined by 
how fast the food Server can work 
 Or until the kitchen gets slammed 
© 2014 23 IBM Corporation
Drawbacks of Asynchronous IO 
 Tasks must execute quickly to avoid blocking the event queue 
- Analogous to work done under a lock 
- Stick to the right jobs, eg, I/O 
- Delegate CPU bound tasks to back end processes 
 Easy to run out of memory 
- No direct bound on amount of parallel work 
- Holding state for each piece or work means unbounded memory usage 
© 2014 24 IBM Corporation
JavaScript and Asynchronous IO 
 JavaScript is already event based in the browser 
- eg. onClick and onMouseOver events 
 First class functions and closures fit well with events 
- Easy to create and pass function callbacks 
- Easy to execute callbacks in the context of the event 
 Node.js execution is based on an event loop 
- Asynchronous I/O built in from the ground up 
 Node.js execution uses a single thread 
- No need to worry about locking or shared data 
- Most machines are now multi-CPU, so cluster capabilities are provided 
© 2014 25 IBM Corporation
HTTP Server Example 
var cluster = require('cluster'); 
var cpus = require('os').cpus().length; 
var http = require('http'); 
if (cluster.isMaster) { 
for (var i = 0; i < cpus; i++) { 
cluster.fork(); 
} 
cluster.on('death', function(worker) { 
console.log("Worker" + worker.pid + "died"); 
}); 
} else { 
http.createServer(function(request, response) { 
response.writeHead(200, {"Content-Type": "text/plain"}); 
response.write("Hello World!n"); 
response.end(); 
}).listen(8080); 
} 
© 2014 26 IBM Corporation
HTTP Server Example with Clustering 
var cluster = require('cluster'); 
var cpus = require('os').cpus().length; 
var http = require('http'); 
if (cluster.isMaster) { 
for (var i = 0; i < cpus; i++) { 
cluster.fork(); 
} 
cluster.on('death', function(worker) { 
console.log("Worker" + worker.pid + "died"); 
}); 
} else { 
http.createServer(function(request, response) { 
response.writeHead(200, {"Content-Type": "text/plain"}); 
response.write("Hello World!n"); 
response.end(); 
}).listen(8080); 
} 
© 2014 27 IBM Corporation
Event Loop Example 
 Hypothetical implementation of readFile(): 
function readFile(filename, cb) { 
nb_open(filename, function(err, fd) { 
if (err) cb(err, null); 
nb_read(fd, function(err, data) { 
cb(err, data); 
nb_close(fd); 
}); 
}); 
} 
© 2014 28 IBM Corporation
© 2014 29 IBM Corporation
© 2014 30 IBM Corporation
© 2014 31 IBM Corporation
© 2014 32 IBM Corporation
© 2014 33 IBM Corporation
© 2014 34 IBM Corporation
© 2014 35 IBM Corporation
© 2014 36 IBM Corporation
© 2014 37 IBM Corporation
© 2014 38 IBM Corporation
© 2014 39 IBM Corporation
© 2014 40 IBM Corporation
© 2014 41 IBM Corporation
© 2014 42 IBM Corporation
© 2014 43 IBM Corporation
© 2014 44 IBM Corporation
© 2014 45 IBM Corporation
© 2014 46 IBM Corporation
© 2014 47 IBM Corporation
© 2014 48 IBM Corporation
© 2014 49 IBM Corporation
© 2014 50 IBM Corporation
© 2014 51 IBM Corporation
© 2014 52 IBM Corporation
© 2014 53 IBM Corporation
© 2014 54 IBM Corporation
© 2014 55 IBM Corporation
© 2014 56 IBM Corporation
© 2014 57 IBM Corporation
© 2014 58 IBM Corporation
© 2014 59 IBM Corporation
© 2014 60 IBM Corporation
© 2014 61 IBM Corporation
© 2014 62 IBM Corporation
© 2014 63 IBM Corporation
JavaScript and Asynchronous I/O 
 Very little time spent with events on the Event Loop 
 Provides good scalability, so should provide great performance for IO bound apps 
 Like WebApplications... 
© 2014 64 IBM Corporation
WebApp Performance 
© 2014 65 IBM Corporation
JSON Serialization 
 JSON serialization of a newly 
instantiated object 
 Maps 
- Key of message 
- Value of Hello, World! 
 Example response: 
Results from TechEmpower.com Round 9 tests (2014-05-01) 
© 2014 66 IBM Corporation
JSON Serialization 
 JSON serialization of a newly 
instantiated object 
 Maps 
- Key of message 
- Value of Hello, World! 
 Example response: 
Results from TechEmpower.com Round 9 tests (2014-05-01) 
© 2014 67 IBM Corporation
Single Query 
 Fetches single row from simple 
database table 
 Row serialized as JSON 
 Example response: 
Results from TechEmpower.com Round 9 tests (2014-05-01) 
© 2014 68 IBM Corporation
Single Query 
 Fetches single row from simple 
database table 
 Row serialized as JSON 
 Example response: 
Results from TechEmpower.com Round 9 tests (2014-05-01) 
© 2014 69 IBM Corporation
Multiple Query 
 Fetches multiple rows from a 
simple database table 
 Rows serialized as JSON 
 Example response: 
Results from TechEmpower.com Round 9 tests (2014-05-01) 
© 2014 70 IBM Corporation
Multiple Query 
 Fetches multiple rows from a 
simple database table 
 Rows serialized as JSON 
 Example response: 
Results from TechEmpower.com Round 9 tests (2014-05-01) 
© 2014 71 IBM Corporation
Data Updates 
 Fetches multiple rows from a 
simple database table 
 Converts rows to objects and 
modifies one attribute of each 
object 
 Updates each associated row and 
serializes as JSON 
 Example Response: 
Results taken from TechEmpower.com 
© 2014 72 IBM Corporation
Data Updates 
 Fetches multiple rows from a 
simple database table 
 Converts rows to objects and 
modifies one attribute of each 
object 
 Updates each associated row and 
serializes as JSON 
 Example Response: 
Results taken from TechEmpower.com 
© 2014 73 IBM Corporation
Under the Hood 
© 2014 74 IBM Corporation
Polymorphism and Object Representation 
Integer Class 
Integer Object Name: Integer 
Class pointer 
Class pointer 
Class pointer 
Class pointer 
Flags 
Flags 
Flags 
Flags 
Locks 
Locks 
Locks 
Locks 
int 
int 
int 
int 
Super Class 
Method Table 
Field Table 
Constant Pool 
Object Offsets 
... 
 Java objects are fixed in size and shape 
- Determined by the object type 
- Type determined by class pointer 
 Class pointer gives access to Method Table 
- All methods executable from the object 
 Class pointer also gives access to Object Offsets 
- Fields in the object that are objects 
- Used for graph traversal during GC 
© 2014 75 IBM Corporation
Polymorphism and Object Representation 
Map 
Field: offset 
Field: offset 
Field: offset 
Fixed Array 
Map 
Length 
Fixed Array 
Map 
1: 
2: 
1: 
Length 
2: 
JSObject 
 JavaScript objects polymorphic and can change in 
size and shape 
 “Simple” objects: 
- Created with 32 fields 
- Contains a Map describing key : value 
parings 
- Contains “extra properties” for overflow 
- Contains “elements” for array values 
- All fields are 64bits 
 Multiple maps can exist for “equal” objects 
- Dependent on order in which fields are added 
to the object 
- ie. X then Y, or Y then X 
Map 
Extra Props 
Elements 
1: 
2: 
3: 
... 
... 
32: 
© 2014 76 IBM Corporation
Polymorphism and JIT Compilation 
 Functions are stored in JavaScript objects as fields 
- No fixed set of methods for an object 
● Objects are not typed, so data much be checked to determine how to handle it 
eg. the '+' operator: 
- number + number → addition 
- string involved? → concatenation 
- objects involved? → convert to primitives then addition or concatenation 
eg. property load: 
- Load prototype object 
- Load getter method 
- Load callback function 
● Therefore not possible to determine what instructions to use just from the source code 
© 2014 77 IBM Corporation
Approach to JIT Compilation 
 V8 JavaScript engine has two compilers 
 Full Compiler 
- Compiles JavaScript to native code on first execution 
- No bytecode stage, and no real optimization applied 
- Implements a Polymorphic Inline Cache (PIC) 
 Crankshaft 
- Execution counter based compilation strategy 
 Also supports on-stack replacement for code with hot loops 
- Compilation is done in the execution path 
- Optimized for types present in the PIC 
© 2014 78 IBM Corporation
Polymorphism and Garbage Collection 
 Implements Generational Garbage Collection, similar to the JVM 
– New space, Old space, Large Object space, Remembered sets 
– Additional JavaScript specific areas: map space, cell space, property cell space 
– Implements concurrent mark/sweep capabilities 
 Root scan based on Global objects and local variables on the stack 
– Reference tree built by following object references to further objects 
– However... how do we know which variables are Objects rather than data? 
• Solution is tagged pointers – use of 01 in the low order bits to denote a 
pointer 
© 2014 79 IBM Corporation
JavaScript on the JVM? 
© 2014 80 IBM Corporation
JavaScript on the JVM 
 Rhino was bundled in JDK6 
- Based on the Mozilla Rhino engine 
- Allowed JavaScript to be embedded in Java, and for JavaScript to call out to Java 
- Provided jrunscript command line utility 
 Nashorn replaces JavaScript in JDK8 
- Supports full ECMAScript 5.1 specification 
- Exploits invokedynamic to provide 2x to 10x better performance than Rhino 
- Provides jjs command line utility 
© 2014 81 IBM Corporation
JavaScript on the JVM 
 SRcrhiinpot Ewnagsi nbeuMnadnleadge inr JsDcKri6ptEngineManager = new ScriptEngineManager(); 
ScriptEngine nashorn = scriptEngineManager.getEngineByName("nashorn"); 
int sendVal = 7; 
nashorn.put("sendVal", sendVal); 
nashorn.eval(" "+ 
"var Thread = Java.type("java.lang.Thread"); "+ 
"var MyThread = Java.extend(Thread, { "+ 
" run: function() { "+ 
" print("Run in separate thread"); "+ 
" } "+ 
"}); "+ 
"var th = new MyThread(); "+ 
"th.start(); "+ 
"th.join(); "+ 
"var resultVal = sendVal + 3;"); 
System.out.println(nashorn.get("resultVal"); 
© 2014 82 IBM Corporation
JavaScript on the JVM 
ScriptEngineManager scriptEngineManager = new ScriptEngineManager(); 
ScriptEngine nashorn = scriptEngineManager.getEngineByName("nashorn"); 
int sendVal = 7; 
nashorn.put("sendVal", sendVal); 
nashorn.eval(" "+ 
"var Thread = Java.type("java.lang.Thread"); "+ 
"var MyThread = Java.extend(Thread, { "+ 
" run: function() { "+ 
" print("Run in separate thread"); "+ 
" } "+ 
"}); "+ 
"var th = new MyThread(); "+ 
"th.start(); "+ 
"th.join(); "+ 
"var resultVal = sendVal + 3;"); 
System.out.println(nashorn.get("resultVal"); 
© 2014 83 IBM Corporation
JavaScript on the JVM 
ScriptEngineManager scriptEngineManager = new ScriptEngineManager(); 
ScriptEngine nashorn = scriptEngineManager.getEngineByName("nashorn"); 
int sendVal = 7; 
nashorn.put("sendVal", sendVal); 
nashorn.eval(" "+ 
"var Thread = Java.type("java.lang.Thread"); "+ 
"var MyThread = Java.extend(Thread, { "+ 
" run: function() { "+ 
" print("Run in separate thread"); "+ 
" } "+ 
"}); "+ 
"var th = new MyThread(); "+ 
"th.start(); "+ 
"th.join(); "+ 
"var resultVal = sendVal + 3;"); 
System.out.println(nashorn.get("resultVal"); 
© 2014 84 IBM Corporation
JavaScript on the JVM 
ScriptEngineManager scriptEngineManager = new ScriptEngineManager(); 
ScriptEngine nashorn = scriptEngineManager.getEngineByName("nashorn"); 
int sendVal = 7; 
nashorn.put("sendVal", sendVal); 
nashorn.eval(" "+ 
"var Thread = Java.type("java.lang.Thread"); "+ 
"var MyThread = Java.extend(Thread, { "+ 
" run: function() { "+ 
" print("Run in separate thread"); "+ 
" } "+ 
"}); "+ 
"var th = new MyThread(); "+ 
"th.start(); "+ 
"th.join(); "+ 
"var resultVal = sendVal + 3;"); 
System.out.println(nashorn.get("resultVal"); 
© 2014 85 IBM Corporation
JavaScript on the JVM 
ScriptEngineManager scriptEngineManager = new ScriptEngineManager(); 
ScriptEngine nashorn = scriptEngineManager.getEngineByName("nashorn"); 
int sendVal = 7; 
nashorn.put("sendVal", sendVal); 
nashorn.eval(" "+ 
"var Thread = Java.type("java.lang.Thread"); "+ 
"var MyThread = Java.extend(Thread, { "+ 
" run: function() { "+ 
" print("Run in separate thread"); "+ 
" } "+ 
"}); "+ 
"var th = new MyThread(); "+ 
"th.start(); "+ 
"th.join(); "+ 
"var resultVal = sendVal + 3;"); 
System.out.println(nashorn.get("resultVal"); 
© 2014 86 IBM Corporation
JavaScript on the JVM 
ScriptEngineManager scriptEngineManager = new ScriptEngineManager(); 
ScriptEngine nashorn = scriptEngineManager.getEngineByName("nashorn"); 
int sendVal = 7; 
nashorn.put("sendVal", sendVal); 
nashorn.eval(" "+ 
"var Thread = Java.type("java.lang.Thread"); "+ 
"var MyThread = Java.extend(Thread, { "+ 
" run: function() { "+ 
" print("Run in separate thread"); "+ 
" } "+ 
"}); "+ 
"var th = new MyThread(); "+ 
"th.start(); "+ 
"th.join(); "+ 
"var resultVal = sendVal + 3;"); 
System.out.println(nashorn.get("resultVal"); 
© 2014 87 IBM Corporation
JavaScript on the JVM 
ScriptEngineManager scriptEngineManager = new ScriptEngineManager(); 
ScriptEngine nashorn = scriptEngineManager.getEngineByName("nashorn"); 
int sendVal = 7; 
nashorn.put("sendVal", sendVal); 
nashorn.eval(" "+ 
"var Thread = Java.type("java.lang.Thread"); "+ 
"var MyThread = Java.extend(Thread, { "+ 
" run: function() { "+ 
" print("Run in separate thread"); "+ 
" } "+ 
"}); "+ 
"var th = new MyThread(); "+ 
"th.start(); "+ 
"th.join(); "+ 
"var resultVal = sendVal + 3;"); 
System.out.println(nashorn.get("resultVal"); 
© 2014 88 IBM Corporation
Introduction to Avatar.js 
 Support for Node.js on Nashorn 
 Binary builds available from Maven 
– Avatar-js.jar 
– Avatar-js library (64bit) 
 Number of common NPM modules 
are supported 
 NPM required to dependencies 
 Issues for native NPMs 
– No native V8 APIs 
From https://avatar-js.java.net/ 
© 2014 89 IBM Corporation
Avatar.js vs Node.js 
 Running Octane r33 
– The “SpecJVM98” of the JavaScript world 
– Actually a JavaScript benchmark rather than a Node.js benchmark 
– So more comparing Nashorn to V8 
 Run on a 8 CPU Windows using: 
– Node.js v0.10.31 
– HotSpot 8u20 
 Settings are “out of the box” with no attempt to tune 
© 2014 90 IBM Corporation
Avatar.js running Octane Bencmark 
Avatar.js 
● Duration: 1m 56s 
● Peak memory: 2830MB 
© 2014 91 IBM Corporation
Node.js running Octane Bencmark 
Node.js 
● Duration: 24s 
● Peak memory: 268MB 
© 2014 92 IBM Corporation
Avatar.js vs Node.js Memory Usage 
Avatar.js 
● Duration: 1m 56s 
● Peak memory: 2830MB 
Node.js 
● Duration: 24s 
● Peak memory: 268MB 
Node.js is 4.8x faster 
Avatar.js is >10x bigger 
© 2014 93 IBM Corporation
Avatar.js vs Node.js: Garbage Collection 
 Avatar.js peak is: 
– 920MB / 1.85GB 
 Node.js peak is: 
– 200MB / 220MB 
 Additional 700+MB of Object Heap 
 Additional 1GB of non-Object Heap 
© 2014 94 IBM Corporation
Avatar.js vs Node.js: Stack Traces 
 Interpretation of JavaScript at the Java layer means stacks are large and anonymous 
© 2014 95 IBM Corporation
Summary 
 JavaScript has a large amount of interest and is growing 
– Fits well for web applications and code sharing between server and browser 
– Async IO and event loop model makes it easy to write scalable applications 
 Weak typing and dynamic linkage makes programming easier, but introduces challenges 
– Errors found during compilation for strongly typed languages are found at runtime 
– JIT compilation loves certainty, which is removed 
 Nashorn and Avatar.js introduces JavaScript to the JVM 
– Adds interoperability 
– … but suffers from the same challenges 
© 2014 96 IBM Corporation
IBM Developer Kits for Java 
ibm.biz/javasdk 
WebShere Liberty Profile 
wasdev.net 
IBM Bluemix 
ibm.com/bluemix 
IBM Developer Kits for Node.js 
ibm.biz/nodesdk 
© 2014 97 IBM Corporation
Questions? 
© 2014 98 IBM Corporation
www.ibm.com/developer 
Discover 
new technical resources. 
ibm.biz/javaone2014 
Visit Booth 5511 to learn about Cloud, DevOps and Mobile solutions 
© 2014 IBM Corporation 
Develop 
your coding skills. 
Connect 
with developers.
Copyright and Trademarks 
© IBM Corporation 2013. All Rights Reserved. 
IBM, the IBM logo, and ibm.com are trademarks or registered trademarks of International 
Business Machines Corp., and registered in many jurisdictions worldwide. 
Other product and service names might be trademarks of IBM or other companies. 
A current list of IBM trademarks is available on the Web – see the IBM “Copyright and 
trademark information” page at URL: www.ibm.com/legal/copytrade.shtml 
© 2014 100 IBM Corporation

More Related Content

What's hot

Node Summit 2016: Web App Architectures
Node Summit 2016:  Web App ArchitecturesNode Summit 2016:  Web App Architectures
Node Summit 2016: Web App ArchitecturesChris Bailey
 
InterConnect2016 Monitoring Nodejs
InterConnect2016 Monitoring NodejsInterConnect2016 Monitoring Nodejs
InterConnect2016 Monitoring NodejsChris Bailey
 
JavaOne2013: Build Your Own Runtime Monitoring for the IBM JDK with the Healt...
JavaOne2013: Build Your Own Runtime Monitoring for the IBM JDK with the Healt...JavaOne2013: Build Your Own Runtime Monitoring for the IBM JDK with the Healt...
JavaOne2013: Build Your Own Runtime Monitoring for the IBM JDK with the Healt...Chris Bailey
 
FrenchKit: End to End Application Development with Swift
FrenchKit: End to End Application Development with SwiftFrenchKit: End to End Application Development with Swift
FrenchKit: End to End Application Development with SwiftChris Bailey
 
Puppet devops wdec
Puppet devops wdecPuppet devops wdec
Puppet devops wdecWojciech Dec
 
How to secure your web applications with NGINX
How to secure your web applications with NGINXHow to secure your web applications with NGINX
How to secure your web applications with NGINXWallarm
 
VMware 2V0-21.20 Practice Test
VMware 2V0-21.20 Practice Test VMware 2V0-21.20 Practice Test
VMware 2V0-21.20 Practice Test Armstrongsmith
 
414: Build an agile CI/CD Pipeline for application integration
414: Build an agile CI/CD Pipeline for application integration414: Build an agile CI/CD Pipeline for application integration
414: Build an agile CI/CD Pipeline for application integrationTrevor Dolby
 
Adrian Stoian - Manage Private and Public Cloud Services with System Center 2...
Adrian Stoian - Manage Private and Public Cloud Services with System Center 2...Adrian Stoian - Manage Private and Public Cloud Services with System Center 2...
Adrian Stoian - Manage Private and Public Cloud Services with System Center 2...ITSpark Community
 
De 03 Introduction To V Cloud Api V1
De 03 Introduction To V Cloud Api V1De 03 Introduction To V Cloud Api V1
De 03 Introduction To V Cloud Api V1ikewu83
 
Introducing Spring Cloud Gateway and API Hub for VMware Tanzu
Introducing Spring Cloud Gateway and API Hub for VMware TanzuIntroducing Spring Cloud Gateway and API Hub for VMware Tanzu
Introducing Spring Cloud Gateway and API Hub for VMware TanzuVMware Tanzu
 
WebSphere Application Server - Meeting Your Cloud and On-Premise Demands
WebSphere Application Server - Meeting Your Cloud and On-Premise DemandsWebSphere Application Server - Meeting Your Cloud and On-Premise Demands
WebSphere Application Server - Meeting Your Cloud and On-Premise DemandsIan Robinson
 
Power vc for powervm deep dive tips &amp; tricks
Power vc for powervm deep dive tips &amp; tricksPower vc for powervm deep dive tips &amp; tricks
Power vc for powervm deep dive tips &amp; trickssolarisyougood
 
V mware white paper virtualizing business-critical applications with confidence
V mware white paper  virtualizing business-critical applications with confidenceV mware white paper  virtualizing business-critical applications with confidence
V mware white paper virtualizing business-critical applications with confidenceReadWrite
 
All you know about ASP.NET deployment is wrong!
All you know about ASP.NET deployment is wrong!All you know about ASP.NET deployment is wrong!
All you know about ASP.NET deployment is wrong!Roger Pence
 
Vulnerability Advisor Deep Dive (Dec 2016)
Vulnerability Advisor Deep Dive (Dec 2016)Vulnerability Advisor Deep Dive (Dec 2016)
Vulnerability Advisor Deep Dive (Dec 2016)Canturk Isci
 
Java EE 7: Boosting Productivity and Embracing HTML5
Java EE 7: Boosting Productivity and Embracing HTML5Java EE 7: Boosting Productivity and Embracing HTML5
Java EE 7: Boosting Productivity and Embracing HTML5Arun Gupta
 
Migrating from Pivotal tc Server on-prem to IBM Liberty in the cloud
Migrating from Pivotal tc Server on-prem to IBM Liberty in the cloudMigrating from Pivotal tc Server on-prem to IBM Liberty in the cloud
Migrating from Pivotal tc Server on-prem to IBM Liberty in the cloudJohn Donaldson
 
Developers Are Users, Too
Developers Are Users, TooDevelopers Are Users, Too
Developers Are Users, TooVMware Tanzu
 

What's hot (20)

Node Summit 2016: Web App Architectures
Node Summit 2016:  Web App ArchitecturesNode Summit 2016:  Web App Architectures
Node Summit 2016: Web App Architectures
 
InterConnect2016 Monitoring Nodejs
InterConnect2016 Monitoring NodejsInterConnect2016 Monitoring Nodejs
InterConnect2016 Monitoring Nodejs
 
JavaOne2013: Build Your Own Runtime Monitoring for the IBM JDK with the Healt...
JavaOne2013: Build Your Own Runtime Monitoring for the IBM JDK with the Healt...JavaOne2013: Build Your Own Runtime Monitoring for the IBM JDK with the Healt...
JavaOne2013: Build Your Own Runtime Monitoring for the IBM JDK with the Healt...
 
Cloud Economics
Cloud EconomicsCloud Economics
Cloud Economics
 
FrenchKit: End to End Application Development with Swift
FrenchKit: End to End Application Development with SwiftFrenchKit: End to End Application Development with Swift
FrenchKit: End to End Application Development with Swift
 
Puppet devops wdec
Puppet devops wdecPuppet devops wdec
Puppet devops wdec
 
How to secure your web applications with NGINX
How to secure your web applications with NGINXHow to secure your web applications with NGINX
How to secure your web applications with NGINX
 
VMware 2V0-21.20 Practice Test
VMware 2V0-21.20 Practice Test VMware 2V0-21.20 Practice Test
VMware 2V0-21.20 Practice Test
 
414: Build an agile CI/CD Pipeline for application integration
414: Build an agile CI/CD Pipeline for application integration414: Build an agile CI/CD Pipeline for application integration
414: Build an agile CI/CD Pipeline for application integration
 
Adrian Stoian - Manage Private and Public Cloud Services with System Center 2...
Adrian Stoian - Manage Private and Public Cloud Services with System Center 2...Adrian Stoian - Manage Private and Public Cloud Services with System Center 2...
Adrian Stoian - Manage Private and Public Cloud Services with System Center 2...
 
De 03 Introduction To V Cloud Api V1
De 03 Introduction To V Cloud Api V1De 03 Introduction To V Cloud Api V1
De 03 Introduction To V Cloud Api V1
 
Introducing Spring Cloud Gateway and API Hub for VMware Tanzu
Introducing Spring Cloud Gateway and API Hub for VMware TanzuIntroducing Spring Cloud Gateway and API Hub for VMware Tanzu
Introducing Spring Cloud Gateway and API Hub for VMware Tanzu
 
WebSphere Application Server - Meeting Your Cloud and On-Premise Demands
WebSphere Application Server - Meeting Your Cloud and On-Premise DemandsWebSphere Application Server - Meeting Your Cloud and On-Premise Demands
WebSphere Application Server - Meeting Your Cloud and On-Premise Demands
 
Power vc for powervm deep dive tips &amp; tricks
Power vc for powervm deep dive tips &amp; tricksPower vc for powervm deep dive tips &amp; tricks
Power vc for powervm deep dive tips &amp; tricks
 
V mware white paper virtualizing business-critical applications with confidence
V mware white paper  virtualizing business-critical applications with confidenceV mware white paper  virtualizing business-critical applications with confidence
V mware white paper virtualizing business-critical applications with confidence
 
All you know about ASP.NET deployment is wrong!
All you know about ASP.NET deployment is wrong!All you know about ASP.NET deployment is wrong!
All you know about ASP.NET deployment is wrong!
 
Vulnerability Advisor Deep Dive (Dec 2016)
Vulnerability Advisor Deep Dive (Dec 2016)Vulnerability Advisor Deep Dive (Dec 2016)
Vulnerability Advisor Deep Dive (Dec 2016)
 
Java EE 7: Boosting Productivity and Embracing HTML5
Java EE 7: Boosting Productivity and Embracing HTML5Java EE 7: Boosting Productivity and Embracing HTML5
Java EE 7: Boosting Productivity and Embracing HTML5
 
Migrating from Pivotal tc Server on-prem to IBM Liberty in the cloud
Migrating from Pivotal tc Server on-prem to IBM Liberty in the cloudMigrating from Pivotal tc Server on-prem to IBM Liberty in the cloud
Migrating from Pivotal tc Server on-prem to IBM Liberty in the cloud
 
Developers Are Users, Too
Developers Are Users, TooDevelopers Are Users, Too
Developers Are Users, Too
 

Viewers also liked

Javascript Libraries & Frameworks | Connor Goddard
Javascript Libraries & Frameworks | Connor GoddardJavascript Libraries & Frameworks | Connor Goddard
Javascript Libraries & Frameworks | Connor GoddardConnor Goddard
 
JavaScript Libraries: The Big Picture
JavaScript Libraries: The Big PictureJavaScript Libraries: The Big Picture
JavaScript Libraries: The Big PictureSimon Willison
 
(DEV306) Building Cross-Platform Applications Using the AWS SDK for JavaScrip...
(DEV306) Building Cross-Platform Applications Using the AWS SDK for JavaScrip...(DEV306) Building Cross-Platform Applications Using the AWS SDK for JavaScrip...
(DEV306) Building Cross-Platform Applications Using the AWS SDK for JavaScrip...Amazon Web Services
 
Java vs javascript (XPages)
Java vs javascript (XPages)Java vs javascript (XPages)
Java vs javascript (XPages)Andrew Barickman
 
Java vs. Java Script for enterprise web applications - Chris Bailey
Java vs. Java Script for enterprise web applications - Chris BaileyJava vs. Java Script for enterprise web applications - Chris Bailey
Java vs. Java Script for enterprise web applications - Chris BaileyJAXLondon_Conference
 
JavaScript for Enterprise Applications
JavaScript for Enterprise ApplicationsJavaScript for Enterprise Applications
JavaScript for Enterprise ApplicationsPiyush Katariya
 
Choosing Javascript Libraries to Adopt for Development
Choosing Javascript Libraries to Adopt for DevelopmentChoosing Javascript Libraries to Adopt for Development
Choosing Javascript Libraries to Adopt for DevelopmentEdward Apostol
 
Real-Time Machine Learning with Node.js - Philipp Burckhardt, Carnegie Mellon...
Real-Time Machine Learning with Node.js - Philipp Burckhardt, Carnegie Mellon...Real-Time Machine Learning with Node.js - Philipp Burckhardt, Carnegie Mellon...
Real-Time Machine Learning with Node.js - Philipp Burckhardt, Carnegie Mellon...NodejsFoundation
 
10 Building Blocks for Enterprise JavaScript
10 Building Blocks for Enterprise JavaScript10 Building Blocks for Enterprise JavaScript
10 Building Blocks for Enterprise JavaScriptGeertjan Wielenga
 
Webinar AWS 201 Delivering apps without servers
Webinar AWS 201 Delivering apps without serversWebinar AWS 201 Delivering apps without servers
Webinar AWS 201 Delivering apps without serversAmazon Web Services
 
Tools For jQuery Application Architecture (Extended Slides)
Tools For jQuery Application Architecture (Extended Slides)Tools For jQuery Application Architecture (Extended Slides)
Tools For jQuery Application Architecture (Extended Slides)Addy Osmani
 
Building Enterprise Grade Front-End Applications with JavaScript Frameworks
Building Enterprise Grade Front-End Applications with JavaScript FrameworksBuilding Enterprise Grade Front-End Applications with JavaScript Frameworks
Building Enterprise Grade Front-End Applications with JavaScript FrameworksFITC
 
Microservice Architecture on AWS using AWS Lambda and Docker Containers
Microservice Architecture on AWS using AWS Lambda and Docker ContainersMicroservice Architecture on AWS using AWS Lambda and Docker Containers
Microservice Architecture on AWS using AWS Lambda and Docker ContainersDanilo Poccia
 
Enough with the JavaScript already!
Enough with the JavaScript already!Enough with the JavaScript already!
Enough with the JavaScript already!Nicholas Zakas
 
Scalable JavaScript Application Architecture
Scalable JavaScript Application ArchitectureScalable JavaScript Application Architecture
Scalable JavaScript Application ArchitectureNicholas Zakas
 
AWS Architecture Case Study: Real-Time Bidding
AWS Architecture Case Study: Real-Time BiddingAWS Architecture Case Study: Real-Time Bidding
AWS Architecture Case Study: Real-Time BiddingAmazon Web Services
 

Viewers also liked (17)

Javascript Libraries & Frameworks | Connor Goddard
Javascript Libraries & Frameworks | Connor GoddardJavascript Libraries & Frameworks | Connor Goddard
Javascript Libraries & Frameworks | Connor Goddard
 
JavaScript Libraries: The Big Picture
JavaScript Libraries: The Big PictureJavaScript Libraries: The Big Picture
JavaScript Libraries: The Big Picture
 
(DEV306) Building Cross-Platform Applications Using the AWS SDK for JavaScrip...
(DEV306) Building Cross-Platform Applications Using the AWS SDK for JavaScrip...(DEV306) Building Cross-Platform Applications Using the AWS SDK for JavaScrip...
(DEV306) Building Cross-Platform Applications Using the AWS SDK for JavaScrip...
 
Java vs javascript (XPages)
Java vs javascript (XPages)Java vs javascript (XPages)
Java vs javascript (XPages)
 
Javascript libraries
Javascript librariesJavascript libraries
Javascript libraries
 
Java vs. Java Script for enterprise web applications - Chris Bailey
Java vs. Java Script for enterprise web applications - Chris BaileyJava vs. Java Script for enterprise web applications - Chris Bailey
Java vs. Java Script for enterprise web applications - Chris Bailey
 
JavaScript for Enterprise Applications
JavaScript for Enterprise ApplicationsJavaScript for Enterprise Applications
JavaScript for Enterprise Applications
 
Choosing Javascript Libraries to Adopt for Development
Choosing Javascript Libraries to Adopt for DevelopmentChoosing Javascript Libraries to Adopt for Development
Choosing Javascript Libraries to Adopt for Development
 
Real-Time Machine Learning with Node.js - Philipp Burckhardt, Carnegie Mellon...
Real-Time Machine Learning with Node.js - Philipp Burckhardt, Carnegie Mellon...Real-Time Machine Learning with Node.js - Philipp Burckhardt, Carnegie Mellon...
Real-Time Machine Learning with Node.js - Philipp Burckhardt, Carnegie Mellon...
 
10 Building Blocks for Enterprise JavaScript
10 Building Blocks for Enterprise JavaScript10 Building Blocks for Enterprise JavaScript
10 Building Blocks for Enterprise JavaScript
 
Webinar AWS 201 Delivering apps without servers
Webinar AWS 201 Delivering apps without serversWebinar AWS 201 Delivering apps without servers
Webinar AWS 201 Delivering apps without servers
 
Tools For jQuery Application Architecture (Extended Slides)
Tools For jQuery Application Architecture (Extended Slides)Tools For jQuery Application Architecture (Extended Slides)
Tools For jQuery Application Architecture (Extended Slides)
 
Building Enterprise Grade Front-End Applications with JavaScript Frameworks
Building Enterprise Grade Front-End Applications with JavaScript FrameworksBuilding Enterprise Grade Front-End Applications with JavaScript Frameworks
Building Enterprise Grade Front-End Applications with JavaScript Frameworks
 
Microservice Architecture on AWS using AWS Lambda and Docker Containers
Microservice Architecture on AWS using AWS Lambda and Docker ContainersMicroservice Architecture on AWS using AWS Lambda and Docker Containers
Microservice Architecture on AWS using AWS Lambda and Docker Containers
 
Enough with the JavaScript already!
Enough with the JavaScript already!Enough with the JavaScript already!
Enough with the JavaScript already!
 
Scalable JavaScript Application Architecture
Scalable JavaScript Application ArchitectureScalable JavaScript Application Architecture
Scalable JavaScript Application Architecture
 
AWS Architecture Case Study: Real-Time Bidding
AWS Architecture Case Study: Real-Time BiddingAWS Architecture Case Study: Real-Time Bidding
AWS Architecture Case Study: Real-Time Bidding
 

Similar to JavaOne 2014: Java vs JavaScript

IBM InterConnect: Java vs JavaScript for Enterprise WebApps
IBM InterConnect: Java vs JavaScript for Enterprise WebAppsIBM InterConnect: Java vs JavaScript for Enterprise WebApps
IBM InterConnect: Java vs JavaScript for Enterprise WebAppsChris Bailey
 
Virtualization aware Java VM
Virtualization aware Java VMVirtualization aware Java VM
Virtualization aware Java VMTim Ellison
 
Was l iberty for java batch and jsr352
Was l iberty for java batch and jsr352Was l iberty for java batch and jsr352
Was l iberty for java batch and jsr352sflynn073
 
Java on zSystems zOS
Java on zSystems zOSJava on zSystems zOS
Java on zSystems zOSTim Ellison
 
(java2days) Is the Future of Java Cloudy?
(java2days) Is the Future of Java Cloudy?(java2days) Is the Future of Java Cloudy?
(java2days) Is the Future of Java Cloudy?Steve Poole
 
Pure Systems Patterns of Expertise - John Kaemmerer and Gerry Kovan, 11th Sep...
Pure Systems Patterns of Expertise - John Kaemmerer and Gerry Kovan, 11th Sep...Pure Systems Patterns of Expertise - John Kaemmerer and Gerry Kovan, 11th Sep...
Pure Systems Patterns of Expertise - John Kaemmerer and Gerry Kovan, 11th Sep...IBM Systems UKI
 
JavaOne 2014: Java Debugging
JavaOne 2014: Java DebuggingJavaOne 2014: Java Debugging
JavaOne 2014: Java DebuggingChris Bailey
 
Webcast urbancodemobiltomainframe
Webcast urbancodemobiltomainframeWebcast urbancodemobiltomainframe
Webcast urbancodemobiltomainframeRosalind Radcliffe
 
.NET Cloud-Native Bootcamp
.NET Cloud-Native Bootcamp.NET Cloud-Native Bootcamp
.NET Cloud-Native BootcampVMware Tanzu
 
Cloud-powered Continuous Integration and Deployment architectures - Jinesh Varia
Cloud-powered Continuous Integration and Deployment architectures - Jinesh VariaCloud-powered Continuous Integration and Deployment architectures - Jinesh Varia
Cloud-powered Continuous Integration and Deployment architectures - Jinesh VariaAmazon Web Services
 
E g innovations overview
E g innovations overviewE g innovations overview
E g innovations overviewNuno Alves
 
Getting Started with PaaS
Getting Started with PaaSGetting Started with PaaS
Getting Started with PaaSCloudBees
 
IBM - Developing portlets using Script portlet in WP 8001
IBM - Developing portlets using Script portlet in WP 8001IBM - Developing portlets using Script portlet in WP 8001
IBM - Developing portlets using Script portlet in WP 8001Vinayak Tavargeri
 
Enterprise Cloud with IBM & Chef (ChefConf 2013)
Enterprise Cloud with IBM & Chef (ChefConf 2013)Enterprise Cloud with IBM & Chef (ChefConf 2013)
Enterprise Cloud with IBM & Chef (ChefConf 2013)Michael Elder
 
Getting Started with Platform-as-a-Service
Getting Started with Platform-as-a-ServiceGetting Started with Platform-as-a-Service
Getting Started with Platform-as-a-ServiceCloudBees
 

Similar to JavaOne 2014: Java vs JavaScript (20)

IBM InterConnect: Java vs JavaScript for Enterprise WebApps
IBM InterConnect: Java vs JavaScript for Enterprise WebAppsIBM InterConnect: Java vs JavaScript for Enterprise WebApps
IBM InterConnect: Java vs JavaScript for Enterprise WebApps
 
Virtualization aware Java VM
Virtualization aware Java VMVirtualization aware Java VM
Virtualization aware Java VM
 
Was l iberty for java batch and jsr352
Was l iberty for java batch and jsr352Was l iberty for java batch and jsr352
Was l iberty for java batch and jsr352
 
Java on zSystems zOS
Java on zSystems zOSJava on zSystems zOS
Java on zSystems zOS
 
(java2days) Is the Future of Java Cloudy?
(java2days) Is the Future of Java Cloudy?(java2days) Is the Future of Java Cloudy?
(java2days) Is the Future of Java Cloudy?
 
Pure Systems Patterns of Expertise - John Kaemmerer and Gerry Kovan, 11th Sep...
Pure Systems Patterns of Expertise - John Kaemmerer and Gerry Kovan, 11th Sep...Pure Systems Patterns of Expertise - John Kaemmerer and Gerry Kovan, 11th Sep...
Pure Systems Patterns of Expertise - John Kaemmerer and Gerry Kovan, 11th Sep...
 
JavaOne 2014: Java Debugging
JavaOne 2014: Java DebuggingJavaOne 2014: Java Debugging
JavaOne 2014: Java Debugging
 
Webcast urbancodemobiltomainframe
Webcast urbancodemobiltomainframeWebcast urbancodemobiltomainframe
Webcast urbancodemobiltomainframe
 
.NET Cloud-Native Bootcamp
.NET Cloud-Native Bootcamp.NET Cloud-Native Bootcamp
.NET Cloud-Native Bootcamp
 
Cloud-powered Continuous Integration and Deployment architectures - Jinesh Varia
Cloud-powered Continuous Integration and Deployment architectures - Jinesh VariaCloud-powered Continuous Integration and Deployment architectures - Jinesh Varia
Cloud-powered Continuous Integration and Deployment architectures - Jinesh Varia
 
E g innovations overview
E g innovations overviewE g innovations overview
E g innovations overview
 
Dattatray Resume
Dattatray ResumeDattatray Resume
Dattatray Resume
 
Node.js Tools Ecosystem
Node.js Tools EcosystemNode.js Tools Ecosystem
Node.js Tools Ecosystem
 
Getting Started with PaaS
Getting Started with PaaSGetting Started with PaaS
Getting Started with PaaS
 
IBM - Developing portlets using Script portlet in WP 8001
IBM - Developing portlets using Script portlet in WP 8001IBM - Developing portlets using Script portlet in WP 8001
IBM - Developing portlets using Script portlet in WP 8001
 
Enterprise Cloud with IBM & Chef (ChefConf 2013)
Enterprise Cloud with IBM & Chef (ChefConf 2013)Enterprise Cloud with IBM & Chef (ChefConf 2013)
Enterprise Cloud with IBM & Chef (ChefConf 2013)
 
Nodejs
NodejsNodejs
Nodejs
 
Beginners Node.js
Beginners Node.jsBeginners Node.js
Beginners Node.js
 
Getting Started with Platform-as-a-Service
Getting Started with Platform-as-a-ServiceGetting Started with Platform-as-a-Service
Getting Started with Platform-as-a-Service
 
SD Times - Docker v2
SD Times - Docker v2SD Times - Docker v2
SD Times - Docker v2
 

More from Chris Bailey

NodeJS Interactive 2019: FaaS meets Frameworks
NodeJS Interactive 2019:  FaaS meets FrameworksNodeJS Interactive 2019:  FaaS meets Frameworks
NodeJS Interactive 2019: FaaS meets FrameworksChris Bailey
 
Voxxed Micro-services: Serverless JakartaEE - JAX-RS comes to FaaS
Voxxed Micro-services: Serverless JakartaEE - JAX-RS comes to FaaSVoxxed Micro-services: Serverless JakartaEE - JAX-RS comes to FaaS
Voxxed Micro-services: Serverless JakartaEE - JAX-RS comes to FaaSChris Bailey
 
Silicon Valley Code Camp 2019 - Reaching the Cloud Native World
Silicon Valley Code Camp 2019 - Reaching the Cloud Native WorldSilicon Valley Code Camp 2019 - Reaching the Cloud Native World
Silicon Valley Code Camp 2019 - Reaching the Cloud Native WorldChris Bailey
 
FaaS Meets Java EE: Developing Cloud Native Applications at Speed
FaaS Meets Java EE: Developing Cloud Native Applications at SpeedFaaS Meets Java EE: Developing Cloud Native Applications at Speed
FaaS Meets Java EE: Developing Cloud Native Applications at SpeedChris Bailey
 
AltConf 2019: Server-Side Swift State of the Union
AltConf 2019:  Server-Side Swift State of the UnionAltConf 2019:  Server-Side Swift State of the Union
AltConf 2019: Server-Side Swift State of the UnionChris Bailey
 
Server-side Swift with Swagger
Server-side Swift with SwaggerServer-side Swift with Swagger
Server-side Swift with SwaggerChris Bailey
 
Node Summit 2018: Cloud Native Node.js
Node Summit 2018: Cloud Native Node.jsNode Summit 2018: Cloud Native Node.js
Node Summit 2018: Cloud Native Node.jsChris Bailey
 
Index - BFFs vs GraphQL
Index - BFFs vs GraphQLIndex - BFFs vs GraphQL
Index - BFFs vs GraphQLChris Bailey
 
Swift Cloud Workshop - Swift Microservices
Swift Cloud Workshop - Swift MicroservicesSwift Cloud Workshop - Swift Microservices
Swift Cloud Workshop - Swift MicroservicesChris Bailey
 
Swift Cloud Workshop - Codable, the key to Fullstack Swift
Swift Cloud Workshop - Codable, the key to Fullstack SwiftSwift Cloud Workshop - Codable, the key to Fullstack Swift
Swift Cloud Workshop - Codable, the key to Fullstack SwiftChris Bailey
 
Try!Swift India 2017: All you need is Swift
Try!Swift India 2017: All you need is SwiftTry!Swift India 2017: All you need is Swift
Try!Swift India 2017: All you need is SwiftChris Bailey
 
Swift Summit 2017: Server Swift State of the Union
Swift Summit 2017: Server Swift State of the UnionSwift Summit 2017: Server Swift State of the Union
Swift Summit 2017: Server Swift State of the UnionChris Bailey
 
IBM Cloud University: Build, Deploy and Scale Node.js Microservices
IBM Cloud University: Build, Deploy and Scale Node.js MicroservicesIBM Cloud University: Build, Deploy and Scale Node.js Microservices
IBM Cloud University: Build, Deploy and Scale Node.js MicroservicesChris Bailey
 
IBM Cloud University: Java, Node.js and Swift
IBM Cloud University: Java, Node.js and SwiftIBM Cloud University: Java, Node.js and Swift
IBM Cloud University: Java, Node.js and SwiftChris Bailey
 
Node Interactive: Node.js Performance and Highly Scalable Micro-Services
Node Interactive: Node.js Performance and Highly Scalable Micro-ServicesNode Interactive: Node.js Performance and Highly Scalable Micro-Services
Node Interactive: Node.js Performance and Highly Scalable Micro-ServicesChris Bailey
 
FrenchKit 2017: Server(less) Swift
FrenchKit 2017: Server(less) SwiftFrenchKit 2017: Server(less) Swift
FrenchKit 2017: Server(less) SwiftChris Bailey
 
AltConf 2017: Full Stack Swift in 30 Minutes
AltConf 2017: Full Stack Swift in 30 MinutesAltConf 2017: Full Stack Swift in 30 Minutes
AltConf 2017: Full Stack Swift in 30 MinutesChris Bailey
 
InterConnect: Server Side Swift for Java Developers
InterConnect:  Server Side Swift for Java DevelopersInterConnect:  Server Side Swift for Java Developers
InterConnect: Server Side Swift for Java DevelopersChris Bailey
 
InterConnect: Java, Node.js and Swift - Which, Why and When
InterConnect: Java, Node.js and Swift - Which, Why and WhenInterConnect: Java, Node.js and Swift - Which, Why and When
InterConnect: Java, Node.js and Swift - Which, Why and WhenChris Bailey
 
Playgrounds: Mobile + Swift = BFF
Playgrounds: Mobile + Swift = BFFPlaygrounds: Mobile + Swift = BFF
Playgrounds: Mobile + Swift = BFFChris Bailey
 

More from Chris Bailey (20)

NodeJS Interactive 2019: FaaS meets Frameworks
NodeJS Interactive 2019:  FaaS meets FrameworksNodeJS Interactive 2019:  FaaS meets Frameworks
NodeJS Interactive 2019: FaaS meets Frameworks
 
Voxxed Micro-services: Serverless JakartaEE - JAX-RS comes to FaaS
Voxxed Micro-services: Serverless JakartaEE - JAX-RS comes to FaaSVoxxed Micro-services: Serverless JakartaEE - JAX-RS comes to FaaS
Voxxed Micro-services: Serverless JakartaEE - JAX-RS comes to FaaS
 
Silicon Valley Code Camp 2019 - Reaching the Cloud Native World
Silicon Valley Code Camp 2019 - Reaching the Cloud Native WorldSilicon Valley Code Camp 2019 - Reaching the Cloud Native World
Silicon Valley Code Camp 2019 - Reaching the Cloud Native World
 
FaaS Meets Java EE: Developing Cloud Native Applications at Speed
FaaS Meets Java EE: Developing Cloud Native Applications at SpeedFaaS Meets Java EE: Developing Cloud Native Applications at Speed
FaaS Meets Java EE: Developing Cloud Native Applications at Speed
 
AltConf 2019: Server-Side Swift State of the Union
AltConf 2019:  Server-Side Swift State of the UnionAltConf 2019:  Server-Side Swift State of the Union
AltConf 2019: Server-Side Swift State of the Union
 
Server-side Swift with Swagger
Server-side Swift with SwaggerServer-side Swift with Swagger
Server-side Swift with Swagger
 
Node Summit 2018: Cloud Native Node.js
Node Summit 2018: Cloud Native Node.jsNode Summit 2018: Cloud Native Node.js
Node Summit 2018: Cloud Native Node.js
 
Index - BFFs vs GraphQL
Index - BFFs vs GraphQLIndex - BFFs vs GraphQL
Index - BFFs vs GraphQL
 
Swift Cloud Workshop - Swift Microservices
Swift Cloud Workshop - Swift MicroservicesSwift Cloud Workshop - Swift Microservices
Swift Cloud Workshop - Swift Microservices
 
Swift Cloud Workshop - Codable, the key to Fullstack Swift
Swift Cloud Workshop - Codable, the key to Fullstack SwiftSwift Cloud Workshop - Codable, the key to Fullstack Swift
Swift Cloud Workshop - Codable, the key to Fullstack Swift
 
Try!Swift India 2017: All you need is Swift
Try!Swift India 2017: All you need is SwiftTry!Swift India 2017: All you need is Swift
Try!Swift India 2017: All you need is Swift
 
Swift Summit 2017: Server Swift State of the Union
Swift Summit 2017: Server Swift State of the UnionSwift Summit 2017: Server Swift State of the Union
Swift Summit 2017: Server Swift State of the Union
 
IBM Cloud University: Build, Deploy and Scale Node.js Microservices
IBM Cloud University: Build, Deploy and Scale Node.js MicroservicesIBM Cloud University: Build, Deploy and Scale Node.js Microservices
IBM Cloud University: Build, Deploy and Scale Node.js Microservices
 
IBM Cloud University: Java, Node.js and Swift
IBM Cloud University: Java, Node.js and SwiftIBM Cloud University: Java, Node.js and Swift
IBM Cloud University: Java, Node.js and Swift
 
Node Interactive: Node.js Performance and Highly Scalable Micro-Services
Node Interactive: Node.js Performance and Highly Scalable Micro-ServicesNode Interactive: Node.js Performance and Highly Scalable Micro-Services
Node Interactive: Node.js Performance and Highly Scalable Micro-Services
 
FrenchKit 2017: Server(less) Swift
FrenchKit 2017: Server(less) SwiftFrenchKit 2017: Server(less) Swift
FrenchKit 2017: Server(less) Swift
 
AltConf 2017: Full Stack Swift in 30 Minutes
AltConf 2017: Full Stack Swift in 30 MinutesAltConf 2017: Full Stack Swift in 30 Minutes
AltConf 2017: Full Stack Swift in 30 Minutes
 
InterConnect: Server Side Swift for Java Developers
InterConnect:  Server Side Swift for Java DevelopersInterConnect:  Server Side Swift for Java Developers
InterConnect: Server Side Swift for Java Developers
 
InterConnect: Java, Node.js and Swift - Which, Why and When
InterConnect: Java, Node.js and Swift - Which, Why and WhenInterConnect: Java, Node.js and Swift - Which, Why and When
InterConnect: Java, Node.js and Swift - Which, Why and When
 
Playgrounds: Mobile + Swift = BFF
Playgrounds: Mobile + Swift = BFFPlaygrounds: Mobile + Swift = BFF
Playgrounds: Mobile + Swift = BFF
 

Recently uploaded

What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...Technogeeks
 
Implementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with AzureImplementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with AzureDinusha Kumarasiri
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...stazi3110
 
Unveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsUnveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsAhmed Mohamed
 
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...Matt Ray
 
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...Angel Borroy López
 
Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...Velvetech LLC
 
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Natan Silnitsky
 
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfAlina Yurenko
 
Folding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a seriesFolding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a seriesPhilip Schwarz
 
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样umasea
 
Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Hr365.us smith
 
Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)Ahmed Mater
 
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASEBATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASEOrtus Solutions, Corp
 
MYjobs Presentation Django-based project
MYjobs Presentation Django-based projectMYjobs Presentation Django-based project
MYjobs Presentation Django-based projectAnoyGreter
 
A healthy diet for your Java application Devoxx France.pdf
A healthy diet for your Java application Devoxx France.pdfA healthy diet for your Java application Devoxx France.pdf
A healthy diet for your Java application Devoxx France.pdfMarharyta Nedzelska
 
Buds n Tech IT Solutions: Top-Notch Web Services in Noida
Buds n Tech IT Solutions: Top-Notch Web Services in NoidaBuds n Tech IT Solutions: Top-Notch Web Services in Noida
Buds n Tech IT Solutions: Top-Notch Web Services in Noidabntitsolutionsrishis
 
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company OdishaBalasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odishasmiwainfosol
 

Recently uploaded (20)

What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...
 
Implementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with AzureImplementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with Azure
 
Advantages of Odoo ERP 17 for Your Business
Advantages of Odoo ERP 17 for Your BusinessAdvantages of Odoo ERP 17 for Your Business
Advantages of Odoo ERP 17 for Your Business
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
 
Unveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsUnveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML Diagrams
 
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
 
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
 
Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...
 
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
 
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
 
Folding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a seriesFolding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a series
 
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
 
Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)
 
2.pdf Ejercicios de programación competitiva
2.pdf Ejercicios de programación competitiva2.pdf Ejercicios de programación competitiva
2.pdf Ejercicios de programación competitiva
 
Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)
 
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASEBATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
 
MYjobs Presentation Django-based project
MYjobs Presentation Django-based projectMYjobs Presentation Django-based project
MYjobs Presentation Django-based project
 
A healthy diet for your Java application Devoxx France.pdf
A healthy diet for your Java application Devoxx France.pdfA healthy diet for your Java application Devoxx France.pdf
A healthy diet for your Java application Devoxx France.pdf
 
Buds n Tech IT Solutions: Top-Notch Web Services in Noida
Buds n Tech IT Solutions: Top-Notch Web Services in NoidaBuds n Tech IT Solutions: Top-Notch Web Services in Noida
Buds n Tech IT Solutions: Top-Notch Web Services in Noida
 
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company OdishaBalasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
 

JavaOne 2014: Java vs JavaScript

  • 1. Chris Bailey – IBM Runtime Monitoring and Diagnostics 1st October 2014 Java vs JavaScript Head to Head Document number © 2014 IBM Corporation
  • 2. © 2014 IBM Corporation Important Disclaimers THE INFORMATION CONTAINED IN THIS PRESENTATION IS PROVIDED FOR INFORMATIONAL PURPOSES ONLY. WHILST EFFORTS WERE MADE TO VERIFY THE COMPLETENESS AND ACCURACY OF THE INFORMATION CONTAINED IN THIS PRESENTATION, IT IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED. ALL PERFORMANCE DATA INCLUDED IN THIS PRESENTATION HAVE BEEN GATHERED IN A CONTROLLED ENVIRONMENT. YOUR OWN TEST RESULTS MAY VARY BASED ON HARDWARE, SOFTWARE OR INFRASTRUCTURE DIFFERENCES. ALL DATA INCLUDED IN THIS PRESENTATION ARE MEANT TO BE USED ONLY AS A GUIDE. IN ADDITION, THE INFORMATION CONTAINED IN THIS PRESENTATION IS BASED ON IBM’S CURRENT PRODUCT PLANS AND STRATEGY, WHICH ARE SUBJECT TO CHANGE BY IBM, WITHOUT NOTICE. IBM AND ITS AFFILIATED COMPANIES SHALL NOT BE RESPONSIBLE FOR ANY DAMAGES ARISING OUT OF THE USE OF, OR OTHERWISE RELATED TO, THIS PRESENTATION OR ANY OTHER DOCUMENTATION. NOTHING CONTAINED IN THIS PRESENTATION IS INTENDED TO, OR SHALL HAVE THE EFFECT OF: - CREATING ANY WARRANT OR REPRESENTATION FROM IBM, ITS AFFILIATED COMPANIES OR ITS OR THEIR SUPPLIERS AND/OR LICENSORS 2
  • 3. A Quick Survey © 2014 3 IBM Corporation
  • 4. What languages do you program in? Java JavaScript Both 60 50 40 30 20 10 0 Percentage of Audience © 2014 4 IBM Corporation
  • 5. What runtimes do you use? Server Java Applets JS in Browser Node.js Rhino Nashorn Avatar.js 100 90 80 70 60 50 40 30 20 10 0 Percentage of Audience © 2014 5 IBM Corporation
  • 6. Introduction to the speaker  Chris Bailey IBM Runtime Monitoring and Diagnostics Architect - 14 years working with Java and JVM technologies - 6 months working with Node.js and V8  Recent work focus: - Java monitoring, diagnostics and troubleshooting - Java integration into the cloud - JavaScript monitoring, diagnostics and troubleshooting  My contact information: - baileyc@uk.ibm.com - http://www.linkedin.com/in/chrisbaileyibm - http://www.slideshare.net/cnbailey/ - @Chris__Bailey © 2014 6 IBM Corporation
  • 7. Goals of this talk ● Langage Adoption ● Deployment Modes ● Introduction to Node.js ● Asynchronous IO ● WebApplication Performance ● Under the Hood of Node.js ● JavaScript on the JVM © 2014 7 IBM Corporation
  • 8. Language Adoption © 2014 8 IBM Corporation
  • 9. GitHub Adoption: Java © 2014 9 IBM Corporation
  • 10. GitHub Adoption: JavaScript GitHut Adoption © 2014 10 IBM Corporation
  • 11. Modulecounts.com © 2014 11 IBM Corporation
  • 12. StackOverFlow Survey © 2014 12 IBM Corporation
  • 13. Tiobe Programming Community Index ● Ratings based on the number of skilled engineers, courses and third party vendors. © 2014 13 IBM Corporation
  • 14. Indeed.com Job Trends © 2014 14 IBM Corporation
  • 15. Indeed.com Job Trends © 2014 15 IBM Corporation
  • 16. Language Adoption  JavaScript has a large developer base - #1 on GitHub with 48.8% more active repositories than Java - #1 on modulecounts.com with 10% more NPM modules than Maven - #1 used language by StackOverflow survey responders - #9 language on the Tiobe index  Java remains a hugely relevant language, particularly on the server - #2 on GitHub with xx% more than the next language - #3 on modulecounts.com with 73.8% more modules than the next language - #2 language on the Tiobe index - #1 on indeed.com for developer jobs © 2014 16 IBM Corporation
  • 17. Deployment Modes © 2014 17 IBM Corporation
  • 18. Usage in the Browser ● JavaScript is ubiquitous in the browser - Supported in every browser - Full integration with HTML and CSS ● Not affected by negative publicity.... Unless it is absolutely necessary to run Java in web browsers, disable it as described below, even after updating to 7u11. This will help mitigate other Java vulnerabilities that may be discovered in the future. This and previous Java vulnerabilities have been widely targeted by attackers, and new Java vulnerabilities are likely to be discovered. To defend against this and future Java vulnerabilities, consider disabling Java in web browsers… © 2014 18 IBM Corporation
  • 19. Usage on the Server ● Java has a long history on the server - JPE launched in 1998 ● Java has rich platform support: - Linux x86, Linux POWER, zLinux - Windows, Mac OS, Solaris, AIX, z/OS  JavaScript is a nascent language on the server - Limited platform support – although its growing - No API support to interact with the OS  Part of the browser security model - Frameworks like Node.js have changed that. © 2014 19 IBM Corporation
  • 20. Introduction to Node.js  Single Threaded Event based JavaScript framework – Uses non-blocking asynchronous I/O  Wraps the Chrome V8 JavaScript engine with I/O interfaces – Libuv provides interaction with OS/system ● Designed to build scalable network applications – Suited for real time delivery of data to distributed client  Available on a growing set of platforms - Windows, Linux x86, Linux ARM, Mac OS, Solaris - Linux POWER, zLinux, AIX Node Standard Library Node Bindings V8 libuv JavaScript C © 2014 20 IBM Corporation
  • 21. Async I/O Model © 2014 21 IBM Corporation
  • 22. Typical approach to IO  One thread (or process) per connection - Each thread waits on a response - Scalability determined by the number of threads  Each thread: - consumes memory - is relatively idle  Number of concurrent customers determined by number of depot workers  Additional customers wait in a queue with no response © 2014 22 IBM Corporation
  • 23. Asynchronous non-blocking IO  One thread multiplexes for multiple requests - No waiting for a response - Handles return from I/O when notified  Scalability determined by: - CPU usage - “Back end” responsiveness  Number of concurrent customers determined by how fast the food Server can work  Or until the kitchen gets slammed © 2014 23 IBM Corporation
  • 24. Drawbacks of Asynchronous IO  Tasks must execute quickly to avoid blocking the event queue - Analogous to work done under a lock - Stick to the right jobs, eg, I/O - Delegate CPU bound tasks to back end processes  Easy to run out of memory - No direct bound on amount of parallel work - Holding state for each piece or work means unbounded memory usage © 2014 24 IBM Corporation
  • 25. JavaScript and Asynchronous IO  JavaScript is already event based in the browser - eg. onClick and onMouseOver events  First class functions and closures fit well with events - Easy to create and pass function callbacks - Easy to execute callbacks in the context of the event  Node.js execution is based on an event loop - Asynchronous I/O built in from the ground up  Node.js execution uses a single thread - No need to worry about locking or shared data - Most machines are now multi-CPU, so cluster capabilities are provided © 2014 25 IBM Corporation
  • 26. HTTP Server Example var cluster = require('cluster'); var cpus = require('os').cpus().length; var http = require('http'); if (cluster.isMaster) { for (var i = 0; i < cpus; i++) { cluster.fork(); } cluster.on('death', function(worker) { console.log("Worker" + worker.pid + "died"); }); } else { http.createServer(function(request, response) { response.writeHead(200, {"Content-Type": "text/plain"}); response.write("Hello World!n"); response.end(); }).listen(8080); } © 2014 26 IBM Corporation
  • 27. HTTP Server Example with Clustering var cluster = require('cluster'); var cpus = require('os').cpus().length; var http = require('http'); if (cluster.isMaster) { for (var i = 0; i < cpus; i++) { cluster.fork(); } cluster.on('death', function(worker) { console.log("Worker" + worker.pid + "died"); }); } else { http.createServer(function(request, response) { response.writeHead(200, {"Content-Type": "text/plain"}); response.write("Hello World!n"); response.end(); }).listen(8080); } © 2014 27 IBM Corporation
  • 28. Event Loop Example  Hypothetical implementation of readFile(): function readFile(filename, cb) { nb_open(filename, function(err, fd) { if (err) cb(err, null); nb_read(fd, function(err, data) { cb(err, data); nb_close(fd); }); }); } © 2014 28 IBM Corporation
  • 29. © 2014 29 IBM Corporation
  • 30. © 2014 30 IBM Corporation
  • 31. © 2014 31 IBM Corporation
  • 32. © 2014 32 IBM Corporation
  • 33. © 2014 33 IBM Corporation
  • 34. © 2014 34 IBM Corporation
  • 35. © 2014 35 IBM Corporation
  • 36. © 2014 36 IBM Corporation
  • 37. © 2014 37 IBM Corporation
  • 38. © 2014 38 IBM Corporation
  • 39. © 2014 39 IBM Corporation
  • 40. © 2014 40 IBM Corporation
  • 41. © 2014 41 IBM Corporation
  • 42. © 2014 42 IBM Corporation
  • 43. © 2014 43 IBM Corporation
  • 44. © 2014 44 IBM Corporation
  • 45. © 2014 45 IBM Corporation
  • 46. © 2014 46 IBM Corporation
  • 47. © 2014 47 IBM Corporation
  • 48. © 2014 48 IBM Corporation
  • 49. © 2014 49 IBM Corporation
  • 50. © 2014 50 IBM Corporation
  • 51. © 2014 51 IBM Corporation
  • 52. © 2014 52 IBM Corporation
  • 53. © 2014 53 IBM Corporation
  • 54. © 2014 54 IBM Corporation
  • 55. © 2014 55 IBM Corporation
  • 56. © 2014 56 IBM Corporation
  • 57. © 2014 57 IBM Corporation
  • 58. © 2014 58 IBM Corporation
  • 59. © 2014 59 IBM Corporation
  • 60. © 2014 60 IBM Corporation
  • 61. © 2014 61 IBM Corporation
  • 62. © 2014 62 IBM Corporation
  • 63. © 2014 63 IBM Corporation
  • 64. JavaScript and Asynchronous I/O  Very little time spent with events on the Event Loop  Provides good scalability, so should provide great performance for IO bound apps  Like WebApplications... © 2014 64 IBM Corporation
  • 65. WebApp Performance © 2014 65 IBM Corporation
  • 66. JSON Serialization  JSON serialization of a newly instantiated object  Maps - Key of message - Value of Hello, World!  Example response: Results from TechEmpower.com Round 9 tests (2014-05-01) © 2014 66 IBM Corporation
  • 67. JSON Serialization  JSON serialization of a newly instantiated object  Maps - Key of message - Value of Hello, World!  Example response: Results from TechEmpower.com Round 9 tests (2014-05-01) © 2014 67 IBM Corporation
  • 68. Single Query  Fetches single row from simple database table  Row serialized as JSON  Example response: Results from TechEmpower.com Round 9 tests (2014-05-01) © 2014 68 IBM Corporation
  • 69. Single Query  Fetches single row from simple database table  Row serialized as JSON  Example response: Results from TechEmpower.com Round 9 tests (2014-05-01) © 2014 69 IBM Corporation
  • 70. Multiple Query  Fetches multiple rows from a simple database table  Rows serialized as JSON  Example response: Results from TechEmpower.com Round 9 tests (2014-05-01) © 2014 70 IBM Corporation
  • 71. Multiple Query  Fetches multiple rows from a simple database table  Rows serialized as JSON  Example response: Results from TechEmpower.com Round 9 tests (2014-05-01) © 2014 71 IBM Corporation
  • 72. Data Updates  Fetches multiple rows from a simple database table  Converts rows to objects and modifies one attribute of each object  Updates each associated row and serializes as JSON  Example Response: Results taken from TechEmpower.com © 2014 72 IBM Corporation
  • 73. Data Updates  Fetches multiple rows from a simple database table  Converts rows to objects and modifies one attribute of each object  Updates each associated row and serializes as JSON  Example Response: Results taken from TechEmpower.com © 2014 73 IBM Corporation
  • 74. Under the Hood © 2014 74 IBM Corporation
  • 75. Polymorphism and Object Representation Integer Class Integer Object Name: Integer Class pointer Class pointer Class pointer Class pointer Flags Flags Flags Flags Locks Locks Locks Locks int int int int Super Class Method Table Field Table Constant Pool Object Offsets ...  Java objects are fixed in size and shape - Determined by the object type - Type determined by class pointer  Class pointer gives access to Method Table - All methods executable from the object  Class pointer also gives access to Object Offsets - Fields in the object that are objects - Used for graph traversal during GC © 2014 75 IBM Corporation
  • 76. Polymorphism and Object Representation Map Field: offset Field: offset Field: offset Fixed Array Map Length Fixed Array Map 1: 2: 1: Length 2: JSObject  JavaScript objects polymorphic and can change in size and shape  “Simple” objects: - Created with 32 fields - Contains a Map describing key : value parings - Contains “extra properties” for overflow - Contains “elements” for array values - All fields are 64bits  Multiple maps can exist for “equal” objects - Dependent on order in which fields are added to the object - ie. X then Y, or Y then X Map Extra Props Elements 1: 2: 3: ... ... 32: © 2014 76 IBM Corporation
  • 77. Polymorphism and JIT Compilation  Functions are stored in JavaScript objects as fields - No fixed set of methods for an object ● Objects are not typed, so data much be checked to determine how to handle it eg. the '+' operator: - number + number → addition - string involved? → concatenation - objects involved? → convert to primitives then addition or concatenation eg. property load: - Load prototype object - Load getter method - Load callback function ● Therefore not possible to determine what instructions to use just from the source code © 2014 77 IBM Corporation
  • 78. Approach to JIT Compilation  V8 JavaScript engine has two compilers  Full Compiler - Compiles JavaScript to native code on first execution - No bytecode stage, and no real optimization applied - Implements a Polymorphic Inline Cache (PIC)  Crankshaft - Execution counter based compilation strategy  Also supports on-stack replacement for code with hot loops - Compilation is done in the execution path - Optimized for types present in the PIC © 2014 78 IBM Corporation
  • 79. Polymorphism and Garbage Collection  Implements Generational Garbage Collection, similar to the JVM – New space, Old space, Large Object space, Remembered sets – Additional JavaScript specific areas: map space, cell space, property cell space – Implements concurrent mark/sweep capabilities  Root scan based on Global objects and local variables on the stack – Reference tree built by following object references to further objects – However... how do we know which variables are Objects rather than data? • Solution is tagged pointers – use of 01 in the low order bits to denote a pointer © 2014 79 IBM Corporation
  • 80. JavaScript on the JVM? © 2014 80 IBM Corporation
  • 81. JavaScript on the JVM  Rhino was bundled in JDK6 - Based on the Mozilla Rhino engine - Allowed JavaScript to be embedded in Java, and for JavaScript to call out to Java - Provided jrunscript command line utility  Nashorn replaces JavaScript in JDK8 - Supports full ECMAScript 5.1 specification - Exploits invokedynamic to provide 2x to 10x better performance than Rhino - Provides jjs command line utility © 2014 81 IBM Corporation
  • 82. JavaScript on the JVM  SRcrhiinpot Ewnagsi nbeuMnadnleadge inr JsDcKri6ptEngineManager = new ScriptEngineManager(); ScriptEngine nashorn = scriptEngineManager.getEngineByName("nashorn"); int sendVal = 7; nashorn.put("sendVal", sendVal); nashorn.eval(" "+ "var Thread = Java.type("java.lang.Thread"); "+ "var MyThread = Java.extend(Thread, { "+ " run: function() { "+ " print("Run in separate thread"); "+ " } "+ "}); "+ "var th = new MyThread(); "+ "th.start(); "+ "th.join(); "+ "var resultVal = sendVal + 3;"); System.out.println(nashorn.get("resultVal"); © 2014 82 IBM Corporation
  • 83. JavaScript on the JVM ScriptEngineManager scriptEngineManager = new ScriptEngineManager(); ScriptEngine nashorn = scriptEngineManager.getEngineByName("nashorn"); int sendVal = 7; nashorn.put("sendVal", sendVal); nashorn.eval(" "+ "var Thread = Java.type("java.lang.Thread"); "+ "var MyThread = Java.extend(Thread, { "+ " run: function() { "+ " print("Run in separate thread"); "+ " } "+ "}); "+ "var th = new MyThread(); "+ "th.start(); "+ "th.join(); "+ "var resultVal = sendVal + 3;"); System.out.println(nashorn.get("resultVal"); © 2014 83 IBM Corporation
  • 84. JavaScript on the JVM ScriptEngineManager scriptEngineManager = new ScriptEngineManager(); ScriptEngine nashorn = scriptEngineManager.getEngineByName("nashorn"); int sendVal = 7; nashorn.put("sendVal", sendVal); nashorn.eval(" "+ "var Thread = Java.type("java.lang.Thread"); "+ "var MyThread = Java.extend(Thread, { "+ " run: function() { "+ " print("Run in separate thread"); "+ " } "+ "}); "+ "var th = new MyThread(); "+ "th.start(); "+ "th.join(); "+ "var resultVal = sendVal + 3;"); System.out.println(nashorn.get("resultVal"); © 2014 84 IBM Corporation
  • 85. JavaScript on the JVM ScriptEngineManager scriptEngineManager = new ScriptEngineManager(); ScriptEngine nashorn = scriptEngineManager.getEngineByName("nashorn"); int sendVal = 7; nashorn.put("sendVal", sendVal); nashorn.eval(" "+ "var Thread = Java.type("java.lang.Thread"); "+ "var MyThread = Java.extend(Thread, { "+ " run: function() { "+ " print("Run in separate thread"); "+ " } "+ "}); "+ "var th = new MyThread(); "+ "th.start(); "+ "th.join(); "+ "var resultVal = sendVal + 3;"); System.out.println(nashorn.get("resultVal"); © 2014 85 IBM Corporation
  • 86. JavaScript on the JVM ScriptEngineManager scriptEngineManager = new ScriptEngineManager(); ScriptEngine nashorn = scriptEngineManager.getEngineByName("nashorn"); int sendVal = 7; nashorn.put("sendVal", sendVal); nashorn.eval(" "+ "var Thread = Java.type("java.lang.Thread"); "+ "var MyThread = Java.extend(Thread, { "+ " run: function() { "+ " print("Run in separate thread"); "+ " } "+ "}); "+ "var th = new MyThread(); "+ "th.start(); "+ "th.join(); "+ "var resultVal = sendVal + 3;"); System.out.println(nashorn.get("resultVal"); © 2014 86 IBM Corporation
  • 87. JavaScript on the JVM ScriptEngineManager scriptEngineManager = new ScriptEngineManager(); ScriptEngine nashorn = scriptEngineManager.getEngineByName("nashorn"); int sendVal = 7; nashorn.put("sendVal", sendVal); nashorn.eval(" "+ "var Thread = Java.type("java.lang.Thread"); "+ "var MyThread = Java.extend(Thread, { "+ " run: function() { "+ " print("Run in separate thread"); "+ " } "+ "}); "+ "var th = new MyThread(); "+ "th.start(); "+ "th.join(); "+ "var resultVal = sendVal + 3;"); System.out.println(nashorn.get("resultVal"); © 2014 87 IBM Corporation
  • 88. JavaScript on the JVM ScriptEngineManager scriptEngineManager = new ScriptEngineManager(); ScriptEngine nashorn = scriptEngineManager.getEngineByName("nashorn"); int sendVal = 7; nashorn.put("sendVal", sendVal); nashorn.eval(" "+ "var Thread = Java.type("java.lang.Thread"); "+ "var MyThread = Java.extend(Thread, { "+ " run: function() { "+ " print("Run in separate thread"); "+ " } "+ "}); "+ "var th = new MyThread(); "+ "th.start(); "+ "th.join(); "+ "var resultVal = sendVal + 3;"); System.out.println(nashorn.get("resultVal"); © 2014 88 IBM Corporation
  • 89. Introduction to Avatar.js  Support for Node.js on Nashorn  Binary builds available from Maven – Avatar-js.jar – Avatar-js library (64bit)  Number of common NPM modules are supported  NPM required to dependencies  Issues for native NPMs – No native V8 APIs From https://avatar-js.java.net/ © 2014 89 IBM Corporation
  • 90. Avatar.js vs Node.js  Running Octane r33 – The “SpecJVM98” of the JavaScript world – Actually a JavaScript benchmark rather than a Node.js benchmark – So more comparing Nashorn to V8  Run on a 8 CPU Windows using: – Node.js v0.10.31 – HotSpot 8u20  Settings are “out of the box” with no attempt to tune © 2014 90 IBM Corporation
  • 91. Avatar.js running Octane Bencmark Avatar.js ● Duration: 1m 56s ● Peak memory: 2830MB © 2014 91 IBM Corporation
  • 92. Node.js running Octane Bencmark Node.js ● Duration: 24s ● Peak memory: 268MB © 2014 92 IBM Corporation
  • 93. Avatar.js vs Node.js Memory Usage Avatar.js ● Duration: 1m 56s ● Peak memory: 2830MB Node.js ● Duration: 24s ● Peak memory: 268MB Node.js is 4.8x faster Avatar.js is >10x bigger © 2014 93 IBM Corporation
  • 94. Avatar.js vs Node.js: Garbage Collection  Avatar.js peak is: – 920MB / 1.85GB  Node.js peak is: – 200MB / 220MB  Additional 700+MB of Object Heap  Additional 1GB of non-Object Heap © 2014 94 IBM Corporation
  • 95. Avatar.js vs Node.js: Stack Traces  Interpretation of JavaScript at the Java layer means stacks are large and anonymous © 2014 95 IBM Corporation
  • 96. Summary  JavaScript has a large amount of interest and is growing – Fits well for web applications and code sharing between server and browser – Async IO and event loop model makes it easy to write scalable applications  Weak typing and dynamic linkage makes programming easier, but introduces challenges – Errors found during compilation for strongly typed languages are found at runtime – JIT compilation loves certainty, which is removed  Nashorn and Avatar.js introduces JavaScript to the JVM – Adds interoperability – … but suffers from the same challenges © 2014 96 IBM Corporation
  • 97. IBM Developer Kits for Java ibm.biz/javasdk WebShere Liberty Profile wasdev.net IBM Bluemix ibm.com/bluemix IBM Developer Kits for Node.js ibm.biz/nodesdk © 2014 97 IBM Corporation
  • 98. Questions? © 2014 98 IBM Corporation
  • 99. www.ibm.com/developer Discover new technical resources. ibm.biz/javaone2014 Visit Booth 5511 to learn about Cloud, DevOps and Mobile solutions © 2014 IBM Corporation Develop your coding skills. Connect with developers.
  • 100. Copyright and Trademarks © IBM Corporation 2013. All Rights Reserved. IBM, the IBM logo, and ibm.com are trademarks or registered trademarks of International Business Machines Corp., and registered in many jurisdictions worldwide. Other product and service names might be trademarks of IBM or other companies. A current list of IBM trademarks is available on the Web – see the IBM “Copyright and trademark information” page at URL: www.ibm.com/legal/copytrade.shtml © 2014 100 IBM Corporation