SlideShare ist ein Scribd-Unternehmen logo
1 von 22
Enhancing scalability
using Node.js
Team 15 - Enlighten
Ratan Kadam - ratan.kadam@gmail.com
Monil Shah - monil.shaah@gmail.com
Akshay Jarandikar - akshayjaradikar@gmail.com
Swapnil Joshi - swapnil.joshi1590@gmail.com
Scalability
 WhyWhat is scalability?
 do we need scalability?
 Current industry solutions -
• Horizontal Scaling
• Vertical Scaling
• Multi-threading
• Cloud Computing
Horizontal vs Vertical Scaling
Horizontal Scaling
Adds extra identical boxes to
server.
Issues:
• Requires Load balancer for
managing connection.
• Distribution of work within the
units becomes overhead.
• Additional investment.
Vertical Scaling
Increases the power of existing
system by adding more powerful
hardware.
Issues:
• Additional Investment
• Single point of failure
(SPOF)
Multi-threading & Cloud Computing
Multi-threading
Issues:
-High chances of deadlock if
application is not designed
properly.
-Web-servers need to handle
thousands of HTTP requests. This
may cause many threads to wait
for network operations.
-For thousands of simultaneous
requests, spawning threads for all
processes would not achieve the
desired scalability.
Cloud Computing
Issues:
-Application architecture may or
may not be suited for Cloud
Computing
-Application and Data Security in
the Cloud
-Lack of skilled resources;
external training is required
-If application is not designed
properly for cloud platform;
difficult to yield benefits
-Again, substantial additional
investment
So the challenge…
 The challenge is to scale the web
application without major re-engineering
and buying new hardware while keeping
its architecture simple and easy to
manage.
Solution
Important Features:
Asynchronous in nature
Event driven
Non-blocking I/O
Proposed Architecture
Proxy Middleware, Entry point for real
world access, Security, Caching
Nginx Server Serves static content, Caching
Load Balancer  connects multithreaded
node.js instances and handles load distribution
V8 JavaScript engine  handles compilation and
execution of JavaScript
Event loop  Handles events in program
during execution of asynchronous operations.
Proxy Server
Server Pool
Routing request based on content type
Nginx server
Nginx server stores static data in hierarchical cache. Thus reduces the latency.
Also supports compression format to reduce response size.
Node.js Workflow
3 core execution models:
1.Asynchronous request processing
2.Event driven programming
3.Non-blocking I/O
 When request is made to server, instead of waiting for the request to complete,
server continues to process other requests.
 When request processing completes, the response is sent to caller using
callback mechanism.
 Event listener listens to the events and determines the flow of program.
 There is an event loop that listens to events and then triggers callback functions.
Non-blocking I/O
 Non-blocking I/O supports the execution of system to be continued
without waiting for I/O operations to complete.
 This enables the architecture to have asynchronous request
processing.
Event loop
Event loop is a programming construct that waits for and dispatches events in a
program once their asynchronous operation completes.
Node Load Balancer Working
 Load balancer
distributes the
workload among
available servers.
 Load Balancer sends
periodic heartbeat to
check server status.
 If one of the servers is
down then the load
balancer distributes
the request queue
among the available
servers.
V8 JavaScript Engine
 When V8 receives script source code, it parses it to create abstract
syntax tree.
 Then this AST is fed into the byte code generator to produce byte
code of the source.
 V8 execution environment then interprets this byte code and with the
help of JIT compiler it produces the native machine code that gets
executed.
 It uses techniques such as in-lining, elision of expensive runtime
properties, and inline caching are used for optimization
CASE STUDY
PayPal & eBay with Node.Js
Changes from development
perspective -
The development time was almost
half that with fewer people.
Number of files that were
constructed reduced to 40%.
The number of lines of code was
reduced by 33%.
Changes from performance
perspective
The number of requests per
second is doubled compared to Java
application.
 The response time is decreased
by 35% compared to Java
application.
Node.js Vs Traditional Java
Advantages
1. Asynchronous
2. Event driven programming
3. Multithreading
4. Scalability
5. High throughput
6. High Performance
7. Cost effective
8.Minimum Latency
9. Efficient Resource Consumption
10. Set of Standard Libraries
Conclusion
Scalability is next decade challenge for enterprise community
as more than 7.1 billion people are using internet.
Most of the vendors use solutions like Horizontal, vertical &
single threaded node.js. However, these single threaded
architectures may not be able to fix the next generation scalable
issues.
Solution to the problem is defined in our proposed architecture –
multithreaded node.js where multiple node.js instances are bind
to the fixed number of threads to boost the power of existing
Node JS.
So multithreaded node.js can be a cost effective, software based
scalable solution for next decade challenges for Enterprise
industries.
References
 Web application performance and scalability
http://www.webforefront.com/performance/scaling101.html
 Node.js at PayPal
https://www.paypal-engineering.com/2013/11/22/node-js-at-paypal/
 Nginx
http://www.aosabook.org/en/nginx.html
 Ebay’s first node.js application
http://www.ebaytechblog.com/2013/05/17/how-we-built-ebays-first-node-
js-application/#.VHLrNIvF9hw
 Node.js architecture diagram
http://blog.cloudfoundry.org/2012/06/27/future-proofing-your-apps-cloud-
foundry-and-node-js/
Questions…
Thank You..

Weitere ähnliche Inhalte

Was ist angesagt?

Serverless java
Serverless   javaServerless   java
Serverless javaVishwas N
 
How to Use OWASP Security Logging
How to Use OWASP Security LoggingHow to Use OWASP Security Logging
How to Use OWASP Security LoggingMilton Smith
 
Java script nirvana in netbeans [con5679]
Java script nirvana in netbeans [con5679]Java script nirvana in netbeans [con5679]
Java script nirvana in netbeans [con5679]Ryan Cuprak
 
Serverless / FaaS / Lambda and how it relates to Microservices
Serverless / FaaS / Lambda and how it relates to MicroservicesServerless / FaaS / Lambda and how it relates to Microservices
Serverless / FaaS / Lambda and how it relates to MicroservicesFrank Munz
 
From VMs to Containers: Introducing Docker Containers for Linux and Windows S...
From VMs to Containers: Introducing Docker Containers for Linux and Windows S...From VMs to Containers: Introducing Docker Containers for Linux and Windows S...
From VMs to Containers: Introducing Docker Containers for Linux and Windows S...Ido Flatow
 
Microservices with Micronaut
Microservices with MicronautMicroservices with Micronaut
Microservices with MicronautQAware GmbH
 
Developing in the Cloud
Developing in the CloudDeveloping in the Cloud
Developing in the CloudRyan Cuprak
 
Stay productive while slicing up the monolith
Stay productive while slicing up the monolith Stay productive while slicing up the monolith
Stay productive while slicing up the monolith Markus Eisele
 
Scaling tokopedia-past-present-future
Scaling tokopedia-past-present-futureScaling tokopedia-past-present-future
Scaling tokopedia-past-present-futureRein Mahatma
 
From VMs to Containers: Decompose and Migrate Old Legacy JavaEE Application
From VMs to Containers: Decompose and Migrate Old Legacy JavaEE ApplicationFrom VMs to Containers: Decompose and Migrate Old Legacy JavaEE Application
From VMs to Containers: Decompose and Migrate Old Legacy JavaEE ApplicationJelastic Multi-Cloud PaaS
 
Microservices with containers in the cloud
Microservices with containers in the cloudMicroservices with containers in the cloud
Microservices with containers in the cloudEugene Fedorenko
 
How to build an HA container orchestrator infrastructure for production – Giu...
How to build an HA container orchestrator infrastructure for production – Giu...How to build an HA container orchestrator infrastructure for production – Giu...
How to build an HA container orchestrator infrastructure for production – Giu...Codemotion
 
Building Micro-Services with Scala
Building Micro-Services with ScalaBuilding Micro-Services with Scala
Building Micro-Services with ScalaYardena Meymann
 
Oracle CODE 2017 San Francisco: Docker on Raspi Swarm to OCCS
Oracle CODE 2017 San Francisco: Docker on Raspi Swarm to OCCSOracle CODE 2017 San Francisco: Docker on Raspi Swarm to OCCS
Oracle CODE 2017 San Francisco: Docker on Raspi Swarm to OCCSFrank Munz
 

Was ist angesagt? (20)

Serverless java
Serverless   javaServerless   java
Serverless java
 
How to Use OWASP Security Logging
How to Use OWASP Security LoggingHow to Use OWASP Security Logging
How to Use OWASP Security Logging
 
Java script nirvana in netbeans [con5679]
Java script nirvana in netbeans [con5679]Java script nirvana in netbeans [con5679]
Java script nirvana in netbeans [con5679]
 
Serverless / FaaS / Lambda and how it relates to Microservices
Serverless / FaaS / Lambda and how it relates to MicroservicesServerless / FaaS / Lambda and how it relates to Microservices
Serverless / FaaS / Lambda and how it relates to Microservices
 
From VMs to Containers: Introducing Docker Containers for Linux and Windows S...
From VMs to Containers: Introducing Docker Containers for Linux and Windows S...From VMs to Containers: Introducing Docker Containers for Linux and Windows S...
From VMs to Containers: Introducing Docker Containers for Linux and Windows S...
 
Microservices with Micronaut
Microservices with MicronautMicroservices with Micronaut
Microservices with Micronaut
 
JEEconf 2017
JEEconf 2017JEEconf 2017
JEEconf 2017
 
Developing in the Cloud
Developing in the CloudDeveloping in the Cloud
Developing in the Cloud
 
Container Patterns
Container PatternsContainer Patterns
Container Patterns
 
Stay productive while slicing up the monolith
Stay productive while slicing up the monolith Stay productive while slicing up the monolith
Stay productive while slicing up the monolith
 
Serverless and cloud computing
Serverless and cloud computingServerless and cloud computing
Serverless and cloud computing
 
Adf with docker
Adf with dockerAdf with docker
Adf with docker
 
Scaling tokopedia-past-present-future
Scaling tokopedia-past-present-futureScaling tokopedia-past-present-future
Scaling tokopedia-past-present-future
 
From VMs to Containers: Decompose and Migrate Old Legacy JavaEE Application
From VMs to Containers: Decompose and Migrate Old Legacy JavaEE ApplicationFrom VMs to Containers: Decompose and Migrate Old Legacy JavaEE Application
From VMs to Containers: Decompose and Migrate Old Legacy JavaEE Application
 
ASP.NET vNext
ASP.NET vNextASP.NET vNext
ASP.NET vNext
 
Microservices: Another Way
Microservices: Another WayMicroservices: Another Way
Microservices: Another Way
 
Microservices with containers in the cloud
Microservices with containers in the cloudMicroservices with containers in the cloud
Microservices with containers in the cloud
 
How to build an HA container orchestrator infrastructure for production – Giu...
How to build an HA container orchestrator infrastructure for production – Giu...How to build an HA container orchestrator infrastructure for production – Giu...
How to build an HA container orchestrator infrastructure for production – Giu...
 
Building Micro-Services with Scala
Building Micro-Services with ScalaBuilding Micro-Services with Scala
Building Micro-Services with Scala
 
Oracle CODE 2017 San Francisco: Docker on Raspi Swarm to OCCS
Oracle CODE 2017 San Francisco: Docker on Raspi Swarm to OCCSOracle CODE 2017 San Francisco: Docker on Raspi Swarm to OCCS
Oracle CODE 2017 San Francisco: Docker on Raspi Swarm to OCCS
 

Andere mochten auch

Interactive publication platform
Interactive publication platformInteractive publication platform
Interactive publication platformratankadam
 
Anatomy of a Modern Node.js Application Architecture
Anatomy of a Modern Node.js Application Architecture Anatomy of a Modern Node.js Application Architecture
Anatomy of a Modern Node.js Application Architecture AppDynamics
 
Architecting large Node.js applications
Architecting large Node.js applicationsArchitecting large Node.js applications
Architecting large Node.js applicationsSergi Mansilla
 
Introduction to Node.js
Introduction to Node.jsIntroduction to Node.js
Introduction to Node.jsVikash Singh
 
Horizontally Scaling Node.js and WebSockets
Horizontally Scaling Node.js and WebSocketsHorizontally Scaling Node.js and WebSockets
Horizontally Scaling Node.js and WebSocketsJames Simpson
 
Node Foundation Membership Overview 20160907
Node Foundation Membership Overview 20160907Node Foundation Membership Overview 20160907
Node Foundation Membership Overview 20160907NodejsFoundation
 
Introduction to Nodejs and Isomorphic javascript
Introduction to Nodejs and Isomorphic javascriptIntroduction to Nodejs and Isomorphic javascript
Introduction to Nodejs and Isomorphic javascriptChenKuo Chen
 
Xitrum internals
Xitrum internalsXitrum internals
Xitrum internalsNgoc Dao
 
JavaScript Architecture: The Front and the Back of It
JavaScript Architecture: The Front and the Back of ItJavaScript Architecture: The Front and the Back of It
JavaScript Architecture: The Front and the Back of ItKyle Simpson
 
Building and Scaling Node.js Applications
Building and Scaling Node.js ApplicationsBuilding and Scaling Node.js Applications
Building and Scaling Node.js ApplicationsOhad Kravchick
 
Building scalable network applications with Netty (as presented on NLJUG JFal...
Building scalable network applications with Netty (as presented on NLJUG JFal...Building scalable network applications with Netty (as presented on NLJUG JFal...
Building scalable network applications with Netty (as presented on NLJUG JFal...Jaap ter Woerds
 
Realtime webapp with node.js
Realtime webapp with node.jsRealtime webapp with node.js
Realtime webapp with node.jsrobin_sy
 
Planning for the Horizontal: Scaling Node.js Applications
Planning for the Horizontal: Scaling Node.js ApplicationsPlanning for the Horizontal: Scaling Node.js Applications
Planning for the Horizontal: Scaling Node.js ApplicationsModulus
 
Getting Started with the Node.js LoopBack APi Framework
Getting Started with the Node.js LoopBack APi FrameworkGetting Started with the Node.js LoopBack APi Framework
Getting Started with the Node.js LoopBack APi FrameworkJimmy Guerrero
 
NodeJS et SocketIO en mode scalable dans le Cloud - GAB 2015
NodeJS et SocketIO en mode scalable dans le Cloud - GAB 2015NodeJS et SocketIO en mode scalable dans le Cloud - GAB 2015
NodeJS et SocketIO en mode scalable dans le Cloud - GAB 2015Stéphane ESCANDELL
 

Andere mochten auch (20)

Interactive publication platform
Interactive publication platformInteractive publication platform
Interactive publication platform
 
Anatomy of a Modern Node.js Application Architecture
Anatomy of a Modern Node.js Application Architecture Anatomy of a Modern Node.js Application Architecture
Anatomy of a Modern Node.js Application Architecture
 
NodeJS for Beginner
NodeJS for BeginnerNodeJS for Beginner
NodeJS for Beginner
 
Node.js - Best practices
Node.js  - Best practicesNode.js  - Best practices
Node.js - Best practices
 
Architecting large Node.js applications
Architecting large Node.js applicationsArchitecting large Node.js applications
Architecting large Node.js applications
 
Introduction to Node.js
Introduction to Node.jsIntroduction to Node.js
Introduction to Node.js
 
Horizontally Scaling Node.js and WebSockets
Horizontally Scaling Node.js and WebSocketsHorizontally Scaling Node.js and WebSockets
Horizontally Scaling Node.js and WebSockets
 
Node Foundation Membership Overview 20160907
Node Foundation Membership Overview 20160907Node Foundation Membership Overview 20160907
Node Foundation Membership Overview 20160907
 
Introduction to Nodejs and Isomorphic javascript
Introduction to Nodejs and Isomorphic javascriptIntroduction to Nodejs and Isomorphic javascript
Introduction to Nodejs and Isomorphic javascript
 
Xitrum internals
Xitrum internalsXitrum internals
Xitrum internals
 
JavaScript Architecture: The Front and the Back of It
JavaScript Architecture: The Front and the Back of ItJavaScript Architecture: The Front and the Back of It
JavaScript Architecture: The Front and the Back of It
 
Keymetrics pm2
Keymetrics pm2Keymetrics pm2
Keymetrics pm2
 
What is Browser Sandbox Protection?
What is Browser Sandbox Protection?What is Browser Sandbox Protection?
What is Browser Sandbox Protection?
 
Building and Scaling Node.js Applications
Building and Scaling Node.js ApplicationsBuilding and Scaling Node.js Applications
Building and Scaling Node.js Applications
 
Building scalable network applications with Netty (as presented on NLJUG JFal...
Building scalable network applications with Netty (as presented on NLJUG JFal...Building scalable network applications with Netty (as presented on NLJUG JFal...
Building scalable network applications with Netty (as presented on NLJUG JFal...
 
Realtime webapp with node.js
Realtime webapp with node.jsRealtime webapp with node.js
Realtime webapp with node.js
 
Planning for the Horizontal: Scaling Node.js Applications
Planning for the Horizontal: Scaling Node.js ApplicationsPlanning for the Horizontal: Scaling Node.js Applications
Planning for the Horizontal: Scaling Node.js Applications
 
Getting Started with the Node.js LoopBack APi Framework
Getting Started with the Node.js LoopBack APi FrameworkGetting Started with the Node.js LoopBack APi Framework
Getting Started with the Node.js LoopBack APi Framework
 
NodeJS et SocketIO en mode scalable dans le Cloud - GAB 2015
NodeJS et SocketIO en mode scalable dans le Cloud - GAB 2015NodeJS et SocketIO en mode scalable dans le Cloud - GAB 2015
NodeJS et SocketIO en mode scalable dans le Cloud - GAB 2015
 
WebSocket avec Java EE 7
WebSocket avec Java EE 7WebSocket avec Java EE 7
WebSocket avec Java EE 7
 

Ähnlich wie Scalability using Node.js

NodeJS ecosystem
NodeJS ecosystemNodeJS ecosystem
NodeJS ecosystemYukti Kaura
 
Data stream processing and micro service architecture
Data stream processing and micro service architectureData stream processing and micro service architecture
Data stream processing and micro service architectureVyacheslav Benedichuk
 
8 Best Ways To Boost Node.js Performance Of Your Application!.pdf
8 Best Ways To Boost Node.js Performance Of Your Application!.pdf8 Best Ways To Boost Node.js Performance Of Your Application!.pdf
8 Best Ways To Boost Node.js Performance Of Your Application!.pdfSufalam Technologies
 
Understanding the Single Thread Event Loop
Understanding the Single Thread Event LoopUnderstanding the Single Thread Event Loop
Understanding the Single Thread Event LoopTorontoNodeJS
 
Building Applications With the MEAN Stack
Building Applications With the MEAN StackBuilding Applications With the MEAN Stack
Building Applications With the MEAN StackNir Noy
 
Practical Thin Server Architecture With Dojo Sapo Codebits 2008
Practical Thin Server Architecture With Dojo Sapo Codebits 2008Practical Thin Server Architecture With Dojo Sapo Codebits 2008
Practical Thin Server Architecture With Dojo Sapo Codebits 2008codebits
 
Architecting and Tuning IIB/eXtreme Scale for Maximum Performance and Reliabi...
Architecting and Tuning IIB/eXtreme Scale for Maximum Performance and Reliabi...Architecting and Tuning IIB/eXtreme Scale for Maximum Performance and Reliabi...
Architecting and Tuning IIB/eXtreme Scale for Maximum Performance and Reliabi...Prolifics
 
GlobalsDB: Its significance for Node.js Developers
GlobalsDB: Its significance for Node.js DevelopersGlobalsDB: Its significance for Node.js Developers
GlobalsDB: Its significance for Node.js DevelopersRob Tweed
 
Node.js meetup at Palo Alto Networks Tel Aviv
Node.js meetup at Palo Alto Networks Tel AvivNode.js meetup at Palo Alto Networks Tel Aviv
Node.js meetup at Palo Alto Networks Tel AvivRon Perlmuter
 
Practical Thin Server Architecture With Dojo Peter Svensson
Practical Thin Server Architecture With Dojo Peter SvenssonPractical Thin Server Architecture With Dojo Peter Svensson
Practical Thin Server Architecture With Dojo Peter Svenssonrajivmordani
 
Dori Exterman, Considerations for choosing the parallel computing strategy th...
Dori Exterman, Considerations for choosing the parallel computing strategy th...Dori Exterman, Considerations for choosing the parallel computing strategy th...
Dori Exterman, Considerations for choosing the parallel computing strategy th...Sergey Platonov
 
Node.js Web Development.pdf
Node.js Web Development.pdfNode.js Web Development.pdf
Node.js Web Development.pdfSonia Simi
 
PHP – Faster And Cheaper. Scale Vertically with IBM i
PHP – Faster And Cheaper. Scale Vertically with IBM iPHP – Faster And Cheaper. Scale Vertically with IBM i
PHP – Faster And Cheaper. Scale Vertically with IBM iSam Hennessy
 
Difference between Node.js vs Java script
Difference between Node.js vs Java scriptDifference between Node.js vs Java script
Difference between Node.js vs Java scriptGhulamHussain799241
 

Ähnlich wie Scalability using Node.js (20)

NodeJS ecosystem
NodeJS ecosystemNodeJS ecosystem
NodeJS ecosystem
 
Beginners Node.js
Beginners Node.jsBeginners Node.js
Beginners Node.js
 
Node js internal
Node js internalNode js internal
Node js internal
 
Data stream processing and micro service architecture
Data stream processing and micro service architectureData stream processing and micro service architecture
Data stream processing and micro service architecture
 
8 Best Ways To Boost Node.js Performance Of Your Application!.pdf
8 Best Ways To Boost Node.js Performance Of Your Application!.pdf8 Best Ways To Boost Node.js Performance Of Your Application!.pdf
8 Best Ways To Boost Node.js Performance Of Your Application!.pdf
 
Understanding the Single Thread Event Loop
Understanding the Single Thread Event LoopUnderstanding the Single Thread Event Loop
Understanding the Single Thread Event Loop
 
Building Applications With the MEAN Stack
Building Applications With the MEAN StackBuilding Applications With the MEAN Stack
Building Applications With the MEAN Stack
 
NoSQL and ACID
NoSQL and ACIDNoSQL and ACID
NoSQL and ACID
 
Practical Thin Server Architecture With Dojo Sapo Codebits 2008
Practical Thin Server Architecture With Dojo Sapo Codebits 2008Practical Thin Server Architecture With Dojo Sapo Codebits 2008
Practical Thin Server Architecture With Dojo Sapo Codebits 2008
 
Architecting and Tuning IIB/eXtreme Scale for Maximum Performance and Reliabi...
Architecting and Tuning IIB/eXtreme Scale for Maximum Performance and Reliabi...Architecting and Tuning IIB/eXtreme Scale for Maximum Performance and Reliabi...
Architecting and Tuning IIB/eXtreme Scale for Maximum Performance and Reliabi...
 
GlobalsDB: Its significance for Node.js Developers
GlobalsDB: Its significance for Node.js DevelopersGlobalsDB: Its significance for Node.js Developers
GlobalsDB: Its significance for Node.js Developers
 
Node.js meetup at Palo Alto Networks Tel Aviv
Node.js meetup at Palo Alto Networks Tel AvivNode.js meetup at Palo Alto Networks Tel Aviv
Node.js meetup at Palo Alto Networks Tel Aviv
 
Practical Thin Server Architecture With Dojo Peter Svensson
Practical Thin Server Architecture With Dojo Peter SvenssonPractical Thin Server Architecture With Dojo Peter Svensson
Practical Thin Server Architecture With Dojo Peter Svensson
 
Dori Exterman, Considerations for choosing the parallel computing strategy th...
Dori Exterman, Considerations for choosing the parallel computing strategy th...Dori Exterman, Considerations for choosing the parallel computing strategy th...
Dori Exterman, Considerations for choosing the parallel computing strategy th...
 
Designing Scalable Applications
Designing Scalable ApplicationsDesigning Scalable Applications
Designing Scalable Applications
 
Introduction to Node.JS
Introduction to Node.JSIntroduction to Node.JS
Introduction to Node.JS
 
Node.js Web Development.pdf
Node.js Web Development.pdfNode.js Web Development.pdf
Node.js Web Development.pdf
 
PHP – Faster And Cheaper. Scale Vertically with IBM i
PHP – Faster And Cheaper. Scale Vertically with IBM iPHP – Faster And Cheaper. Scale Vertically with IBM i
PHP – Faster And Cheaper. Scale Vertically with IBM i
 
Going Serverless on AWS
Going Serverless on AWSGoing Serverless on AWS
Going Serverless on AWS
 
Difference between Node.js vs Java script
Difference between Node.js vs Java scriptDifference between Node.js vs Java script
Difference between Node.js vs Java script
 

Kürzlich hochgeladen

Russian Call Girls in Andheri Airport Mumbai WhatsApp 9167673311 💞 Full Nigh...
Russian Call Girls in Andheri Airport Mumbai WhatsApp  9167673311 💞 Full Nigh...Russian Call Girls in Andheri Airport Mumbai WhatsApp  9167673311 💞 Full Nigh...
Russian Call Girls in Andheri Airport Mumbai WhatsApp 9167673311 💞 Full Nigh...Pooja Nehwal
 
The byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxThe byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxShobhayan Kirtania
 
Arihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfArihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfchloefrazer622
 
The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13Steve Thomason
 
social pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajansocial pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajanpragatimahajan3
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Krashi Coaching
 
JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...
JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...
JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...anjaliyadav012327
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introductionMaksud Ahmed
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdfQucHHunhnh
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityGeoBlogs
 
Disha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdfDisha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdfchloefrazer622
 
9548086042 for call girls in Indira Nagar with room service
9548086042  for call girls in Indira Nagar  with room service9548086042  for call girls in Indira Nagar  with room service
9548086042 for call girls in Indira Nagar with room servicediscovermytutordmt
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104misteraugie
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Sapana Sha
 
Sports & Fitness Value Added Course FY..
Sports & Fitness Value Added Course FY..Sports & Fitness Value Added Course FY..
Sports & Fitness Value Added Course FY..Disha Kariya
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...fonyou31
 

Kürzlich hochgeladen (20)

Russian Call Girls in Andheri Airport Mumbai WhatsApp 9167673311 💞 Full Nigh...
Russian Call Girls in Andheri Airport Mumbai WhatsApp  9167673311 💞 Full Nigh...Russian Call Girls in Andheri Airport Mumbai WhatsApp  9167673311 💞 Full Nigh...
Russian Call Girls in Andheri Airport Mumbai WhatsApp 9167673311 💞 Full Nigh...
 
The byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxThe byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptx
 
Arihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfArihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdf
 
The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13
 
social pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajansocial pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajan
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
 
JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...
JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...
JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
 
Disha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdfDisha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdf
 
Advance Mobile Application Development class 07
Advance Mobile Application Development class 07Advance Mobile Application Development class 07
Advance Mobile Application Development class 07
 
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptxINDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
 
9548086042 for call girls in Indira Nagar with room service
9548086042  for call girls in Indira Nagar  with room service9548086042  for call girls in Indira Nagar  with room service
9548086042 for call girls in Indira Nagar with room service
 
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
 
Sports & Fitness Value Added Course FY..
Sports & Fitness Value Added Course FY..Sports & Fitness Value Added Course FY..
Sports & Fitness Value Added Course FY..
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
 

Scalability using Node.js

  • 1. Enhancing scalability using Node.js Team 15 - Enlighten Ratan Kadam - ratan.kadam@gmail.com Monil Shah - monil.shaah@gmail.com Akshay Jarandikar - akshayjaradikar@gmail.com Swapnil Joshi - swapnil.joshi1590@gmail.com
  • 2. Scalability  WhyWhat is scalability?  do we need scalability?  Current industry solutions - • Horizontal Scaling • Vertical Scaling • Multi-threading • Cloud Computing
  • 3. Horizontal vs Vertical Scaling Horizontal Scaling Adds extra identical boxes to server. Issues: • Requires Load balancer for managing connection. • Distribution of work within the units becomes overhead. • Additional investment. Vertical Scaling Increases the power of existing system by adding more powerful hardware. Issues: • Additional Investment • Single point of failure (SPOF)
  • 4. Multi-threading & Cloud Computing Multi-threading Issues: -High chances of deadlock if application is not designed properly. -Web-servers need to handle thousands of HTTP requests. This may cause many threads to wait for network operations. -For thousands of simultaneous requests, spawning threads for all processes would not achieve the desired scalability. Cloud Computing Issues: -Application architecture may or may not be suited for Cloud Computing -Application and Data Security in the Cloud -Lack of skilled resources; external training is required -If application is not designed properly for cloud platform; difficult to yield benefits -Again, substantial additional investment
  • 5. So the challenge…  The challenge is to scale the web application without major re-engineering and buying new hardware while keeping its architecture simple and easy to manage.
  • 6. Solution Important Features: Asynchronous in nature Event driven Non-blocking I/O
  • 7. Proposed Architecture Proxy Middleware, Entry point for real world access, Security, Caching Nginx Server Serves static content, Caching Load Balancer  connects multithreaded node.js instances and handles load distribution V8 JavaScript engine  handles compilation and execution of JavaScript Event loop  Handles events in program during execution of asynchronous operations.
  • 9. Server Pool Routing request based on content type
  • 10. Nginx server Nginx server stores static data in hierarchical cache. Thus reduces the latency. Also supports compression format to reduce response size.
  • 11. Node.js Workflow 3 core execution models: 1.Asynchronous request processing 2.Event driven programming 3.Non-blocking I/O
  • 12.  When request is made to server, instead of waiting for the request to complete, server continues to process other requests.  When request processing completes, the response is sent to caller using callback mechanism.  Event listener listens to the events and determines the flow of program.  There is an event loop that listens to events and then triggers callback functions.
  • 13. Non-blocking I/O  Non-blocking I/O supports the execution of system to be continued without waiting for I/O operations to complete.  This enables the architecture to have asynchronous request processing.
  • 14. Event loop Event loop is a programming construct that waits for and dispatches events in a program once their asynchronous operation completes.
  • 15. Node Load Balancer Working  Load balancer distributes the workload among available servers.  Load Balancer sends periodic heartbeat to check server status.  If one of the servers is down then the load balancer distributes the request queue among the available servers.
  • 16. V8 JavaScript Engine  When V8 receives script source code, it parses it to create abstract syntax tree.  Then this AST is fed into the byte code generator to produce byte code of the source.  V8 execution environment then interprets this byte code and with the help of JIT compiler it produces the native machine code that gets executed.  It uses techniques such as in-lining, elision of expensive runtime properties, and inline caching are used for optimization
  • 17. CASE STUDY PayPal & eBay with Node.Js Changes from development perspective - The development time was almost half that with fewer people. Number of files that were constructed reduced to 40%. The number of lines of code was reduced by 33%. Changes from performance perspective The number of requests per second is doubled compared to Java application.  The response time is decreased by 35% compared to Java application.
  • 19. Advantages 1. Asynchronous 2. Event driven programming 3. Multithreading 4. Scalability 5. High throughput 6. High Performance 7. Cost effective 8.Minimum Latency 9. Efficient Resource Consumption 10. Set of Standard Libraries
  • 20. Conclusion Scalability is next decade challenge for enterprise community as more than 7.1 billion people are using internet. Most of the vendors use solutions like Horizontal, vertical & single threaded node.js. However, these single threaded architectures may not be able to fix the next generation scalable issues. Solution to the problem is defined in our proposed architecture – multithreaded node.js where multiple node.js instances are bind to the fixed number of threads to boost the power of existing Node JS. So multithreaded node.js can be a cost effective, software based scalable solution for next decade challenges for Enterprise industries.
  • 21. References  Web application performance and scalability http://www.webforefront.com/performance/scaling101.html  Node.js at PayPal https://www.paypal-engineering.com/2013/11/22/node-js-at-paypal/  Nginx http://www.aosabook.org/en/nginx.html  Ebay’s first node.js application http://www.ebaytechblog.com/2013/05/17/how-we-built-ebays-first-node- js-application/#.VHLrNIvF9hw  Node.js architecture diagram http://blog.cloudfoundry.org/2012/06/27/future-proofing-your-apps-cloud- foundry-and-node-js/

Hinweis der Redaktion

  1. Web application performance and scalability http://www.webforefront.com/performance/scaling101.html Node.js at PayPal https://www.paypal-engineering.com/2013/11/22/node-js-at-paypal/ Nginx http://www.aosabook.org/en/nginx.html http://www.ebaytechblog.com/2013/05/17/how-we-built-ebays-first-node-js-application/#.VHLrNIvF9hw Node.js architecture diagram http://blog.cloudfoundry.org/2012/06/27/future-proofing-your-apps-cloud-foundry-and-node-js/