45
CP4101 B.COMP DISSERTATION (H101850) SPONTANEOUS SOCIAL-NETWORKING ON SMARTPHONES USING DELAY-TOLERANT NETWORKS CHEN JUNCHENG SUPERVISOR: PROF CHAN MUN CHOON

Spontaneous Social-Networking on Smartphones using Delay-Tolerant Networks

  • Upload
    bunme

  • View
    57

  • Download
    0

Embed Size (px)

DESCRIPTION

Spontaneous Social-Networking on Smartphones using Delay-Tolerant Networks. CP4101 B.COMP DISSERTATION (H101850 ). CHEN JUNCHENG. SUPERVISOR: PROF CHAN MUN CHOON. Agenda. Motivation Application Description Challenges Faced (and Solutions) Evaluation Testing Demo. - PowerPoint PPT Presentation

Citation preview

Page 1: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

C P 4 1 0 1 B . C O M P D I S S E RTAT I O N ( H 1 0 1 8 5 0 )

SPONTANEOUS SOCIAL-NETWORKINGON SMARTPHONES USING

DELAY-TOLERANT NETWORKS

CHEN JUNCHENGSUPERVISOR: PROF CHAN MUN CHOON

Page 2: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

2

AGENDA

• Motivation• Application Description• Challenges Faced (and Solutions)• Evaluation• Testing• Demo

Page 3: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

3

RISE IN SMARTPHONE SALES

• Sale of smartphones has overtaken personal computers in the year 2010

Source: International Data Corporation

Page 4: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

4

RISE OF SOCIAL PROXIMITY APPS

• Applications where users discover others nearby and interact with them

Application Description Downloads

Rating

Badoo Chatting, dating, making friends with people nearby

10m+ 4.5

Skout Discovering and meeting new people around

10m+ 4.1

Circle Finding people nearby with mutual interests

5m+ 4.4

Sonar Connect with friends and like-minded people nearby

1m+ 4.1

As of: 2nd November 2013

Page 5: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

5

RISE OF SOCIAL PROXIMITY APPS

Market for social proximity apps

Projected Growth: $1.9 billion

Milli

ons o

f dol

lars

Page 6: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

6

SOCIAL PROXIMITY APPSIMPLEMENTATION

• Location (typically GPS) data uploaded to a central server• Server determines who/what is nearby• Client downloads the list of neighbors• Client displays the neighbors to the user

Page 7: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

7

PROBLEMS

• Battery consumption: Use of 3G + GPS is heavy on battery• Server-Reliance: Fails to function in absence of

internet connectivity• Bandwidth consumption: 3G consume user’s

data bandwidth• Network congestion: Cell towers are

overloaded with small packets in network

Page 8: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

8

THE FLITBY APPLICATION

• Build a Facebook-like application that is server-less• Works without internet connectivity

• Use peer-to-peer communication in order to exchange social data• Saves battery by eliminating 3G and GPS usage

• Vision: people flit by one another and spontaneously sharing social data using the application, therefore it is called Flitby

Page 9: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

9

P2P COMMUNICATION

• Phone-to-phone communications such as Wifi-Direct and Bluetooth• Proximity is inherent – if I can contact you, you

must be nearby• Shortcoming: only support one-hop transfers

which is very limited• Solution: Use Mobile Delay-Tolerant Network (DTN)

Page 10: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

10

MOBILE DELAY-TOLERANT NETWORK

• Network of all mobile users• Topology changes rapidly because of high user mobility

• Users exchange data when they are within range of one another• These connections are intermittent and short-lived in

nature• No direct paths may exist between any two nodes• Messages are stored and forwarded opportunistically for

multi-hop communication

A B C

Page 11: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

11

EXAMPLE OF HOW FLITBY WORKS

Guys! Free ice cream sandwich here at the Ice Cream Store!

Functionality #1: Post a

status

Functionality #2: Propagate social

data

Page 12: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

12

Oh my god! Really?Functionality #3:

Log encounters with other users

Functionality #5: Make comments and like them!

Functionality #4: View status post associated with

encounter

EXAMPLE OF HOW FLITBY WORKS

Page 13: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

13

CHALLENGE #1

• State Inconsistencies• In a decentralized network, it takes time for social

data to propagate through the network• Therefore, it is usually the case that clients have a

subset of the global state and this can be inconsistent.

• Merging of subsets during chance encounters can warp the meaning of messages

Page 14: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

14

CHALLENGE #1

TomBillDoraJuncheng

Does anyone know if there’s a lecture next

Monday?

DJ B T

Most recent first

Page 15: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

15

TomBillDoraJuncheng

Does anyone know if there’s a lecture next

Monday?

CHALLENGE #1

DJ B T

Page 16: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

16

TomBillDoraJuncheng

Does anyone know if there’s a lecture next

Monday?

Yes, there’s school on Monday. Deepavali is

on Saturday.

CHALLENGE #1

DJ B T

Page 17: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

17

TomBillDoraJuncheng

Does anyone know if there’s a lecture next

Monday?

Nope, it’s supposed to be a public holiday in

lieu of Deepavali being on Sunday

Yes, there’s school on Monday. Deepavali is

on Saturday.

CHALLENGE #1

DJ B T

Page 18: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

18

TomBillDoraJuncheng

Does anyone know if there’s a lecture next

Monday?

Nope, it’s supposed to be a public holiday in

lieu of Deepavali being on Sunday

Yes, there’s school on Monday. Deepavali is

on Saturday.

I agree!

CHALLENGE #1

DJ B T

Page 19: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

19

TomBillDoraJuncheng

Does anyone know if there’s a lecture next

Monday?

Nope, it’s supposed to be a public holiday in

lieu of Deepavali being on Sunday

Yes, there’s school on Monday. Deepavali is

on Saturday.

I agree!

CHALLENGE #1

DJ B T

Page 20: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

20

TomBillDoraJuncheng

Does anyone know if there’s a lecture next

Monday?

Nope, it’s supposed to be a public holiday in

lieu of Deepavali being on Sunday

Yes, there’s school on Monday. Deepavali is

on Saturday.

Uhm… So which is it?

I agree!

CHALLENGE #1

DJ B T

Page 21: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

21

TomBillDoraJuncheng

Does anyone know if there’s a lecture next

Monday?

Nope, it’s supposed to be a public holiday in

lieu of Deepavali being on Sunday

Yes, there’s school on Monday. Deepavali is

on Saturday.

Uhm… So which is it?

I agree!

CHALLENGE #1

The problem is that we did not capture the context of the comments!

Page 22: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

22

CHALLENGE #1

• Solution• Present information in a coherent manner to the user• Tapping on a particular comment should show the context in

which that comment was made

Page 23: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

23

CHALLENGE #1

TomBillDoraJuncheng

Does anyone know if there’s a lecture next

Monday?

Nope, it’s supposed to be a public holiday in

lieu of Deepavali being on Sunday

Yes, there’s school on Monday. Deepavali is

on Saturday.

Uhm… So which is it?

I agree!

Page 24: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

24

CHALLENGE #1

TomBillDoraJuncheng

Does anyone know if there’s a lecture next

Monday?

Nope, it’s supposed to be a public holiday in

lieu of Deepavali being on Sunday

Yes, there’s school on Monday. Deepavali is

on Saturday.

Uhm… So which is it?

I agree!

Page 25: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

25

CHALLENGE #1

TomBillDoraJuncheng

Does anyone know if there’s a lecture next

Monday?

Nope, it’s supposed to be a public holiday in

lieu of Deepavali being on Sunday

Yes, there’s school on Monday. Deepavali is

on Saturday.

Uhm… So which is it?

I agree!

Page 26: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

26

CHALLENGE #1

TomBillDoraJuncheng

Does anyone know if there’s a lecture next

Monday?

Nope, it’s supposed to be a public holiday in

lieu of Deepavali being on Sunday

Yes, there’s school on Monday. Deepavali is

on Saturday.

Uhm… So which is it?

I agree!

Page 27: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

27

CHALLENGE #2

• Communication Challenges• Exchange of information relies upon often brief

contacts with other users• Not enough time to exchange all data

• Social network data is monotonically increasing• Infeasible to exchange all data with users

Page 28: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

28

CHALLENGE #2

• Solution• Given that connection time is short-lived• Exchange of information should be prioritized based on

one’s interest (friends or otherwise)• Reduce redundancy and only send new information in form

of deltas• Any connection/encounters with any other clients is

purely opportunistic• Spread other non-priority data once priority data is

exchanged• Mobility patterns of users may also be used to prioritize

exchanges but this topic itself is its own research topic

Page 29: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

29

CHALLENGE #2Client A Client B

send friends list, status IDs with last modified time,

comment IDs with last modified time

send status delta

loop

[while there are updates for A's friends' statuses/comments]

acknowledgement

send status delta

acknowledgement

loop

[while there are status/comment updates to be sent]

close connection

Priority Data

Non-priority Data

Page 30: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

30

CHALLENGE #3

• Facebook Synchronization• Good idea to synchronize social networking data back

to Facebook periodically• However, Facebook doesn’t allow arbitrary

timestamps on status/comment posts.• It is difficult to coordinate the clients to preserve the order of

comments

Page 31: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

31

CHALLENGE #3

Flitby Proxy Facebook Servers

. . .

Aggregates and syncs

Solution: Use a proxy server to store social networking data from clients and commit to Facebook periodically. (Unimplemented)

Page 32: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

32

CHALLENGE #4

• Privacy• Flitby uses opportunistic routing through intermediate

nodes• Intermediate nodes can access other people’s data

• Negotiating cryptographic keys is difficult due to large delay.

• Solution• Use a server to negotiate/distribute cryptographic keys.

(Unimplemented)

Page 33: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

33

FLITBY ARCHITECTURE

Flitby Android Application

Data

User Activities (GUI) Syncher Facebook Android

SDK API

User Discovery

DTN Middleware

API Facebook Servers

User

Page 34: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

34

DATABASE

• User Table• Group Table• Status Table• Comment Table• Encounter Table

Page 35: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

35

EVALUATION

• Devices used:• Samsung Galaxy SII (v4.3.1)• Samsung Galaxy SIII (v4.1.2)• Nexus 4 (v4.3)

• Wi-Fi used:• IEEE 802.11g

• Development Environment: • Android Developer Tools v22.0.5-757759

Page 36: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

36

EVALUATION

• Time taken for DTN messages of varying sizes to be sent from node to node. (Using TCP over Wi-Fi)

0 500 1000 1500 2000 2500 3000 3500 4000 45000

500

1000

1500

2000

2500

3000

3500

4000

4500

5000

f(x) = 0.984117733534946 x + 420.208333333334R² = 0.999254493733008

Data size (kB)

time

take

n (m

s)

Page 37: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

37

EVALUATION

• Throughput of DTN based on previous data• For comparison: In the US, 3G has a data bandwidth of

3.84Mbps/1.44Mbps (practical download/upload rate)

Data Size (kB) Throughput (Kbps)256 3046.973048512 4432.532912

1024 5736.916072048 6726.6595924096 7361.685488

Page 38: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

38

EVALUATION

• Using Samsung Galaxy S2 and 3G network• 10 trials were conducted• Time recorded was time taken for the first screen

to completely load

First startup Subsequent startup

Flitby 5.97s 1.11sFacebook 9.89s 6.63s

Page 39: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

39

TESTING

• Android Strict Mode• option in the application

that would detect & log undesirable practices

• Manual Testing• 1 phone test case• 2 phones test case• Systems Testing

Client A Client B Client C Client D

Make a status post

synchronize postsynchronize post

Make comment c1

synchronize c1

synchronize post

synchronize c1

Make comment c2

Make comment c3

synchronize c3

synchronize c3

loop

[not synchronized] synchronize synchronize synchronize

Make comment c4

loop

[not synchronized]synchronize synchronize synchronize

Key:Application open

Page 40: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

40

WHAT FLITBY LOOKS LIKE

These are the people you have encountered with

This is your profile information

Page 41: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

41

WHAT FLITBY LOOKS LIKE

Type in a new status here

This is your profile information

Page 42: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

42

WHAT FLITBY LOOKS LIKE

Status PostStatus Post Owner

Comments

Write a response here

Page 43: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

43

DEMO

Page 44: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

44

CONCLUSION

• We were able to develop Flitby as a decentralized social application that functions with DTN• We tackled 2 of the problems presented in this

presentation• Communication Challenges (Application Routing Protocol)• State Inconsistencies (View Hierarchy)

• Future work could involve:• Expanding the social network feature sets• Improving Privacy• Synchronization of social data back to Facebook

Page 45: Spontaneous  Social-Networking on  Smartphones using  Delay-Tolerant Networks

45

END

• Thank you for your attention!• Questions?