Lock in $30 Savings on PRO—Offer Ends Soon! ⏳
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Erlang u praksi
Search
Saša Jurić
November 24, 2012
Programming
1
350
Erlang u praksi
WebCamp Zagreb, 2012
Saša Jurić
November 24, 2012
Tweet
Share
More Decks by Saša Jurić
See All by Saša Jurić
Such Great Heights, Code BEAM Lite, Amsterdam 2018
sasajuric
0
160
Simplifying systems with Elixir - Belgrade
sasajuric
3
440
Simplifying systems with Elixir
sasajuric
2
560
Metagrokking Elixir
sasajuric
4
280
Solid Ground
sasajuric
15
1.2k
Solid Ground
sasajuric
3
840
Elixir - valentine edition
sasajuric
0
120
What's the fuss about Phoenix?
sasajuric
2
1k
Phoenix
sasajuric
1
210
Other Decks in Programming
See All in Programming
社内活動の取り組み紹介 ~ スリーシェイクでこんな取り組みしてます ~
bells17
0
290
PipeCDの歩き方
kuro_kurorrr
3
130
React CompilerとFine Grained Reactivityと宣言的UIのこれから / The next chapter of declarative UI
ssssota
7
2.6k
「天気予報があなたに届けられるまで」 - NIFTY Tech Talk #22
niftycorp
PRO
0
130
watsonx.ai Dojo #4 生成AIを使ったアプリ開発、応用編
oniak3ibm
PRO
1
250
Jakarta EE meets AI
ivargrimstad
0
230
OnlineTestConf: Test Automation Friend or Foe
maaretp
0
130
Laravel や Symfony で手っ取り早く OpenAPI のドキュメントを作成する
azuki
2
140
C++でシェーダを書く
fadis
6
4.2k
気をつけたい!Desktop対応で陥りやすい罠とその対策
goto_tsl
0
140
Jakarta EE meets AI
ivargrimstad
0
1.1k
Micro Frontends Unmasked Opportunities, Challenges, Alternatives
manfredsteyer
PRO
0
170
Featured
See All Featured
How to Think Like a Performance Engineer
csswizardry
20
1.1k
The MySQL Ecosystem @ GitHub 2015
samlambert
250
12k
Automating Front-end Workflow
addyosmani
1366
200k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
356
29k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
44
2.2k
A Modern Web Designer's Workflow
chriscoyier
693
190k
How To Stay Up To Date on Web Technology
chriscoyier
789
250k
BBQ
matthewcrist
85
9.3k
Writing Fast Ruby
sferik
627
61k
Code Reviewing Like a Champion
maltzj
520
39k
[RailsConf 2023] Rails as a piece of cake
palkan
52
5k
Embracing the Ebb and Flow
colly
84
4.5k
Transcript
Erlang u praksi
[email protected]
Korisnici
Platforma • jezik • framework (OTP) • runtime
Konkurentnost spawn(...)
Konkurentnost scheduler spawn(...)
Konkurentnost scheduler CPU scheduler CPU scheduler CPU scheduler CPU spawn(...)
Komunikacija P1 poruka P2 P2 = spawn(...), P2 ! Poruka
receive Poruka1 -> ... Poruka2 -> ... ... end
Komunikacija P1 poruka odgovor P2 P2 ! {self(), ...}, receive
... receive {Sender, ...} -> ... Sender ! Response end
Stanje A = 5, A = A + 1
Stanje S f(Stanje) -> Poruka = receive ... end, NovoStanje
= f2(Poruka, Stanje), f(NovoStanje).
Stanje {set, ...} {get, ...} P S f(Stanje) -> Poruka
= receive ... end, NovoStanje = f2(Poruka, Stanje), f(NovoStanje).
Actor model actor actor actor actor actor actor
Supervisor S W
Supervisor W S S S W W W S W
W W W
Http server http_server request_1 request_n request response response
Http server http_server stanje request_1 request_n request response response
Push server korisnik_1 korisnik_2 korisnik_n kanal_2 kanal_1 podaci podaci
Push server <= 3000 paralelnih korisnika ≈ 30 kanala >
2000 requesta u sekundi
Erlang • actor model • supervisor • distribuiranost • mnesia
• hot code swapping • interoperabilnost • alati
Primjena • server • skalabilnost • dinamički requesti
Linkovi • Why Erlang? • Programming Erlang • Learn You
Some Erlang for Great Good! • Erlang and OTP in Action • A History of Erlang • erlang.org • Erlang Programming Group