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
Mobile Development - BTalk
Search
Sing Jie Lee
January 09, 2013
Technology
100
1
Share
Mobile Development - BTalk
Talks about general iOS development and some mobile stats on BTalk - a mobile messenger.
Sing Jie Lee
January 09, 2013
More Decks by Sing Jie Lee
See All by Sing Jie Lee
Infocomm Media Youth Festival 2016 - Career Talk
singjie
0
58
Sprite Kit
singjie
0
59
SiriKit
singjie
0
210
React Native
singjie
1
89
Arduino
singjie
0
44
Software Engineering
singjie
0
56
Advanced Core Data
singjie
0
42
Amazon Echo and Home Integration
singjie
0
100
CS3216 Garena Project X
singjie
0
53
Other Decks in Technology
See All in Technology
運用を見据えたAIエージェント設計実践
amacbee
0
1.4k
ChatworkとBPaaS 異なる特性で学んだAI機能開発の ベストプラクティス
kubell_hr
2
1.3k
「速く作る」から「正しく作る」へ ─ 生成AI時代の開発フロー改革の ロードマップと実行 ─
starfish719
0
350
テストコードのないプロジェクトにテストを根付かせる
tttol
1
240
GoとSIMDとWasmの今。
askua
3
460
Spring AI × MCP 入門〜AIエージェントへのツール公開、境界設計から始める最小構成 〜
yuyamiyamoto
0
200
AIガバナンス実践 - 生成AIコネクタのデータ漏洩リスクと実務対策
knishioka
0
160
サイバーセキュリティ概論 / Introduction to Cybersecurity
ks91
PRO
0
110
地元にいないローカルオーガナイザーの立ち回り
uvb_76
1
430
ITエンジニアを取り巻く環境とキャリアパス / A career path for Japanese IT engineers
takatama
4
1.8k
JEP 522 Deep Dive - G1 GC同期コスト削減によるスループット向上を徹底検証&解説
tabatad
1
580
大規模災害時でも高い信頼性を維持するアプリケーション基盤の実現/nikkei-tech-talk46
nikkei_engineer_recruiting
0
130
Featured
See All Featured
Lessons Learnt from Crawling 1000+ Websites
charlesmeaden
PRO
1
1.3k
Tell your own story through comics
letsgokoyo
1
940
Visualization
eitanlees
152
17k
Avoiding the “Bad Training, Faster” Trap in the Age of AI
tmiket
0
160
Organizational Design Perspectives: An Ontology of Organizational Design Elements
kimpetersen
PRO
1
720
The Power of CSS Pseudo Elements
geoffreycrofte
82
6.3k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
234
17k
Faster Mobile Websites
deanohume
310
31k
Building Flexible Design Systems
yeseniaperezcruz
330
40k
A Modern Web Designer's Workflow
chriscoyier
698
190k
WENDY [Excerpt]
tessaabrams
11
38k
Accessibility Awareness
sabderemane
1
130
Transcript
Mobile Development Monday, January 21, 13
Agenda • Lifecycle of App • Mobile Design Principles •
Responsive • Memory Management • Network • Maintainability • Other Stuffs Monday, January 21, 13
Lifecycle of an App Monday, January 21, 13
Monday, January 21, 13
Different states of App Active Background Suspended Inactive Not Running
Monday, January 21, 13
Different states of App Active Background Suspended Inactive Not Running
Monday, January 21, 13
Different states of App Active Background Suspended Inactive Not Running
Free up memory Disconnect Reconnect Monday, January 21, 13
Mobile Design Principles • Performance • Responsiveness • Optimal memory
usage • Network • Maintainability Monday, January 21, 13
Responsiveness • Never block the main thread • Always dispatch
complex data handling to background threads • Utilize cache Monday, January 21, 13
Responsiveness • Image Processing User selects a picture Process Image
Main Thread Update UI Background Monday, January 21, 13
Example: Image Processing BBImageLoop::Post(^{ processedImage = ImageProcessor.Process(image); BBUILoop::Post(^{ [self updateUI:processedImage];
}); }); User selects a picture Process Image BBUILoop Update UI BBImageLoop Monday, January 21, 13
Responsiveness • Queues • BBUILoop • BBSoundLoop • BBImageLoop •
BBDLCoreData • BBDBLoop Monday, January 21, 13
Responsiveness • Queues/Operations are cancelable // Sending out Request tcp.requestNearbyBuddies();
handler = BBUILoop::DelayPost(^{ showTimeoutScreen(); }, 5000); ... ... // Response received BBUILoop::Cancel(handler); Monday, January 21, 13
• Queues • Use one queue per subsystem • Know
your queues / threads • Can be cancelled Responsiveness Monday, January 21, 13
Memory Management User Experience Low Memory Usage Monday, January 21,
13
Memory Management User Experience Low Memory Usage App is Active
Monday, January 21, 13
Memory Management User Experience Low Memory Usage App is in
Background/Suspended Monday, January 21, 13
Memory Management • Active? • Use comfortably, but be practical
• Inactive/Background? • Free up memory as much as possible • If not, Apple kills you in background Monday, January 21, 13
Anything lesser than that is a good gauge Memory Management
Apps in Background Monday, January 21, 13
Optimal Memory Usage • Stay SAFE in background • Utilize
system’s memory warning • Ensure no memory leaks Monday, January 21, 13
Use Instruments Monday, January 21, 13
Use Instruments Monday, January 21, 13
Network • Minimize network requests • Timeout is necessary •
Always assume: Network is BAD Monday, January 21, 13
Network Monday, January 21, 13
Network • Bad network : Delays • Prevent sending out
same requests before timeout • Cache responses Monday, January 21, 13
• Bad network : Disconnect • Queue critical requests •
Fast / Safe Queue • Resend requests after reconnection • Requestid is essential Network Monday, January 21, 13
• Fast Queue • Safe Queue Network Client Client Server
Server Monday, January 21, 13
• Fast Queue • Safe Queue Network Client Client Server
Server Chats Daily Life Monday, January 21, 13
Maintainability • Modular Code • Easy to Read • Proper
class/method names Monday, January 21, 13
Maintainability • BTalk is built on modular code Core Network
FileSystem MediaEngine ... DailyLife ... Video Draw Monday, January 21, 13
Added by Daily Life Plugin Monday, January 21, 13
Added by Plugins Monday, January 21, 13
Maintainability Core Network FileSystem MediaEngine ... DailyLife ... Video Draw
Plugin Manager register get Monday, January 21, 13
Some other stuffs la Monday, January 21, 13
Tracker • PivotalTracker • Schedule management tool cum bugs tracker
• Manages schedule for you • Generate Weekly Report Monday, January 21, 13
PivotalTracker Monday, January 21, 13
PivotalTracker • Generated Weekly Report and Schedule Monday, January 21,
13
Insights on Mobile Stats Monday, January 21, 13
Insights on Mobile Stats • Uses Flurry SDK • ~20kB
per session • Client stats collection is needed Monday, January 21, 13
Number of Sessions Monday, January 21, 13
Median Session Length Monday, January 21, 13
Session Length Monday, January 21, 13
User Paths Monday, January 21, 13
User Paths Monday, January 21, 13
Thank You 谢谢 Always write human readable code Monday, January
21, 13