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
Introduction to RethinkDB: 1KE Meetup
Search
Jorge Silva
June 12, 2015
Programming
0
38
Introduction to RethinkDB: 1KE Meetup
Jorge Silva
June 12, 2015
Tweet
Share
More Decks by Jorge Silva
See All by Jorge Silva
Introduction to RethinkDB : Move fast and break things
thejsj
2
250
ForwardJS - RethinkDB - Getting Started
thejsj
0
170
ForwardJS - RethinkDB - Advanced Queries
thejsj
1
180
Automatic Failover in RethinkDB
thejsj
0
210
Workshop: Introduction to RethinkDB : Santa Cruz JS
thejsj
1
100
Push databases: A better way to build realtime apps
thejsj
1
110
Data Modeling in RethinkDB
thejsj
4
250
RethinkDB+Angular.js: Building realtime web applications
thejsj
10
30k
Introduction to RethinkDB : Hack Reactor
thejsj
4
380
Other Decks in Programming
See All in Programming
StoreKit2によるiOSのアプリ内課金のリニューアル
kangnux
0
110
Random\Randomizer クラスで日常のあれこれを解決しよう! / Random\Randomizer class solves familiar trouble
cocoeyes02
0
230
大規模Reactアプリのリアーキテクチャ~8万行のTanStack Query移行の軌跡~
kj455
4
960
GitHub Copilotのススメ
marcy731
1
200
はてなにおける CSS Modules、及び CSS Modules に足りないもの / CSS Modules in Hatena, and CSS Modules missing parts
mizdra
7
920
ゆるい個人開発のススメ
kuroppe1819
10
990
検証も兼ねて個人開発でHonoとかと向き合った話
hanetsuki
0
890
単体テストを書かない技術 #phpcon_odawara
o0h
PRO
27
8.2k
"config" ってなんだ? / What is "config"?
okashoi
0
240
Milestoner
bkuhlmann
1
410
Zero Waste, Radical Magic, and Italian Graft – Quarkus Efficiency Secrets
hollycummins
0
230
educure_カリキュラム生操作マニュアル.pdf
linew_official
0
760
Featured
See All Featured
Documentation Writing (for coders)
carmenintech
60
3.9k
Product Roadmaps are Hard
iamctodd
44
9.7k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
6
1.5k
Designing with Data
zakiwarfel
96
4.8k
Design by the Numbers
sachag
274
18k
Put a Button on it: Removing Barriers to Going Fast.
kastner
58
3k
Building Better People: How to give real-time feedback that sticks.
wjessup
355
18k
Atom: Resistance is Futile
akmur
259
25k
Fashionably flexible responsive web design (full day workshop)
malarkey
398
65k
We Have a Design System, Now What?
morganepeng
43
6.7k
The Cult of Friendly URLs
andyhume
74
5.7k
Build The Right Thing And Hit Your Dates
maggiecrowley
24
2k
Transcript
1KE Tech Talks San Francisco, California June 12, 2015 RethinkDB
The database for the realtime web
Jorge Silva @thejsj Developer Evangelist @ RethinkDB
Preface Why is realtime important?
Realtime apps
Realtime apps
Realtime apps • More and more apps are built to
be realtime • Users have come to want and expect this behavior in their apps
Building realtime apps is hard • You can keep everything
in a single server • You can poll the database to keep track of updates • You can publish updates through a message broker
Building realtime apps is hard • All solutions present a
tradeoff between scalability and complexity • It’s hard to keep track of state in realtime architectures.
Introduction What is RethinkDB?
What is RethinkDB? • Open source database for building realtime
web applications • NoSQL database that stores schemaless JSON documents • Distributed database that is easy to scale
Built for Realtime Apps • Subscribe to change notifications from
database queries • No more polling — the database pushes changes to your app • Reduce the amount of plumbing needed to stream live updates
Built for Realtime Apps RethinkDB is an excellent database for:
• Collaborative web and mobile apps • Multiplayer games • Streaming analytics apps • Realtime marketplaces • Connected devices
Introduction to ReQL RethinkDB Query Language
Introduction to ReQL • ReQL embeds natively into your programming
language • Compose ReQL queries by chaining commands
Anatomy of a ReQL Query r.table("players") .orderBy({ index: r.desc("score") })
.limit(3) Top three players by score
Anatomy of a ReQL Query r.table("players") .orderBy({ index: r.desc("score") })
.limit(3) Access a database table
Anatomy of a ReQL Query r.table("players") .orderBy({ index: r.desc("score") })
.limit(3) Order results
Anatomy of a ReQL Query r.table("players") .orderBy({ index: r.desc("score") })
.limit(3) Use index as pre-processed lookup
Anatomy of a ReQL Query r.table("players") .orderBy({ index: r.desc("score") })
.limit(3) Order results in descending order
Anatomy of a ReQL Query r.table("players") .orderBy({ index: r.desc("score") })
.limit(3) Only get the first three results
Subscribe to change notifications on database queries Changefeeds
r.table("users").changes() Track changes on the users table Changefeeds
Changefeeds r.table("players") .orderBy({ index: r.desc("score") }) .limit(3) .changes() Get updates
on top three players
Realtime apps Demo
http://questions.rethinkdb.com Questions
Additional Resources • RethinkDB website: http://rethinkdb.com • RethinkDB installation: http://rethinkdb.com/docs/
install/
Questions •
[email protected]
• @thejsj