Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
High Performance Architecture Patterns
Search
Celso Crivelaro
May 12, 2016
Technology
520
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
High Performance Architecture Patterns
Celso Crivelaro
May 12, 2016
Transcript
74 slides
High Performance Architecture Patterns Celso Crivelaro @celsocrivelaro
$ whoami > Celso Crivelaro - Engineer and MSc in
Computer Engineering - Dev Ruby / Python / Java @celsocrivelaro http://crivelaro.me
None
None
SMTP Locaweb - Transaction email platform - Fast and high
quality email sending - Live reports - Integration by SMTP Protocol and HTTP API - 2,5 Millions of messages per day - + 2 years
None
Platforms
None
None
None
None
High Availability
Resource Consumption
None
Disk Memory Band- width Processor time Logs GC Open Connections
Deadlocks Stop all disk activities Swap Slowness Services stop responding Queues Amount Workers Slowness
Integrations
Integrations always fails!
Integration Fails always Internal External DB API Storage Network API
ISP Hop Cloud
Map hidden integrations E.g. DNS
Fail Fast
Failing Fast reduces transient errors
Timeouts
Never trust in default timeouts
Threads Timeouts to get rid of deadlocls Internal Little timeout
External Depends: The least possible
Retry
1 2 3 5 8 n Fibonacci Proportion ...
Isolate Critical Components
Panel / API Painel Web Internal API - HTTP Resources
Connection Pool App Server Business Rules Integrations
App Internal API App Panel Painel Web API - HTTP
Resources Conn. Pool App Server Business Rules Integrations Resources Conn. Pool App Server Business Rules Integrations
Less Components == Less Problems
None
Redundancy
Health Check
None
None
Scalability
CAP Theorem
Availability Consistency Tolerance to network partition
Availability Consistency Partition Tolerance to network partition whether system is
available or not
Availability Consistency Tolerance to network partition Same data in all
nodes
Availability Consistency Tolerance to network partition Tolerante when a network
fails
Availability Consistency Partition Tolerance Postgres
Availability Consistency Partition Tolerance DNS
Availability Consistency Partition Tolerance Protocols
Evaluate which one is acceptable to your platform
Pool of Resources
App Connection Resource Connection Connection Connection Connection
Controlled Timeouts Controlled Resource Consumption Avoid opening/closing connections overhead
Cache
Make your data closer to your app
When use cache App API DB
Default Cache Strategy App Cache Source 1 2 3
Hot Cache Strategy App Cache Source 2 1
Load Balacing
LB App App App App
Load Balance Strategy matters!
Decoupled Architecture
Slow Processing Fast processing Asynchronous Processing Authentication Message Transformation MTA
Providers User Message Persistence Consolidation
Background jobs Messaging frameworks
How to discover bottlenecks?
Test your limits... Load Test Stress Test Peak Test
Telemetry
None
Grafana + InfluxDB
Other scalabity patterns
Indexes
Sharding
References
None
None
None
http://use-the-index-luke.com
None
Thank you! Celso Crivelaro @celsocrivelaro
[email protected]
More Decks by Celso Crivelaro
See All by Celso Crivelaro
Sistemas de Recomendação
celsocrivelaro
2
250
Big Data para Gerentes de Projetos
celsocrivelaro
0
80
FileSystems em Ruby com FUSE
celsocrivelaro
2
79
Padrões e Boas Práticas de Teste de Tela
celsocrivelaro
0
470
Projeto de APIs
celsocrivelaro
0
190
Testing Network Conditions with ToxiProxy
celsocrivelaro
1
420
Testing Network Conditions with ToxiProxy
celsocrivelaro
0
96
Actor Model in Ruby
celsocrivelaro
0
280
Separando as regras de negócios do Rails
celsocrivelaro
0
210
Other Decks in Technology
See All in Technology
AI対話型分析を作成し、リリースするまでの話 / The Road to Release: Buiding AI Conversational Analytics
yappli_developers
0
170
飯から始まるデータエンジニア
sansantech
PRO
0
100
Oracle Base Database Service 技術詳細
oracle4engineer
PRO
17
120k
cdkdがどんだけ早いか、実際に動かして見てみよう
smt7174
1
130
エンタープライズ事業未経験のデータ屋、 AI時代にN回撃沈する.pdf
ryoskdara_
0
150
高品質と高スピードを支える品質のシフトレフトのアプローチ
goyoki
4
1.6k
あの日、見つかっていなかったらどうなっていたか
kazzpapa3
2
260
異夢同船〜異なる夢でも同じ船でなんとかする〜
fortegp05
1
520
「任されビリティ」で引き受けて「よしなりてぃ」に頼らず任せる / Accept tasks with "makasarebility" and hand them over without relying on "yoshinarily"
pauli
1
780
これからのデータエンジニアの役割について考える / Rethinking the Role of Data Engineers in the AI Era
okiyuki99
1
540
[関西Kaggler会 20261113] 続・コミュニティコンペのススメ
nejumi
0
150
人間+AIを「チーム」としてプロセスを再設計する
littlehands
4
3.5k
Featured
See All Featured
Docker and Python
trallard
47
4.3k
More Than Pixels: Becoming A User Experience Designer
marktimemedia
3
630
Marketing to machines
jonoalderson
1
6k
A Soul's Torment
seathinner
9
3.9k
Exploring anti-patterns in Rails
aemeredith
4
570
Information Architects: The Missing Link in Design Systems
soysaucechin
1
1.3k
The Power of CSS Pseudo Elements
geoffreycrofte
82
6.6k
HDC tutorial
michielstock
2
1k
Crafting Experiences
bethany
1
440
Kristin Tynski - Automating Marketing Tasks With AI
techseoconnect
PRO
0
590
Intergalactic Javascript Robots from Outer Space
tanoku
273
28k
Making the Leap to Tech Lead
cromwellryan
135
10k