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
Michael Nitschinger on Building a reactive Couc...
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Enterprise Java User Group Austria
September 29, 2015
Technology
180
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Michael Nitschinger on Building a reactive Couchbase driver for the JVM
Enterprise Java User Group Austria
September 29, 2015
Transcript
50 slides
A Retrospective: Couchbase on the JVM or
how we’ve built the first reactive driver and still love it Michael Nitschinger, SDK Engineer
©2015 Couchbase Inc. 2 Some History
©2015 Couchbase Inc. 3 Memcached
©2015 Couchbase Inc. 4 Memcached
©2015 Couchbase Inc. 5 Membase + CouchOne =
©2015 Couchbase Inc. 6 = Couchbase
©2015 Couchbase Inc. 7 Java SDK 1.x
§ Extends Spymemcached § Adds Config & View Capabilities § Stable & Mature § Old codebase, difficult to maintain and evolve § API grew organically
©2015 Couchbase Inc. 8 Spymemcached § Initial
Work Started mid 2006 (Java 5) § No Generics § Memcached ASCII Protocol
©2015 Couchbase Inc. 9 API Inconsistencies
©2015 Couchbase Inc. 10 Reworking the API
©2015 Couchbase Inc. 11 From Key Value to
Documents Key Value Views N1QL Search mcd ✔ 1.8 ✔ 2.0 ✔ ✔ 3.0 ✔ ✔ 4.0 ✔ ✔ ✔ .next ✔ ✔ ✔ ✔
©2015 Couchbase Inc. 12 Reworking the API –
The Document
©2015 Couchbase Inc. 13 Reworking the API –
2.x
©2015 Couchbase Inc. 14 Reworking the API
©2015 Couchbase Inc. 15 Rx Semantics single
multiple sync T Iterable<T> async Future<T> Observable<T>
©2015 Couchbase Inc. 16 Rx Semantics Event
Iterable<T> Observable<T> data retrieval T next() onNext(T) discover error throws Exception onError(Throwable) complete returns onCompleted()
©2015 Couchbase Inc. 17 Consuming Observables 17
§ The Observer subscribes and receives events. § A cold Observable starts when subscribed. § onNext can be called 0..N times
©2015 Couchbase Inc. 18 RxJava: Creating Observables
just 18
©2015 Couchbase Inc. 19 RxJava: Creating Observables
19
©2015 Couchbase Inc. 20 RxJava: Creating Observables
20
©2015 Couchbase Inc. 21 RxJava: Creating Observables
21
©2015 Couchbase Inc. 22 RxJava: Creating Observables
22
©2015 Couchbase Inc. 23 RxJava: Creating Observables
23
©2015 Couchbase Inc. 24 RxJava: Transforming Observables
24
©2015 Couchbase Inc. 25 RxJava: Transforming Observables
25
©2015 Couchbase Inc. 26 RxJava: Transforming Observables
26
©2015 Couchbase Inc. 27 RxJava: Transforming Observables
27
©2015 Couchbase Inc. 28 RxJava: Transforming Observables
28
©2015 Couchbase Inc. 29 RxJava: Transforming Observables
29
©2015 Couchbase Inc. 30 RxJava: Transforming Observables
30
©2015 Couchbase Inc. 31 RxJava: Transforming Observables
31
©2015 Couchbase Inc. 32 RxJava: Transforming Observables
32
©2015 Couchbase Inc. 33 RxJava: Filtering Observables
33
©2015 Couchbase Inc. 34 RxJava: Filtering Observables
34
©2015 Couchbase Inc. 35 RxJava: Filtering Observables
35
©2015 Couchbase Inc. 36 RxJava: Filtering Observables
36
©2015 Couchbase Inc. 37 Simple Query 37
©2015 Couchbase Inc. 38 Parameterized Query 38
§ Named Params
©2015 Couchbase Inc. 39 Parametrized Query 39
§ Positional Params
©2015 Couchbase Inc. 40 Conditional Index Creation
40
©2015 Couchbase Inc. 41 Coordinated Fallback 41
©2015 Couchbase Inc. 42 Coordinated Retry: Builder
42 § Declarative API instead of complicated retryWhen
©2015 Couchbase Inc. 43 Levelling up the Architecture
©2015 Couchbase Inc. 44 Why Reactive? 44
©2015 Couchbase Inc. 45 Java != JVM
©2015 Couchbase Inc. 46 Architecture
©2015 Couchbase Inc. 47 Smart Batching
©2015 Couchbase Inc. 48 Backpressure
©2015 Couchbase Inc. 49 Netty
©2015 Couchbase Inc. 50 Netty – In the
next Session!
More Decks by Enterprise Java User Group Austria
See All by Enterprise Java User Group Austria
Gerrit Grunwald on What the CRaC... SUPERFAST JVM STARTUP
ejug
2
240
Spring Framework 5.2 - Core Container Revisited
ejug
0
200
Andreas Caternberg on Jenkins Pipelines
ejug
1
830
Martin Ahrer on Continuous Delivery Infrastructure With Docker
ejug
0
190
Dirk Mahler on Software Analyse mit jQAssistant & Neo4j
ejug
1
330
Christoph Strobl on Spring Data & Hypermedia
ejug
0
180
Stefan Armbruster on Graph Modelling Antipatterns
ejug
1
160
Stefan Armbruster on Introduction into Neo4J
ejug
1
130
Michael Nitschinger on State of the art JVM networking with Netty
ejug
1
100
Other Decks in Technology
See All in Technology
田んぼから始まる挑戦 〜新米農家の1年目〜
miu_crescent
PRO
0
340
81天的 AI Agent 軟體開發團隊治理實務分享
regionbbs
0
170
20261113_JAWS_Osaka
takuyay0ne
0
430
Kiro アップデート 2026 年 11 月号 (11 月 8 日時点) | 目指せ Kiro マスター アップデート編
inariku
PRO
2
120
Reticulum, le réseau cypherpunk dont vous avez besoin !
rlifchitz
0
140
属人化したISMS運用をGitHubとAIで仕組み化した1年間の記録
sioncojp
4
2.6k
The Author Pays
hiccupps
0
210
SSFの現在地 ― CAEP/RISCからAI Identityへ
oidfj
0
430
ラクスル会社紹介資料|エンジニア向け / RAKSUL Introduction for Engineers
raksulrecruiting
0
100
bpf_arenaとstruct_opsを使うのが難しかった話
masu_mi
0
230
Ebitengine製iOSアプリ公開ボタンを押す会
eiei114
0
120
AI時代の組織作り:チーム開発から「個人×AI」への移行と、持続可能な「開発資本」の築き方
ham0215
3
840
Featured
See All Featured
Ethics towards AI in product and experience design
skipperchong
2
460
Measuring Dark Social's Impact On Conversion and Attribution
stephenakadiri
2
330
Making Projects Easy
brettharned
120
6.9k
Public Speaking Without Barfing On Your Shoes - THAT 2023
reverentgeek
1
660
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
10
1.4k
Chasing Engaging Ingredients in Design
codingconduct
0
400
Visualization
eitanlees
153
17k
Building AI with AI
inesmontani
PRO
1
1.4k
The Art of Programming - Codeland 2020
erikaheidi
57
14k
Tips & Tricks on How to Get Your First Job In Tech
honzajavorek
1
850
A designer walks into a library…
pauljervisheath
211
25k
Reality Check: Gamification 10 Years Later
codingconduct
0
2.4k