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
Jerzy Chałupski - Offline mode in Android apps
Search
Base Lab
January 15, 2014
Programming
3
470
Jerzy Chałupski - Offline mode in Android apps
A talk delivered at KrakDroid 2013 conference.
Base Lab
January 15, 2014
Tweet
Share
More Decks by Base Lab
See All by Base Lab
Szymon Sobczak - Hadoop + Storm
baselab
0
94
Slawek Skowron - Monitoring @ Scale
baselab
0
110
Karol Nowak - Monitoring clock drift in Amazon EC2 environment
baselab
0
100
Tomasz Nowak - Web Application Testing made easy
baselab
0
290
Szymon Pawlik - UX i Automatyzacja czyli jak testerzy mogą poprawić produkt.
baselab
0
240
Mateusz Herych - LIKE '%smth%' is not the way
baselab
0
140
Jerzy Chałupski - Data model on Android
baselab
4
220
Other Decks in Programming
See All in Programming
range over funcの使い道と非同期N+1リゾルバーの夢 / about a range over func
mackee
0
110
PSR-15 はあなたのための ものではない? - phpcon2024
myamagishi
0
140
Semantic Kernelのネイティブプラグインで知識拡張をしてみる
tomokusaba
0
180
Keeping it Ruby: Why Your Product Needs a Ruby SDK - RubyWorld 2024
envek
0
190
20年もののレガシープロダクトに 0からPHPStanを入れるまで / phpcon2024
hirobe1999
0
500
LLM Supervised Fine-tuningの理論と実践
datanalyticslabo
7
1.3k
menu基盤チームによるGoogle Cloudの活用事例~Application Integration, Cloud Tasks編~
yoshifumi_ishikura
0
110
ChatGPT とつくる PHP で OS 実装
memory1994
PRO
2
110
KMP와 kotlinx.rpc로 서버와 클라이언트 동기화
kwakeuijin
0
160
今年一番支援させていただいたのは認証系サービスでした
satoshi256kbyte
1
260
責務を分離するための例外設計 - PHPカンファレンス 2024
kajitack
6
1.5k
testcontainers のススメ
sgash708
1
120
Featured
See All Featured
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
0
98
Designing for humans not robots
tammielis
250
25k
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
32
2.7k
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
159
15k
Intergalactic Javascript Robots from Outer Space
tanoku
270
27k
GraphQLの誤解/rethinking-graphql
sonatard
67
10k
Practical Orchestrator
shlominoach
186
10k
Designing Dashboards & Data Visualisations in Web Apps
destraynor
229
52k
No one is an island. Learnings from fostering a developers community.
thoeni
19
3k
Optimizing for Happiness
mojombo
376
70k
How to train your dragon (web standard)
notwaldorf
88
5.7k
How GitHub (no longer) Works
holman
311
140k
Transcript
! Jerzy Chalupski chalup, futuresimple "
[email protected]
Offline mode in
Android apps Base CRM http://porcupineprogrammer.blogspot.com/ #
WHAT WHY HOW
WHAT is offline mode?
What happens when you send and email from Gmail app?
What happens if your connection is down?
What happens if your connection is down?
None
RECAP Offline mode = fully functional app without connection
WHY should I bother?
Life is too short to worry about the internet connection.
I had to watch the animated circle for 2 seconds.
They want to post the photos of their dinner on
Instagram! People want to DO THINGS!
SLOOOOOOW TIMEOUTS RETRYS NETWORK ERRORS HANDLING LIT SCREEN DATA PLAN
USAGE
ˑˑˑˑ˒ “Unbearably sloooooow.”
ˑˑˑˑ˒ “Drains my battery.”
ˑˑˑˑ˒ “Crashes all the time.”
None
RECAP BETTER UX
RECAP BETTER UX BETTER BATTERY LIFE
RECAP BETTER UX BETTER BATTERY LIFE BETTER CODE
RECAP BETTER UX BETTER BATTERY LIFE BETTER CODE
HOW do I implement it?
UI Http Client
UI Http Client SLOW FLAKY
UI Http Client SLOW FLAKY CACHE ALL THE THINGS!
Http Client SLOW FLAKY Storage FAST RELIABLE UI
Storage Http Client SLOW FLAKY UI FAST RELIABLE GET
Http Client SLOW FLAKY Storage FAST RELIABLE UI GET POST
Sync Service Http Client UI Storage GET POST
AbstractThreadedSyncAdapter Http Client UI ContentProvider SQLite DB CursorLoader
Sync Service Http Client UI Storage
Sync Service Http Client UI Storage
Sync Service Http Client UI Storage
BACKEND MOBILE
BACKEND MOBILE
BACKEND MOBILE
BACKEND MOBILE
BACKEND MOBILE
BACKEND MOBILE
BACKEND MOBILE
BACKEND MOBILE
BACKEND MOBILE
BACKEND MOBILE
BACKEND MOBILE
BACKEND MOBILE
BACKEND MOBILE 250k items?
BACKEND MOBILE ?
BACKEND MOBILE
BACKEND MOBILE
BACKEND MOBILE OFFLINE MODE = DATA MIGRATIONS
As pleasant as data migrations with SQLiteOpenHelper.
BACKEND MOBILE 1 2 1 2
BACKEND MOBILE 1 2 1 2 3
BACKEND MOBILE 1 2 1 2 3 3
BACKEND MOBILE 1 2 1 2 3 3 3
BACKEND MOBILE 1 2 1 2 3 3 3
BACKEND MOBILE 1A 2B 1 2
BACKEND MOBILE 1A 2B 1 2 3
BACKEND MOBILE 1A 2B 1 2 3 C
BACKEND MOBILE 1A 2B 1 2 3 C C
BACKEND MOBILE 1A 2B 1 2 3 C 4C C
BACKEND MOBILE 1A 2B 1 2 3 C 4 3
4C
BACKEND MOBILE 1A 2B 1 2 3 4 3 4C
BACKEND MOBILE 1A 2B 1 2 3 4 3D 4C
BACKEND MOBILE 1A 2B 1 2 2 3C 3
BACKEND MOBILE 1A 2B 1 2 2 2 3C 3
BACKEND MOBILE 1A 2B 1 2 2 D 2 3C
3 ?
BACKEND MOBILE 1A 2B 1 2 2 D 2 3C
3 D
BACKEND MOBILE 1A 2B 1 2 2 D 2 3C
3 D
BACKEND MOBILE 1A 2B 1 2 2 D 2 3C
3 D
BACKEND MOBILE 1A 2B 1 2 2 D 2 3C
3 D D
BACKEND MOBILE 1A 2B 1 2 2 D 2 3C
3 D 4D D
BACKEND MOBILE 1A 2B 1 2 2 D 2 3C
3 D 4D 4D
4D BACKEND MOBILE 1A 2B 1 2 2 2 3C
3 D 4
4D BACKEND MOBILE 1A 2B 1 2 2 2 3C
3 4 4
4D BACKEND MOBILE 1A 2B 1 2 2 2 3C
3 4 4
“My friend, you’re entering a world of pain” WALTER SOBCHAK
UUID
RECAP OFFLINE MODE = MIGRATIONS
RECAP UUID OR WORLD OF PAIN OFFLINE MODE = MIGRATIONS
Sync Service Http Client UI Storage
Sync Service Http Client UI Storage
“For every complex problem there is an answer that is
clear, simple and wrong.” HENRY LOUIS MENCKEN
Sync Service Http Client UI Storage CONFLICTS
Sync Service Http Client UI Storage CONFLICTS DUPLICATES
Sync Service Http Client UI Storage CONFLICTS HANDLING LARGE DATA
SETS DUPLICATES
Sync Service Http Client UI Storage CONFLICTS HANDLING LARGE DATA
SETS DUPLICATES BATTERY USAGE
None
!futuresimple chalup
?
Thanks.