SlideShare a Scribd company logo
1 of 10
Node.js:
middleware proxy
Ilya Starostin
Software Engineer
Introducing (How it was)
Azure Web Site
CPU-Intensive worker
role
Web site file system
DB
Introducing (Step 2: Scalable storage)
Azure Web Site
CPU-Intensive worker
role
Web site file system
DB
Introducing (Step 3: Access securing)
Azure Web Site
CPU-Intensive worker
role
Web site file system
DB
Non-authorized user
Authorized user
Middleware
proxy
x
Why node.js ?
• Fast for development and implementation
• Low-cost solution
• Horizontal and vertical scaling
• High-flexibility
• High-performance (…?)
DB
Load balancer
Performance (theoretical)
• Working in a one thread
• Creation of a 2000 blank threads can take
up than 3.7 sec (Windows 8)
• It takes ~50 mb RAM
• IO operations shouldn’t block main thread
• Proxing of traffic from storage to client works
almost at operation-system layer (when properly
implemented) – through piping from source
thread to another.
Message loop picture
Performance (practical 5kb)
Testing with Apache AB console utill
1000 tries in 50 threads
File size 5kb
• Storage:
• Proxy
Connection Times (ms)
min avg max
Connect: 115 120 3082
Processin
g:
127 5818 5964
Total: 242 5938 9046
Connnection Times (ms)
min avg max
Connect: 115 124 3142
Processin
g:
244 6002 8865
Total: 359 6126 12007
4800
5000
5200
5400
5600
5800
6000
6200
1 2
Storagems Proxy
Diff:
Min value: 33%
Av. Value: 3.1%
Max value: 25%
Performance (practical 500kb)
Testing with Apache AB console utill
100 tries in 10 threads
File size 535kb
• Storage:
• Proxy
Storagems Proxy
Diff:
Min value: <1%
Av. Value: 3%
Max value: <1%
Connnection Times (ms)
min avg max
Connect: 116 148 3100
Processin
g:
950 2063 1318
Total: 1066 2211 4418
Connnection Times (ms)
min avg max
Connect: 115 118 127
Processin
g:
965 1694 4334
Total: 1080 1812 4461
634
834
1034
1234
1434
1634
1834
2034
2234
2434
1 2
Code
Thanks!
Questions?
Thoughts?

More Related Content

What's hot

Running on Elastic Beanstalk
Running on Elastic BeanstalkRunning on Elastic Beanstalk
Running on Elastic Beanstalk
Alex Verdyan
 
Load testing with gatling
Load testing with gatlingLoad testing with gatling
Load testing with gatling
Chris Birchall
 
Application of nodejs in epsilon mobile
Application of nodejs in epsilon mobileApplication of nodejs in epsilon mobile
Application of nodejs in epsilon mobile
Tony Vo
 

What's hot (20)

Node js
Node jsNode js
Node js
 
Introduction to AJAX
Introduction to AJAXIntroduction to AJAX
Introduction to AJAX
 
Running on Elastic Beanstalk
Running on Elastic BeanstalkRunning on Elastic Beanstalk
Running on Elastic Beanstalk
 
Windows Azure Storage – Architecture View
Windows Azure Storage – Architecture ViewWindows Azure Storage – Architecture View
Windows Azure Storage – Architecture View
 
Windows Azure Virtual Machines
Windows Azure Virtual MachinesWindows Azure Virtual Machines
Windows Azure Virtual Machines
 
Azure storage
Azure storageAzure storage
Azure storage
 
Azure Recovery Services
Azure Recovery ServicesAzure Recovery Services
Azure Recovery Services
 
Improve aws withproxysql
Improve aws withproxysqlImprove aws withproxysql
Improve aws withproxysql
 
Windows Azure Caching
Windows Azure CachingWindows Azure Caching
Windows Azure Caching
 
Configuring MongoDB HA Replica Set on AWS EC2
Configuring MongoDB HA Replica Set on AWS EC2Configuring MongoDB HA Replica Set on AWS EC2
Configuring MongoDB HA Replica Set on AWS EC2
 
Windows Azure Drive
Windows Azure DriveWindows Azure Drive
Windows Azure Drive
 
Scalable server component using NodeJS & ExpressJS
Scalable server component using NodeJS & ExpressJSScalable server component using NodeJS & ExpressJS
Scalable server component using NodeJS & ExpressJS
 
Data backup and Disaster recovery with AWS
Data backup and Disaster recovery with AWSData backup and Disaster recovery with AWS
Data backup and Disaster recovery with AWS
 
Load testing with gatling
Load testing with gatlingLoad testing with gatling
Load testing with gatling
 
Sql saturday azure storage by Anton Vidishchev
Sql saturday azure storage by Anton VidishchevSql saturday azure storage by Anton Vidishchev
Sql saturday azure storage by Anton Vidishchev
 
MongoDB WiredTiger Internals
MongoDB WiredTiger InternalsMongoDB WiredTiger Internals
MongoDB WiredTiger Internals
 
Application of nodejs in epsilon mobile
Application of nodejs in epsilon mobileApplication of nodejs in epsilon mobile
Application of nodejs in epsilon mobile
 
Azure IaaS
Azure IaaSAzure IaaS
Azure IaaS
 
Windows Azure Virtual Machines And Virtual Networks
Windows Azure Virtual Machines And Virtual NetworksWindows Azure Virtual Machines And Virtual Networks
Windows Azure Virtual Machines And Virtual Networks
 
ECS위에 Log Server 구축하기
ECS위에 Log Server 구축하기ECS위에 Log Server 구축하기
ECS위에 Log Server 구축하기
 

Viewers also liked

Three Challenges in Reliable Data Transport over Heterogeneous ...
Three Challenges in Reliable Data Transport over Heterogeneous ...Three Challenges in Reliable Data Transport over Heterogeneous ...
Three Challenges in Reliable Data Transport over Heterogeneous ...
Videoguy
 
Materials management & inventory management
Materials management & inventory managementMaterials management & inventory management
Materials management & inventory management
NMIMS ASSIGNMENTS HELP
 

Viewers also liked (20)

Three Challenges in Reliable Data Transport over Heterogeneous ...
Three Challenges in Reliable Data Transport over Heterogeneous ...Three Challenges in Reliable Data Transport over Heterogeneous ...
Three Challenges in Reliable Data Transport over Heterogeneous ...
 
Invetory management
Invetory managementInvetory management
Invetory management
 
Mba isbm case study answers & solutions 3
Mba isbm case study answers & solutions 3Mba isbm case study answers & solutions 3
Mba isbm case study answers & solutions 3
 
Human resource management (3)
Human resource management (3)Human resource management (3)
Human resource management (3)
 
Best practices in business
Best practices in businessBest practices in business
Best practices in business
 
Financial management 250613
Financial management 250613Financial management 250613
Financial management 250613
 
Examination paper international business management & globall marketing mana...
Examination paper  international business management & globall marketing mana...Examination paper  international business management & globall marketing mana...
Examination paper international business management & globall marketing mana...
 
Mba iibm case study solutions & multiple answers
Mba iibm case study solutions & multiple answersMba iibm case study solutions & multiple answers
Mba iibm case study solutions & multiple answers
 
Training the Trainer - Module 6
Training the Trainer - Module 6Training the Trainer - Module 6
Training the Trainer - Module 6
 
Best practices in business
Best practices in businessBest practices in business
Best practices in business
 
Business management (1)
Business management (1)Business management (1)
Business management (1)
 
General management2
General management2General management2
General management2
 
Managerial economics
Managerial economicsManagerial economics
Managerial economics
 
Examination paper six sigma green belt & six sigma black belt
Examination paper six sigma green belt & six sigma black beltExamination paper six sigma green belt & six sigma black belt
Examination paper six sigma green belt & six sigma black belt
 
seo dersi
seo dersiseo dersi
seo dersi
 
Fol
FolFol
Fol
 
Emba iibm case study solutions & multiple answers 1
Emba iibm case study solutions & multiple answers 1Emba iibm case study solutions & multiple answers 1
Emba iibm case study solutions & multiple answers 1
 
Find A List of Local Non denominational churches in South Africa
Find A List of Local Non denominational churches in South AfricaFind A List of Local Non denominational churches in South Africa
Find A List of Local Non denominational churches in South Africa
 
Materials management & inventory management
Materials management & inventory managementMaterials management & inventory management
Materials management & inventory management
 
Managerial economics 250613
Managerial economics 250613Managerial economics 250613
Managerial economics 250613
 

Similar to Node proxy

Scalable Web Solutions - Use Case: Regulatory Reform In Vietnam On eZ Publish...
Scalable Web Solutions - Use Case: Regulatory Reform In Vietnam On eZ Publish...Scalable Web Solutions - Use Case: Regulatory Reform In Vietnam On eZ Publish...
Scalable Web Solutions - Use Case: Regulatory Reform In Vietnam On eZ Publish...
Ivo Lukač
 
Building Scalable .NET Web Applications
Building Scalable .NET Web ApplicationsBuilding Scalable .NET Web Applications
Building Scalable .NET Web Applications
Buu Nguyen
 
From 0 to 60 million users scaling with microservices and multi cloud archite...
From 0 to 60 million users scaling with microservices and multi cloud archite...From 0 to 60 million users scaling with microservices and multi cloud archite...
From 0 to 60 million users scaling with microservices and multi cloud archite...
JAXLondon_Conference
 

Similar to Node proxy (20)

Scalable Web Solutions - Use Case: Regulatory Reform In Vietnam On eZ Publish...
Scalable Web Solutions - Use Case: Regulatory Reform In Vietnam On eZ Publish...Scalable Web Solutions - Use Case: Regulatory Reform In Vietnam On eZ Publish...
Scalable Web Solutions - Use Case: Regulatory Reform In Vietnam On eZ Publish...
 
DjangoCon 2010 Scaling Disqus
DjangoCon 2010 Scaling DisqusDjangoCon 2010 Scaling Disqus
DjangoCon 2010 Scaling Disqus
 
Scaling Wix with microservices architecture and multi-cloud platforms - Reve...
 Scaling Wix with microservices architecture and multi-cloud platforms - Reve... Scaling Wix with microservices architecture and multi-cloud platforms - Reve...
Scaling Wix with microservices architecture and multi-cloud platforms - Reve...
 
VMworld 2013: VMware Mirage Storage and Network Deduplication, DEMYSTIFIED
VMworld 2013: VMware Mirage Storage and Network Deduplication, DEMYSTIFIED VMworld 2013: VMware Mirage Storage and Network Deduplication, DEMYSTIFIED
VMworld 2013: VMware Mirage Storage and Network Deduplication, DEMYSTIFIED
 
My Sql Performance In A Cloud
My Sql Performance In A CloudMy Sql Performance In A Cloud
My Sql Performance In A Cloud
 
Scaling wix with microservices architecture devoxx London 2015
Scaling wix with microservices architecture devoxx London 2015Scaling wix with microservices architecture devoxx London 2015
Scaling wix with microservices architecture devoxx London 2015
 
Building Scalable .NET Web Applications
Building Scalable .NET Web ApplicationsBuilding Scalable .NET Web Applications
Building Scalable .NET Web Applications
 
From 0 to 60 million users scaling with microservices and multi cloud archite...
From 0 to 60 million users scaling with microservices and multi cloud archite...From 0 to 60 million users scaling with microservices and multi cloud archite...
From 0 to 60 million users scaling with microservices and multi cloud archite...
 
Scaling wix with microservices and multi cloud - 2015
Scaling wix with microservices and multi cloud - 2015Scaling wix with microservices and multi cloud - 2015
Scaling wix with microservices and multi cloud - 2015
 
NodeJS ecosystem
NodeJS ecosystemNodeJS ecosystem
NodeJS ecosystem
 
Speeding Up Atlas Deep Learning Platform with Alluxio + Fluid
Speeding Up Atlas Deep Learning Platform with Alluxio + FluidSpeeding Up Atlas Deep Learning Platform with Alluxio + Fluid
Speeding Up Atlas Deep Learning Platform with Alluxio + Fluid
 
Scaling wix with microservices architecture jax london-2015
Scaling wix with microservices architecture jax london-2015Scaling wix with microservices architecture jax london-2015
Scaling wix with microservices architecture jax london-2015
 
Building Highly Scalable Java Applications on Windows Azure - JavaOne S313978
Building Highly Scalable Java Applications on Windows Azure - JavaOne S313978Building Highly Scalable Java Applications on Windows Azure - JavaOne S313978
Building Highly Scalable Java Applications on Windows Azure - JavaOne S313978
 
Yaroslav Nedashkovsky "How to manage hundreds of pipelines for processing da...
Yaroslav Nedashkovsky  "How to manage hundreds of pipelines for processing da...Yaroslav Nedashkovsky  "How to manage hundreds of pipelines for processing da...
Yaroslav Nedashkovsky "How to manage hundreds of pipelines for processing da...
 
Azure: Lessons From The Field
Azure: Lessons From The FieldAzure: Lessons From The Field
Azure: Lessons From The Field
 
Building Cloud-Native Applications with Microsoft Windows Azure
Building Cloud-Native Applications with Microsoft Windows AzureBuilding Cloud-Native Applications with Microsoft Windows Azure
Building Cloud-Native Applications with Microsoft Windows Azure
 
Play framework productivity formula
Play framework   productivity formula Play framework   productivity formula
Play framework productivity formula
 
Life In The FastLane: Full Speed XPages
Life In The FastLane: Full Speed XPagesLife In The FastLane: Full Speed XPages
Life In The FastLane: Full Speed XPages
 
Snowflake Datawarehouse Architecturing
Snowflake Datawarehouse ArchitecturingSnowflake Datawarehouse Architecturing
Snowflake Datawarehouse Architecturing
 
slides (PPT)
slides (PPT)slides (PPT)
slides (PPT)
 

Recently uploaded

Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024
Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024
Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024
VictoriaMetrics
 
%+27788225528 love spells in Toronto Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Toronto Psychic Readings, Attraction spells,Brin...%+27788225528 love spells in Toronto Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Toronto Psychic Readings, Attraction spells,Brin...
masabamasaba
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
Health
 
%+27788225528 love spells in Huntington Beach Psychic Readings, Attraction sp...
%+27788225528 love spells in Huntington Beach Psychic Readings, Attraction sp...%+27788225528 love spells in Huntington Beach Psychic Readings, Attraction sp...
%+27788225528 love spells in Huntington Beach Psychic Readings, Attraction sp...
masabamasaba
 
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
masabamasaba
 
Abortion Pills In Pretoria ](+27832195400*)[ 🏥 Women's Abortion Clinic In Pre...
Abortion Pills In Pretoria ](+27832195400*)[ 🏥 Women's Abortion Clinic In Pre...Abortion Pills In Pretoria ](+27832195400*)[ 🏥 Women's Abortion Clinic In Pre...
Abortion Pills In Pretoria ](+27832195400*)[ 🏥 Women's Abortion Clinic In Pre...
Medical / Health Care (+971588192166) Mifepristone and Misoprostol tablets 200mg
 

Recently uploaded (20)

Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
Direct Style Effect Systems -The Print[A] Example- A Comprehension AidDirect Style Effect Systems -The Print[A] Example- A Comprehension Aid
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
 
Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024
Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024
Large-scale Logging Made Easy: Meetup at Deutsche Bank 2024
 
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
 
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
 
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
 
%+27788225528 love spells in Toronto Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Toronto Psychic Readings, Attraction spells,Brin...%+27788225528 love spells in Toronto Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Toronto Psychic Readings, Attraction spells,Brin...
 
Devoxx UK 2024 - Going serverless with Quarkus, GraalVM native images and AWS...
Devoxx UK 2024 - Going serverless with Quarkus, GraalVM native images and AWS...Devoxx UK 2024 - Going serverless with Quarkus, GraalVM native images and AWS...
Devoxx UK 2024 - Going serverless with Quarkus, GraalVM native images and AWS...
 
%in Rustenburg+277-882-255-28 abortion pills for sale in Rustenburg
%in Rustenburg+277-882-255-28 abortion pills for sale in Rustenburg%in Rustenburg+277-882-255-28 abortion pills for sale in Rustenburg
%in Rustenburg+277-882-255-28 abortion pills for sale in Rustenburg
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
 
WSO2CON 2024 - How to Run a Security Program
WSO2CON 2024 - How to Run a Security ProgramWSO2CON 2024 - How to Run a Security Program
WSO2CON 2024 - How to Run a Security Program
 
WSO2Con204 - Hard Rock Presentation - Keynote
WSO2Con204 - Hard Rock Presentation - KeynoteWSO2Con204 - Hard Rock Presentation - Keynote
WSO2Con204 - Hard Rock Presentation - Keynote
 
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park %in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
 
%+27788225528 love spells in Huntington Beach Psychic Readings, Attraction sp...
%+27788225528 love spells in Huntington Beach Psychic Readings, Attraction sp...%+27788225528 love spells in Huntington Beach Psychic Readings, Attraction sp...
%+27788225528 love spells in Huntington Beach Psychic Readings, Attraction sp...
 
WSO2CON2024 - It's time to go Platformless
WSO2CON2024 - It's time to go PlatformlessWSO2CON2024 - It's time to go Platformless
WSO2CON2024 - It's time to go Platformless
 
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
 
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
 
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
 
AI & Machine Learning Presentation Template
AI & Machine Learning Presentation TemplateAI & Machine Learning Presentation Template
AI & Machine Learning Presentation Template
 
WSO2CON 2024 - Does Open Source Still Matter?
WSO2CON 2024 - Does Open Source Still Matter?WSO2CON 2024 - Does Open Source Still Matter?
WSO2CON 2024 - Does Open Source Still Matter?
 
Abortion Pills In Pretoria ](+27832195400*)[ 🏥 Women's Abortion Clinic In Pre...
Abortion Pills In Pretoria ](+27832195400*)[ 🏥 Women's Abortion Clinic In Pre...Abortion Pills In Pretoria ](+27832195400*)[ 🏥 Women's Abortion Clinic In Pre...
Abortion Pills In Pretoria ](+27832195400*)[ 🏥 Women's Abortion Clinic In Pre...
 

Node proxy

  • 2. Introducing (How it was) Azure Web Site CPU-Intensive worker role Web site file system DB
  • 3. Introducing (Step 2: Scalable storage) Azure Web Site CPU-Intensive worker role Web site file system DB
  • 4. Introducing (Step 3: Access securing) Azure Web Site CPU-Intensive worker role Web site file system DB Non-authorized user Authorized user Middleware proxy x
  • 5. Why node.js ? • Fast for development and implementation • Low-cost solution • Horizontal and vertical scaling • High-flexibility • High-performance (…?) DB Load balancer
  • 6. Performance (theoretical) • Working in a one thread • Creation of a 2000 blank threads can take up than 3.7 sec (Windows 8) • It takes ~50 mb RAM • IO operations shouldn’t block main thread • Proxing of traffic from storage to client works almost at operation-system layer (when properly implemented) – through piping from source thread to another. Message loop picture
  • 7. Performance (practical 5kb) Testing with Apache AB console utill 1000 tries in 50 threads File size 5kb • Storage: • Proxy Connection Times (ms) min avg max Connect: 115 120 3082 Processin g: 127 5818 5964 Total: 242 5938 9046 Connnection Times (ms) min avg max Connect: 115 124 3142 Processin g: 244 6002 8865 Total: 359 6126 12007 4800 5000 5200 5400 5600 5800 6000 6200 1 2 Storagems Proxy Diff: Min value: 33% Av. Value: 3.1% Max value: 25%
  • 8. Performance (practical 500kb) Testing with Apache AB console utill 100 tries in 10 threads File size 535kb • Storage: • Proxy Storagems Proxy Diff: Min value: <1% Av. Value: 3% Max value: <1% Connnection Times (ms) min avg max Connect: 116 148 3100 Processin g: 950 2063 1318 Total: 1066 2211 4418 Connnection Times (ms) min avg max Connect: 115 118 127 Processin g: 965 1694 4334 Total: 1080 1812 4461 634 834 1034 1234 1434 1634 1834 2034 2234 2434 1 2