MOBILE APPLICATIONS AND CLOUD COMPUTING Roberto Beraldi Course - - PowerPoint PPT Presentation

mobile applications and cloud computing
SMART_READER_LITE
LIVE PREVIEW

MOBILE APPLICATIONS AND CLOUD COMPUTING Roberto Beraldi Course - - PowerPoint PPT Presentation

MOBILE APPLICATIONS AND CLOUD COMPUTING Roberto Beraldi Course Outline 6 CFUs Topics: Mobile application programming (Android) Cloud computing To pass the exam: Individual working and documented application Answer to


slide-1
SLIDE 1

MOBILE APPLICATIONS AND CLOUD COMPUTING

Roberto Beraldi

slide-2
SLIDE 2

Course Outline

  • 6 CFUs
  • Topics:
  • Mobile application programming (Android)
  • Cloud computing
  • To pass the exam:
  • Individual working and documented application
  • Answer to a couple of general questions
slide-3
SLIDE 3

Technologies today

Language Run-time support Development Protocols REST

slide-4
SLIDE 4

Technological convergence

INTERNET Mobile cellular Networks, wi-fi Telephone network

slide-5
SLIDE 5

New trends

  • Cloud
  • basically used as an extension of the resources of the device (memory

space, virtual machine, sw modules, etc..)

  • The goal is to make the computer look like ‘bigger’
  • Application that runs on mobile devices
  • Mobility (context-awareness)
  • Sensors
  • Where (lat,lon) the device running the application is located
  • Other Sensors, e.g., acceleration, orientation, camera
  • Connection and synergy between Cloud and Mobile applications

is possible

slide-6
SLIDE 6

Some example of application: QRCode

QR-code QR-reader Internet URI

slide-7
SLIDE 7

Example

slide-8
SLIDE 8

Another examples: media are changing

Same applies to books, newspapers, encyclopedia, etc.

slide-9
SLIDE 9

Example: Augmented reality

slide-10
SLIDE 10

Example: social-based applications

  • Twitter
  • Facebook
  • Blablacar
  • Uber
slide-11
SLIDE 11

Mobile application and cloud computing

Cloud

  • Cloud can play the role of

‘backend’

  • Access to cloud resourses

(CPU, storage, DB) using RPC- like calls … but cloud is more than this (see later)…

req reply

slide-12
SLIDE 12

Example

req reply

Cloud real time data on transportation available from ATAC via XML-RPC

http://www.agenziamobilita.roma.it/progetti/open-data/ http://www.agenziamobilita.roma.it/it/progetti/open-data/api-real-time.html

slide-13
SLIDE 13

New trends: Mobile cloud computing

code offloading computation and result

  • wi-fi direct (comm. feature)
  • reflection (language feature)
  • security aspects
  • application partitioning
  • subtasks allocation
  • DTN and social behavior

cloudlet (nearby resources)

  • voice recognition
  • pattern recognition
  • augmented reality
  • games (e.g., chess)
slide-14
SLIDE 14

Example: transient cloud*

*from: Transient Clouds: Assignment and Collaborative Execution of Tasks on Mobile Devices. Terry Penner et al. Globecom 2014

slide-15
SLIDE 15

Another example*

  • Task offloading over a DTN with task replication
  • Real mobility traces
  • Social behavior can help

(*)Collaborative Mobile-To-Mobile Computation Offloading, Beraldi et al., 3rd International Workshop on Collaborative Cloud (CollabCloud 2014), Miami October 2014

slide-16
SLIDE 16

Building distributed applications: run-time big view

Distributed System Distributed applications

run on

Resources

virtualizes

Operating System HW device CPU Local Communication

Higher abstractions :

  • Process (threads)
  • File, Virtual Memory
  • Active role (no need

controlling SW, which is ‘embedded’, hard wired)

  • Receive and respond to

external events (interrupts)

  • passive role
  • need to be

‘controlled’

Memory Socket Socket OS C M D Comm Remote Protocol (i.e. HTTP)

SW SW

Wire protocol Computer Computer Application

slide-17
SLIDE 17

Example of wire protocols

  • SOAP for Web Service
  • IIOP for CORBA
  • ORPC for DCOM
  • JRMP for Java RMI
  • REST for Web Service
  • JSONP

SW A SW B

Wire Protocol

HTTP OTHER

slide-18
SLIDE 18

Middleware and SW stack

Application layer Middleware layer / run-tine support Operating System HW

slide-19
SLIDE 19

Example: Tic Tac Toe

  • Monolithic application
  • All the logic is in a single program
  • Client Server
  • The server dynamically generates the page to

be displayed

  • Web API
  • Provides primitive operations to an application

(that can run on a mobile device, for example)

slide-20
SLIDE 20

Example: monolithic app

  • Monolithic

e.g., javaScript, or any language

slide-21
SLIDE 21

Example: client/server

http://game.org/ttt.php?move=7

  • Client HTTP Server + php

HTML Put an X at position 7

slide-22
SLIDE 22

Simple technological mapping of a web based application… (1/3)

Client Server

HTTP HTML

User Agent

mod_php

TCP/IP connection 3306,…

slide-23
SLIDE 23

…continued… (2/3)

Client Server

HTTP HTML

Embedded Objects

User Agent

mod_php

TCP/IP connection 3306,…

slide-24
SLIDE 24

…continued(3/3)

Client Server

HTTP HTML

+JS

User Agent

mod_php

TCP/IP connection 3306,…

slide-25
SLIDE 25

Simple solution for mobile app

Web API init

  • Send the

current state

  • Reply with the

new state Interface (remote functions) backend front end

slide-26
SLIDE 26

Introducing cloud

  • Cloud roles and boundaries
  • Cloud Provider
  • Cloud Consumer
  • Cloud Resourse Administrator
  • Cloud Characteristics
  • On-demand usage
  • Ubiquitous access
  • Resource pooling (Multitentancy)
  • Elasticity
  • Cloud Deployement models
  • Private cloud
  • Public cloud
  • Hybrid cloud
  • Delivery models
  • IaaS
  • PaaS
  • SaaS (and Web-API)
slide-27
SLIDE 27

Introducing clouds: example altervista

  • Self-service interface
  • Accessing complex building blocks, or ‘functionalities’
slide-28
SLIDE 28

Web API

WEB-API INRTENET Client Application A Web API allows to design and develop an application that exploits software modules accessed via Internet via a simple wire protocol

slide-29
SLIDE 29

Web API: example

slide-30
SLIDE 30

Example: Google apis

slide-31
SLIDE 31

Oauth 2.0: securing access

User Service Provider Application

4.send token acess and get info 1.register the application

slide-32
SLIDE 32

Web API: programmatic point of view

Programmatic Service Access (many methods) Web URL (standard HTTP methods)

web brower

HTTP

Application

HTTP

Rest,XML-RPC,etc

(Web API)

slide-33
SLIDE 33

Example: mashup applications

Provide A Provider B … API WEB CLIENT s=A.methodName(par1) … z=B.methodName(s,par2)

slide-34
SLIDE 34

Example: mashup applications (1/2)

Client Server Web API

Server Web API … JSON-RPC Server Web API AJAX Python ..

slide-35
SLIDE 35

Example: mashup applications (2/2)

HTTP

  • Server Web
  • ”mashupper”

(e.g.,dynamic pages Php) WEB API XML-RPC SOAP

slide-36
SLIDE 36

Web API and Interoperability

WEB-API Client Application (Technology A) Client Application (Technology B) Client Application (Technology C) ….

slide-37
SLIDE 37
  • Dropbox is a free (up to 2GB), web-based cloud storage mechanism
  • file backup service
  • data sharing
  • Data sync among different clients
  • Mobile applications

iPhone iPad Windows Linux MAC

.mp3 .avi .jpg

Freemium business model REST / JSON calls

Web API and Interoperability

slide-38
SLIDE 38

Questions?