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
40
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
180
ForwardJS - RethinkDB - Advanced Queries
thejsj
1
180
Automatic Failover in RethinkDB
thejsj
0
220
Workshop: Introduction to RethinkDB : Santa Cruz JS
thejsj
1
110
Push databases: A better way to build realtime apps
thejsj
0
120
Data Modeling in RethinkDB
thejsj
4
260
RethinkDB+Angular.js: Building realtime web applications
thejsj
10
30k
Introduction to RethinkDB : Hack Reactor
thejsj
4
400
Other Decks in Programming
See All in Programming
Tauriでネイティブアプリを作りたい
tsucchinoko
0
370
Compose 1.7のTextFieldはPOBox Plusで日本語変換できない
tomoya0x00
0
190
ピラミッド、アイスクリームコーン、SMURF: 自動テストの最適バランスを求めて / Pyramid Ice-Cream-Cone and SMURF
twada
PRO
10
1.3k
광고 소재 심사 과정에 AI를 도입하여 광고 서비스 생산성 향상시키기
kakao
PRO
0
170
AWS Lambdaから始まった Serverlessの「熱」とキャリアパス / It started with AWS Lambda Serverless “fever” and career path
seike460
PRO
1
260
flutterkaigi_2024.pdf
kyoheig3
0
130
A Journey of Contribution and Collaboration in Open Source
ivargrimstad
0
930
ふかぼれ!CSSセレクターモジュール / Fukabore! CSS Selectors Module
petamoriken
0
150
WebフロントエンドにおけるGraphQL(あるいはバックエンドのAPI)との向き合い方 / #241106_plk_frontend
izumin5210
4
1.4k
Nurturing OpenJDK distribution: Eclipse Temurin Success History and plan
ivargrimstad
0
920
Better Code Design in PHP
afilina
PRO
0
130
OnlineTestConf: Test Automation Friend or Foe
maaretp
0
110
Featured
See All Featured
BBQ
matthewcrist
85
9.3k
What’s in a name? Adding method to the madness
productmarketing
PRO
22
3.1k
Six Lessons from altMBA
skipperchong
27
3.5k
Automating Front-end Workflow
addyosmani
1366
200k
What's new in Ruby 2.0
geeforr
343
31k
Building a Scalable Design System with Sketch
lauravandoore
459
33k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
47
2.1k
Optimizing for Happiness
mojombo
376
70k
ピンチをチャンスに:未来をつくるプロダクトロードマップ #pmconf2020
aki_iinuma
109
49k
Reflections from 52 weeks, 52 projects
jeffersonlam
346
20k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
232
17k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
26
1.4k
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