Things you didn't know you can use in your Salesforce
Mobile Applications on an Elastic and Scalable 2-Tier Cloud Architecture
1. MAPCloud: Mobile Applications on an
Elastic and Scalable 2-Tier Cloud
Architecture
M. Reza Rahimi1, Nalini Venkatasubramanian1, Sharad Mehrotra1 and
Athanasios V. Vasilakos2
1. University of California, Irvine, CA.
2. National Technical University of Athens, Athens, Greece.
in IEEE/ACM UCC 2012, Chicago, IL, USA.
2. Outline
Cloud Resource
Allocation for Introduction and
Mobile Applications Motivation
Mathematical Formulation
of the Problem
Experimental and MAPCloud Middleware
Conclusion and
Simulation Results Architecture
Future Directions
2
3. Introduction and Motivation
Sensory Based Applications Location Based Mobile Music: 52.5%
Services (LBS) Mobile Video:25.2%
Mobile Gaming: 19.3%
Augmented Reality
Mobile Social
Networks and
Crowdsourcing
Multimedia and
Data Streaming
• ABI Research shows that mobile cloud
computing will be rising from 42.8 million
subscribers in 2008, to just over 998 million
in 2014 (nearly 19%).
3
4. Mobile Cloud Computing; What? Why?
Mobile Cloud Computing (MCC) = Using
Resources on Cloud to Empower Mobile
Applications
• Cellphones have limited resources such as Battery,
Memory and Computation.
First Approach: Connect to Public Cloud for resource intensive
tasks!
• (-) Long WAN delay [Satyanarayanan_2011] , [ Cavilla_2007] :
• unlikely to be improved while the prime target of WAN improvement
is bandwidth, security, management.
• (+) Scale up Very well.
[Satyanarayanan_2011] Mahadev Satyanarayanan, “Mobile Computing: The Next Decade”, in SIGMOBILE Mobile
2011.
[ Cavilla_2007] Lagar-Cavilla, Niraj Tolia, Eyal De Lara, M. Satyanarayanan, and David O'Hallaron. “ Interactive
Resource-Intensive Applications Made Easy”, In Proceedings MIDDLEWARE2007
4
5. Second Approach: Connect to Local
Clouds (Local proxies, Cloudlets) in
proximity of the users for resource
intensive tasks, [Clone Cloud],
[MAUI], [PARM], [Calling the
Cloud].
• (+) LAN delay is always order of
magnitude better that WAN delay
[Satyanarayanan_2011] .
• (-) Near user resources and wireless
bandwidth could not scale up well.
[PARM] S. Mohapatra, M. Reza Rahimi, N. Venkatasubranian ”Power-Aware Middleware for Mobile Applications”,
Chapter 10 of the Handbook of Energy-Aware and Green Computing, Chapman Hall/CRC, 2011.
[Clone Cloud] Byung-Gon Chun, Sunghwan Ihm, Petros Maniatis, Mayur Naik, Ashwin Patti " CloneCloud: Elastic Execution
between Mobile Device and Cloud", In EuroSys 2011.
[MAUI] E. Cuervo, A. Balasubramanian, D. Cho, A. Wolman, S. Saroiu, R. Chandra, and P. Bahl " MAUI: Making Smartphones Last
Longer with Code Offload", In MobiSys 2010.
[Calling the Cloud] Giurgiu, O. Riva, D. Juric, I. Krivulev and G. Alonso " Calling The Cloud: Enabling Mobile Phones as
Interfaces to Cloud Applications", In Middleware 2009. 5
6. Tier 1: Public Cloud
(+) Scalable and Elastic
(-) Price, Delay
Tier 2: Local Cloud
(+) Low Delay, Low Power,
Almost Free RTT:
(-) Not Scalable and 3G Access ~290ms
Point
Elastic
Wi-Fi Access
Point
RTT:
~80ms
M. Reza. Rahimi, N. Venkatasubramania "MAPCloud: Mobile Applications on an Elastic 2-Tier Cloud Architecture", UCC 2012.
M. Reza. Rahimi, Nalini Venkatasubramania "Exploiting an Elastic 2-Tiered Cloud Architecture for Rich Mobile Applications", poster in
IEEE WoWMoM 2012.
M. Reza. Rahimi, N. Venkatasubramania "Cloud Based Framework for Rich Content Mobile Applications", poster in the IEEE/ACM
CCGrid 2011.
M. Satyanarayanan, P. Bahl, R. Cáceres, N. Davies " The Case for VM-Based Cloudlets in Mobile Computing", In PerCom 2009. 6
9. Workflow
• It consists of number of logical and precise steps
known as a function (for application modeling).
• Functions could be composed together in different
patterns [Mabrouk_2009] , [Zheng_2004] :
k
F1 F2 F3 F1
SEQ LOOP
F3 P1 F3
1
F1 F4 F1 F4
1 F2 F2
P2
AND: CONCURRENT FUNCTIONS XOR: CONDITIONAL FUNCTIONS
N. B. Mabrouk, S. Beauche, E. Kuznetsova, N. Georgantas, and V. Issarny " QoS-aware Service Composition in Dynamic
Service Oriented Environments", In Middleware 2009.
L. Zeng, B. Benatallah, A. H. NGU, M. Dumas, J. Kalagnanam, and H. Chang "QoS-Aware Middleware for Web Services
Composition ", In IEEE Trans. Software. Eng., 2004.
9
11. Quality of Service (QoS)
• The QoS could be defined in two different Levels:
• Atomic service level and Composite service level or
workflow level.
• Atomic service level could be defined as:
• The workflow QoS is defined based on different patterns as:
Qos SEQ AND XOR LOOP
11
12. Normalization
• As it can be understood different QoSes have different
dimensions (Price->$, power->joule, delay->s)
• We need the normalization process to make them
comparable.
• It could be defined in different levels:
• Service,
• Workflow.
• Services, Max and Min Services (example):
12
13. Normalization (Cont.)
• The higher Normalized Power/Price/Delay are The better
services are (low power/price/delay).
• The same procedure could be used to define the normalized
workflow as:
13
14. Optimal Resource Allocation for
Mobile Applications
• The main question in resource allocation
problem is:
• Knowing the mobile user workflow; what is the
optimal service allocation considering price, power
and delay?
• To formally formulate this problem; we need to
have utility function.
• Many has been defined in the operational
research literature, we use the fairness utility
for our problem.
14
16. Cloud Resource Allocation for Mobile
Applications: CRAM
• CRAM uses the combination of two main best
practices in heuristic algorithm design:
• Simulated Annealing (Good Global Optima Finder)
• Greedy Approach(Good Local Optima Finder)
• It then uses the following observation to customize
for pervasive environment:
• Near user resources usually have better QoS.
Qos
16
17. CRAM (Cont.)
• Need Efficient way to retrieve information of
services on cloud in specific region.
• Example Query: “Retrieve all MPEG to AVI decoder
services in distance R of mobile user “
• R-Tree is an efficient way to answer these queries.
R2 R1 R
S2 S8
S1
R1 R2
S6
S4
R3
R3 R4 R5 R6
R5 R4
S3
R6 S5
S1 S1 S2 S5
S8 S3 S4 S7
S7 S9
S11 S11 S6 S9
S10 S10
A. Silberschatz, H. F. Korth, S. Sudarshan, "Database System Concepts", McGraw-Hill, 2010. 17
19. CRAM
• CRAM service selection could be as:
Total Number of Services
Randomly select and assigned
services to uk workflow with high
normalized price, normalized power,
normalized delay and average
normalized QoS.
Fi
S1,S12,S20,S28,…
19
20. MAPCloud Middleware Architecture
R-Tree
Cloud Service Registry Indexing
Structure
QoS-Aware Cloud
DB
Mobile User Log
DB
MAPCloud
Analytics DB
Local
and
Mobile Mobile Profile
Mobile User Public
Client Analyzer
Space-Time DB Cloud
Pool
Admission Control and Scheduling
MAPCloud Middleware CRAM Core
20
21. Experimental and Simulation Results: Mobile
Applications (Case Studies)
Video OCR+ Speech: Preprocessing:
Decode Video Noise cancelation,
Augmented
Binarization,
Reality Area Detection
(VAR): Search for Symbol in
Video Frames
You Tube Feature
Extraction
Link
Compute its Position
and Orientation
Classification
Extract Symbol in
all Frames Language
Processing
Render 3D object in
all Frames Text to Speech
Encode Video
Audio Decoding
21
22. Mobile Applications Profiling:
S1 large instance:
.
Amazon EC2,S3 . equivalent to a PC with
. 7.5GB of memory,
Sn
850 GB of storage
Local Cloud 4
S1
.
. Local Cloud 1 Local Cloud 5
.
Sn Local Cloud:
64bit Windows dual-core
LAN Speed
server,
with 8GB of memory S1
.
S1 and 500GB of storage. .
. Local Cloud 2 .
. Sn
.
Sn
Local Cloud n
S1
.
Local Cloud 7 .
.
Sn
22
23. Simulation Results
• In simulation we try to answer two important
questions:
• The optimality of CRAM Algorithm in different scenarios.
• The optimality of 2-Tier Architecture in comparison to
only using public cloud.
• Simulation Setup:
• MATLAB and CloudSim: Simulation Platforms.
• 15 15 : 100m length of each cell
• # Wi-Fi Access point 50 (Uniform Dist.), 3G ubiquitous connectivity.
• #Amazon Instances: [5-10]
• #Local Cloud Instances:[5-10]
• RWP as the Mobility model U[0-10ms]
23
25. Simulation Results(Cont.)
• Local Cloud+Public Cloud:
• How could we measure the performance of 2-Tiered
Cloud Architecture?
• What are the reasonable metrics?
Local Cloud+ Local Cloud+ Local Cloud+
Public Cloud Public Cloud Public Cloud
Same Delay Same Power Same Price
Public Cloud Public Cloud Public Cloud
25
27. Conclusions and Future Directions
• 2-Tier Cloud architecture has been reviewed.
• CRAM was proposed and its optimality was
investigated.
• MAPCloud middleware is reviewed for optimal
service allocation.
• Future Work:
1. Extending the workflow concept to space-time
workflow which capture the user mobility effects.
2. More class of mobile application such as video
streaming and content sharing with CRAM extension.
27