CHAPTER 3 Location-Based Content Search Approach
3.5 Message queue selection algorithm
國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
29
3.5 Message queue selection algorithm
When all the messages are chosen (D_set, Q_set and R_set), Node A has to send these messages to Node B. But the messages cannot be parallel transferred. Therefore, we have to decide which one will be sent first. In the thesis, shown in Figure 13, we proposed a simple message queue selection algorithm, within the weight value d, q and r, and progressive value S to calculate and get the transmission Message queue M.
Figure 13: Message Queue Selection
We can get the dataset D_Set, Q_Set and R_Set from all the replication strategies we describe above. Then we give the dataset a different weight value d, q, r and d + q + r = 1. The first step, we find the dataset of highest weight value MaxSet, then, the MaxSet dataset pop a message and enqueue to M. This will be the first transmission message, then, we reset the weight value of MaxSet dataset, and add the Progressive value S to the other weight. Repeat the steps until all messages enqueue to M, and then we can get a complete Message queue M. Finally, Node A according to M sends all the messages to Node B.
The beginning results of this selection queue are similar to Weight Fair Queue
‧ 國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
30
(WFQ), the highest weight of messages will be sent more. After several times, the message will be selected by Round Robin (RR), because of the weight value and progressive value.
Message queue selection algorithm
Input: Data dataset D_set, Query dataset Q_set, Reply dataset R_set, Data weight d, Query weight q, Reply weight r, Progressive value S
Output: Message queue M 1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
While((size(D_set) + size(Q_set) + size(R_set)) != 0) MaxSet = Max(d,q,r).getSet()
M.enqueue(popMsg(MaxSet)) Switch(MaxSet)
Case D_set: d = d.original, q = q + S, r = r + S Case Q_set: d = d + S, q = q.original, r = r + S Case R_set: d = d + S, q = q + S, r = r.original End switch
If size(MaxSet) = 0 then MaxSet.weight = 0 End while
Return M
‧ 國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
31
CHAPTER 4
Simulation Results
In this chapter, we discuss the simulation results, and we compare with three protocols. LCS (we proposed), Locus [11] and Epidemic [3]. We make some variation in Epidemic, because of Epidemic doesn’t matter the query-reply situation. We set the area concept and let nodes having query scenario and reply action in Epidemic.
Then, in the results, we will show some validation parameters. And we explain how the equation be calculated below.
(1) Query-Reply Success Ratio: The equation is shown below. The number of success reply message means all the reply messages success delivery from Replier to Querier, and the same data we won’t be repeatable recorded. And the number of query message means how many numbers the query message be generated, so the replicate query messages we won’t record.
(2) Query Delivery Ratio: The equation is shown below. The number of query delivered means the all query messages which delivered to the data source node and the number of query message described above.
(3) Overhead: The messages which are redundant transferred are overhead.
Success reply message means the first message reply to the Querier and the same messages replied afterword do not include. Query delivered means the first message delivered to the Replier, and as above, the same messages don’t include.
‧
get the med Query-Re en they rea des move to
cy: We calc time of rec dium numbe
nodes are p ached the de the position
Figure
culate from ceive the fir
er to analyze s Ratio = n by shortes
e 14: Map o
32
the time o rst reply me
e. then we giv st path algor
of Taipei101
f send the f essage by th
ding area (F t a random ve them the
rithm.
1 surroundin
first query m he Replier.
message by And the re
‧ 國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
33
Figure 15: ONE simulator
4.2 Simulation Settings
The simulation setting is shown as Table 2. The map area is 3000m * 2500m, and the simulation time is 43200 seconds, it is equivalent to 12 hours. In order to initialize data sources, we have to set a warm up time 1000 seconds. The node data transmission rate is 2Mbps, and the transmission rage is 10m. All nodes divided to types, 35% is Online-node and 65% is Offline-node. The message size of Data message and Reply message are 500KB~1MB, and the Query message is 50KB~100KB. All the messages have a creation interval, the Data message is 120~180 seconds, and the Query message is 200~400 seconds. The node buffer size is 500MB. All nodes are pedestrian, so the moving speed is 1.8km~5.4km per hour. And the messages’ TTS is 18000 seconds, it is equivalent to 5 hours.
‧ 國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
34
Table 2: Simulation Settings
Area 3000m x 2500m
Simulation Times 43200 Sec
Warm Up Time 1000 Sec
Data Rate 2Mbps
Radio Range 10m
Online‐node : Offline‐node 35% : 65%
Message Size
Data/Reply message 500K~1MB
Query message 50K~100K
Interval of message creation
Data message 120‐180 Sec
Query message (offline‐node only) 200‐400 Sec
Buffer size 300MB
Velocity 1.8~5.4 km/h
Time‐To‐Store(TTS) 18000 sec
4.3 Simulation Results
Before comparing to other approaches, we analyze some parameters to our approach. First we will discuss the effect of the percentage of node type and the radius of Inside Area. Then, we will compare with other approaches to analyze the performance. And we will discuss below.
4.3.1 The percentage of node type
We simulate four node type scenarios. All the Online-node can’t query data, because we assume they can query from the Internet directly. They just create or reply data. We can see Figure 16 Query-Reply success ratio. If there are no Online-nodes, it get low success ratio. Because all nodes are Offline-node, they can’t know all the data
‧ 國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
mes
and vali
ssages.
Thus, they more repli idate our op
Figure 16
Figure
y cannot ge icate (see F pinion, in th
6: Query-Re
e 17: Query
et data easily Figure 18) he first case
35
eply Succes
y Delivery R
y. They hav to find the e (0% vs. 1
ss Ratio (No
Ratio (Node
ve to spend e data. And
00%), it ge
ode Type)
e Type)
more time d we can se et the worst
(see Figure ee Figure 1 t query deli
e 19) 7 to ivery
‧ 國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
ratio repl dire four
o. However lication (low ectly ask the rth case (90
r, if the netw w overhead)
em for data 0% vs. 10%)
work full of ), because it a. So, they g ) is the best
Figure 18:
Figure 19:
36
f Online-nod t is easily to get the data t results of a
Overhead (
: Latency (N
de, it means o encounter quickly (lo all the charts
Node Type)
Node Type)
s they don’t Online-nod ow latency)
s.
)
t need any m de, and they
. Therefore more y can , the
‧
cess ratio, a roach doesn he Inside Aradius per ssage replic area, then, 0 and 500.
Fig
we discuss sn’t have m l spend mu
dius of Insid
the results and we can n’t matter th
rea, and the rformed bad
ation, and t it is more
he outside a en the relate dly, too. B the data wil difficult to
ery-Reply S
mall radius area, if the r ed data does Because the e data sourc
In Figure performed radius too sm sn’t be centr
large Insi complicated ata. So, the
tio (Radius
the small r ode would l ce. Then, in
20, it is th a bad resu mall, there a ralized in th
de Area w d and be spr suitable rad
of Inside Ar
radius of in ike to query n Figure 2
he Query-R ult. Because are a few n he area. And will allow m
read around dius is betw
rea)
nside area, s y in this are 1, it perfor
Reply
‧
he big radiuenvironmen ed, etc., we e in our scen
d in the sma d in Figure 2 us, nodes wo nt settings.
might get t nario.
Figur
Figu
all radius. O 22, nodes sp ould look up If there are the differen
re 21: Overh
ure 22: Laten
38
On the other pent much up quickly. O
e different t nt suitable ra
head (Radiu
ncy (Radius
r hand, in th time to que Otherwise, t transmission adius. The r
us of Inside
s of Inside A
he big radiu ery in the sm
the selected n ranges, bu radius 500m
Area)
Area)
us, it got hi mall radius, d results bas uffer size, n m is the suit
‧ 國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
39
4.3.3 Node Density
In the section, we analyze the results with other approaches, Locus and Epidemic routing schemes. And we want to see what the importance part of our approach is, so we make two changing in our approach. One is we don’t matter the Data replication strategic and we only use the Epidemic routing to spread the data messages, and the other is we don’t care the Query replication strategic, just use Epidemic to disseminate the query messages.
In Figure 23, we can see our approach and Locus have a similar performance in query-reply success ratio, because both of we are using the region concept to centralize the messages. But, as the number of nodes increase, Locus will perform well than ours. Because our region concept base on local area, if there are many nodes in this area, it will have many messages (data, query, reply) in every node. Although nodes have rich data source, the transmission rate is fixed, and nodes intermittent connected, they can’t send all the messages. So, some messages might be ignore, and the performance isn’t well. And we want to see the importance part of our approach, we modify it in two types. (1) We use epidemic routing to replace the data replication strategic, and (2) we use epidemic routing to replace the query replication. The result shows the (1) type got worse performance. Because the data messages couldn’t be centralized to the inside area, the messages would spread to whole network. It is difficult to query unique data message in the network.
Otherwise, in order to compare fairly, we present a scenario with only Offline-node in our approach. Although the success ratio is worse than Locus, but the overhead and latency are better than Locus. And the result will discuss below.
‧ 國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
nod hav
And we ca des success
e high prob
Figure 23:
an see the F searching d bability to qu
Figure 2
Query-Rep
Figure 24 an data in Insid uery succes
24: Node Di
40
ply Success
nd Table 3, de Area. It ss.
istribution o
Ratio (Nod
in our appr means nod
of Success S
de Density)
roach, there des in the In
Searching
e are 71% o nside Area
f the will
‧
nside Areaorder Area utside Area
Figure 25 t the query m
the figure, sn’t just on query mess cess deliver Querier is t
Figure 26 cess ratio o
e 3: Detail n y 30
15 3 0
shows the q message, an , all the ap e copy spre sages, we ju ry. Therefor the most dif
Figure
6 is overhea of Locus is
number of N 40 50 15 22 7 7 5 3
query deliv nd it deliver pproaches h ead to the ne ust need one
re, it is easy fficult.
25: Query D
ad, and we s higher th
41
ery ratio, w ry to the Re have high d
etwork, and e query mes y to find the
Delivery Ra
can see the han LCS, b
bution in Su 70 80 25 23 6 4 3 0
we define the eplier who h delivery rat d the query m ssage to find e Replier, bu
atio (Node D
e result of L but its over
uccess Sear 90 10 23 18
8 6
3 2
e query deli has the data rhead is lar
rching 00 150
8 17 6 5 2 3
ivery as Qu source. We e data mes oes, either. I ource, then, eply this da
hough the q rger than L
200
‧
m this area, her. And LC a, thus, LCSFigure 27 wer than Loc de in the Ins S has higher
F
is Query L cus and Ep ide Area or concept, too
that data, b
s the same ry replicate eplicate mo de range of r opportunit
Figure 26: O
Latency. We pidemic. Be r Border Are
o. They wi but they ar
42
data in the to look up ore message the local ar ty to spend l
Overhead (N
e can see the ecause all th ea, it will qu ill centralize re not near
e same area data quickl e in delivery
rea, it sprea lower cost t
Node Density
e result of o he data wil uickly get th e the same
the area, it
a, if Querie ly. But, if Q ll be spread he data. Alt data in the t will spend
er closed to Querier far a verhead wi
‧
cus have simS has the ad
F
fer Size
8 shows the S and Locu d it could i milar rule t dvantage of
Figure 28
Figure 27: L
e query-rep us. As the increase the to replicate overhead an
8: Query-Re
43
Latency (No
ply success buffer size e query suc
messages,
ss Ratio (Bu y)
can see th , nodes cou ability. Our
cess ratio a
uffer Size)
he result of uld store m r approach are similar.
f our more
and But
‧
rease the la sible to for in all the warding, an ssage, then,9 is the ove crease slow ered, they c e are limited
0 is the que atency resul rward the re
results. W nd the big it could enh
erhead. As t ly. Because can send m d, it can’t sen
Figure 29: O
ery latency.
lts. Because eply messag We use the l storage co hance the d
44
the buffer s e node has more messag nd more as
Overhead (B
As the bu e nodes hav
ge to the R local region ould store m delay time o
size increas more space ges. But the
buffer size
Buffer Size
uffer size in ve more spa Replier. Our n concept
ncrease, all ace to store
approach L to determin rtant messa
ly activity.
overhead of messages, w ion rate and
the approa e messages,
LCS is the ne the mes ages, like r
f the
‧
shows the q ry approach e, they don’w TTS, Locu data in its difficult to
me to Store
on we want query-reply h display the
t have muc us is worse area, but th query data.
Figure 30:
t to see the i success ra e bed perfor ch time to d than LCS, he live time
45
Latency (B
influence o atio results,
rmance, bec delivery, so it is becaus e of data isn
Buffer Size)
f messages we can see cause messa the success se they will n’t enough,
live time ch e the low T ages just hav s ratio does
try their be it drops qu
hanging. Fi TTS parame ave short tim
sn’t well. In est to centra uickly, so n
gure
‧
work, if repsn’t send t rease the ov
Figur
shows the s will incre ply message
to the Quer verhead.
e 31: Query
overhead re ease. Becau es success d rier still ex
Figure 3
46
y-Reply Suc
esults, as th use messag delivery to t xist in the
32: Overhea
ccess Ratio
he TTS grow ges have a Then, these
overhead o
‧ 國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
appr send then
Figure 33 roaches wil ding queue, n, it could sp
shows the ll increase.
, the old me pend much
latency res Because the essage will b time to forw
Figure
47
sults. As th ere are man be sent first ward.
33: Latency
he TTS gro ny message t. So the new
y (TTS)
wth, the lat s in every n w one is dif
tency of all node, and in fficult to be
l the n the sent,
‧ 國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
48
CHAPTER 5
Conclusions and Future Work
In this thesis, we proposed a location-based content search approach. We use four strategies to achieve our objective. It is Data replication strategic, Query replication strategic, Data reply strategic and Data synchronize and update. Then we proposed a three-tier area concept, and every strategic in different area will have different rule to replicate messages. We divided all nodes into two parts, Online-node and Offline-node. If Offline-node wants to search some information, besides the other Offline-node, it can ask Online-node for searching. And in the sending message period, we proposed a message queue selection algorithm to decide which message will be sent first. Finally, we evaluate the results with Epidemic and Locus. And we use some parameters to verify our approach. Although LCS is worse than Locus in Query-Reply success ratio, in Overhead and Latency, LCS is much better than Locus.
In the future, we will consider the adaptive weighted value of messages.
According to the message forwarding times or the estimation numbers of unique messages in some area. The weighted value of messages could be revised, and the nodes can spread the most important message out. Finally, we will implement this work into Plastory [28] system which is a mobile storytelling platform we developed before.
‧ 國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
49
REFERENCE
[1] V. Cerf, S. Burleigh, A. Hooke, L. Torgerson, R. Durst, K. Scott, K. Fall and H.
Weiss, “Delay-Tolerant Networking Architecture”, RFC4838, April 2007, [Online].
Available: http://www.ietf.org/rfc/rfc4838.txt
[2] K. Fall, “A Delay-Tolerant Network Architecture for Challenged Internets”, In Proc. SIGCOMM, August 2003.
[3] A. Vahdat and D. Becker, “Epidemic routing for partially-connected ad hoc networks,” Tech. Rep. CS-2000-06, Duke University, July 2000.
[4] T. Spyropoulos, K. Psounis, C.S. Raqhavendra, “Spray and wait: an efficient routing scheme for intermittently connected mobile networks”, EE, USC, USA, In Proc. SIGCOMM, August 2005.
[5] T. Spyropoulos, K. Psounis, C.S. Raqhavendra, “Spray and Focus: Efficient Mobility-Assisted Routing for Heterogeneous and Correlated Mobility”, USC, EECS, USA, In Proc. PERCOM, March 2007.
[6] A.Lindgren, A.Doria, and O. Schel’en, “Probabilistic Routing in Intermittently Connected Networks”, LUT, Sweden, In Proc. SIGMOBILE, vol. 7-3, July 2003.
[7] D.K. Cho, C.W. Chang, M.H. Tsai, M. Gerla, “Networked medical monitoring in the battlefield”, CS, UCLA, USA, In Proc. MILCOM, November 2008.
[8] C. Caini, P. Cornice, R. Firrincieli, D. Lacamera, S. Tamagnini, “A DTN Approach to Satellite Communications”, DEIS/ ARCES, University of Bologna, Italy, In Proc.
IEEE Journal on Selected Areas in Communications, vol. 26-5, June 2008.
‧ 國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
50
[9] Y. Sasaki, Y. Shibata, “Distributed Disaster Information System in DTN Based Mobile Communication Environment”, Japan, In Proc. BWCCA, November 2010.
[10] P. Jinag, J. Bigham, E. Bodanese, “Adaptive Service Provisioning for Emergency Communications with DTN”, EECS, Queen Mary University of London, UK, In Proc.
WCNC, March 2011.
[11] Nathanael Thompson, Riccardo Crepaldi and Robin Kravets, “Locus: A Location-based Data Overlay for Disruption-tolerant Networks”, CS, University of Illinois Urbana-Champaign, USA, In Proc. CHANTS, September 2010.
[12] P. Yang, M.C. Chuah, “Performance evaluations of data-centric information retrieval schemes for DTNs”, CSE, Lehigh University, USA, In Proc. MILCOM, November 2008.
[13] Cong Liu, Jie Wu, Xin Guan and Li Chen, “Cooperative File Sharing in Hybrid Delay Tolerant Networks”, In Proc. ICDCSW, June 2011.
[14] Mikko Pitk¨anen, Teemu K¨arkk¨ainen, Janico Greifenberg, and J¨org Ott,
“Searching for Content in Mobile DTNs”, Helsinki University of Technology, Finland, In Proc. PERCOM, March 2009.
[15] S.C. Nelson, M. Bakht, R. Kravets, “Encounter–Based Routing in DTNs”, CS, University of Illinois at Urbana-Champaign, USA, In Proc. INFOCOM, April 2009.
[16] E.C.R de Oliveria, C.V.N. de Albuquerque, “NECTAR: A DTN Routing Protocol Based on Neighborhood Contact History”, Universidade Federal Fluminense, Brasil, In Proc. SAC, March 2009
[17] J. LeBrun, C.N. Chuah, D. Ghosal, M. Zhang, “Knowledge-Based Opportunistic Forwarding in Vehicular Wireless Ad Hoc Networks”, UC Davis, USA, In Proc. VTC, May 2005.
[18] P. Hui, J. Crowcroft, E. Yoneki, “BUBBLE Rap: Social-based Forwarding in Delay Tolerant Networks”, University of Cambridge, UK, In Proc. MobiHoc, May
‧ 國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
51
2008.
[19] P. Juang, H. Oki, Y. Wang, M. Martonosi, L.S. Peh, D. Rubenstein,
“Energy-Efficient Computing for Wildlife Tracking: Design Tradeoffs and Early Experiences with ZebraNet”, Princeton University, USA, In Proc. ASPLOS-X, October 2002.
[20] G. Sollazzo, M. Musolesi, C. Mascolo, “TACO-DTN: a time-aware content-based dissemination system for delay tolerant networks”, CS, University College London, UK, In Proc. MobiOpp, June 2007.
[21] S. Carrilho, G. Valadon, H. Esaki, “Hikari: DTN message distribute system”, The University of Tokyo, Japan, IPSJ SIG Technical Report, January 2009.
[22] C.E. Palazzi, A. Bujari, “A Delay/Disruption Tolerant Solution for Mobile-to-Mobile File Sharing”, University of Padova, Italy, Wireless Day, In Proc.
IFIP, October 2010.
[23] B. Cohen, “Incentives Build Robustness in BitTorrent”, May 2003
[24] “InMobi Mobile Market 2011 Review: Explosive Growth in Mobile, Tablet Impressions Increase 771%*”, InMobi, January 2012.
Available: http://www.inmobi.com/press-releases/
[25] “Steve Jobs Declares Post-PC Era”, InformationWeek, June 2010.
Available: http://www.informationweek.com/news/software/productivity_apps/225300193 [26] T. Vincenty, “Direct and Inverse Solutions of Geodesics on the Ellipsoid with application of nested equations”, Survey Review, Vol.23, 1975.
Available: http://www.informationweek.com/news/software/productivity_apps/225300193 [26] T. Vincenty, “Direct and Inverse Solutions of Geodesics on the Ellipsoid with application of nested equations”, Survey Review, Vol.23, 1975.