Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Real-time Communications with SignalR
Search
Shravan Kumar Kasagoni
May 19, 2015
Technology
0
47
Real-time Communications with SignalR
Shravan Kumar Kasagoni
May 19, 2015
Tweet
Share
More Decks by Shravan Kumar Kasagoni
See All by Shravan Kumar Kasagoni
Functional Programming in JavaScript
shravan
0
35
ASP.NET Core – Deep Dive on Building a Real Website
shravan
0
38
Cross-Platform Mobile Development using Visual Studio and Xamarin
shravan
1
38
Angular 2 with TypeScript
shravan
1
160
Building Next Generation Web Apps and Services using ASP.NET 5
shravan
0
88
Writing Application-Scale JavaScript:TypeScript
shravan
0
54
Running, improving and maintaining a site in the real world
shravan
0
35
Open Web Interface for .NET
shravan
0
140
Glance at Visual Studio 2013 ASP.NET and Web Tools 2013
shravan
0
72
Other Decks in Technology
See All in Technology
バックエンドエンジニアのためのフロントエンド入門 #devsumiC
panda_program
16
6.5k
技術的負債解消の取り組みと専門チームのお話 #技術的負債_Findy
bengo4com
1
1.2k
Datadog APM におけるトレース収集の流れ及び Retention Filters のはなし / datadog-apm-trace-retention-filters
k6s4i53rx
0
320
MC906491 を見据えた Microsoft Entra Connect アップグレード対応
tamaiyutaro
1
480
データ資産をシームレスに伝達するためのイベント駆動型アーキテクチャ
kakehashi
PRO
2
230
管理者しか知らないOutlookの裏側のAIを覗く#AzureTravelers
hirotomotaguchi
2
240
[2025-02-07]生成AIで変える問い合わせの未来 〜チームグローバル化の香りを添えて〜
tosite
1
290
滅・サービスクラス🔥 / Destruction Service Class
sinsoku
6
1.5k
APIファーストで実現する運用性の高い IoT プラットフォーム: SORACOMのアプローチ
soracom
PRO
0
240
Ask! NIKKEIの運用基盤と改善に向けた取り組み / NIKKEI TECH TALK #30
kaitomajima
1
450
WAF に頼りすぎない AWS WAF 運用術 meguro sec #1
izzii
0
460
転生CISOサバイバル・ガイド / CISO Career Transition Survival Guide
kanny
3
410
Featured
See All Featured
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
175
51k
Done Done
chrislema
182
16k
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
33
2.1k
The Cost Of JavaScript in 2023
addyosmani
47
7.3k
Building a Scalable Design System with Sketch
lauravandoore
460
33k
Thoughts on Productivity
jonyablonski
69
4.5k
Building Better People: How to give real-time feedback that sticks.
wjessup
366
19k
Producing Creativity
orderedlist
PRO
343
39k
Designing for Performance
lara
604
68k
Automating Front-end Workflow
addyosmani
1367
200k
Optimising Largest Contentful Paint
csswizardry
34
3.1k
Unsuck your backbone
ammeep
669
57k
Transcript
Real-time Communications with SignalR Shravan Kumar Kasagoni
Agenda 1) Introduction to the real-time web 2) ASP .NET
SignalR 3) Building a real-time
Real-time Application? Real-time functionality is the ability to have server
code push content to connected clients instantly as it becomes available, rather than having the server wait for a client to request new data.
Without real-time
With real-time
Why Real-time? Users want the latest info, NOW!
Show Me Some Examples Twitter, Facebook, Mail - live
searches/updates Stock streamers Auctions Interactive games Live Scores Collaborative apps (google docs, office web apps) Live user analytics (live graphs)
How to build real-time web apps?
HTTP is an old beast… Never designed for real-time communications
Web is all about request-response Web is stateless
How to do real-time in web?
Periodic polling Poll from time to time using Ajax
Delay in communication due to polling interval Wastes bandwidth & latency Server Client Polling interval
Long polling Poll but doesn’t respond until there's data
Poll again after data received or after the connection times out Consumes server & threads & connection resources Server Client
Forever Frame Server tells client that response is chucked
Client keeps connection open until server closes it Server pushed data to the client followed by \0 Consumes server threads Server Client
HTML5 Web sockets Extension to HTTP Provides raw
sockets over HTTP Full-duplex Traverses proxies It's still a working draft Not every proxy server supports it Not every web server supports it Not every browser supports it They are raw sockets!
too many options
None
Basically…
Introducing SignalR • Abstraction over transports • Events instead of
task/async • Connection management • Broadcast or target specific client
What does SignalR do? • Client to Server persistent connection
over HTTP • Easily build multi-user, real-time web applications • Auto-negotiates transport
SignalR Fallback Long Polling Forever Frames Server Sent Events Web
Sockets
What does SignalR do? • Allows server-to-client push and RPC
• Built async to scale to 1000’s of connections • Scale out with Service Bus, SQL Server & Redis • Open Source on GitHub
Backplane SignalR Backplanes Load balancing via a common transport mechanism
Thank You