On Device Applications

Download Report

Transcript On Device Applications

On Device Applications
aka Smart or Fat Clients
INF245
H2007
Ola Bø
Høgskolen i Molde
Build upon Martyn Mallick (2003)
Molde University College INF 245 Fall 2007
OBø
Smart clients – an outline


Smart clients may be
used when not on line
They may give access
to data also when not
on line


May be solved by having
a local data store
Smart clients permit a
better user interface
than thin clients
Molde University College INF 245 Fall 2007
OBø
Smart client development
challenges and goals

Challenges






Limited UI and low device capacity
Integration with other business systems
Connectivity
Application roll out and administration
Technology in development –
Goals


Insight into challenges and solutions
Cover possible technologies
Molde University College INF 245 Fall 2007
OBø
On device application
platforms

No clear leader – several possibilities




Windows CE
Symbian
Palm OS
Linux
Molde University College INF 245 Fall 2007
OBø
Windows CE


A bad start (1996) (unstable
and cumbersome)
Major progress






Pocket Word, Excel, IE,
Outlook, Multimedia, Reader
Simplified Win32 API
Support for Visual Studio.NET
Communications using BT,
WLAN, GPRS, IPv6, 3G
Improved performance
CE.NET
Pocket PC
Windows Mobile
CE.NET
CE.NET
CE.NET as Core operating
system


CE is used in the operating
system for several device types
Pocket PC uses a version of
CE.NET adapted to PDA
Molde University College INF 245 Fall 2007
OBø
Windows Automotive
CE.NET
Windows CE development
CE.NET 2004
5.0
ARM, MIPS
SH, x86
2G-3G
VoIP
Molde University College INF 245 Fall 2007
OBø
Windows CE Architecture
Molde University College INF 245 Fall 2007
Kilde Microsoft http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wceintro5/html/wce50oriWelcomeToWindowsCE.asp
OBø
Windows
mobile



Started 2000
Supports several types
of device
Now in version 6.0







connectivity
persistent storage
Office-support
Multimedia
Hard-disk storage
Multimedia
hard drive
Kilde: Microsoft
Molde University College INF 245 Fall 2007
OBø
Molde University College INF 245 Fall 2007
OBø
Palm OS

Early success




75 % of the market in early 2000
many applications
now fading
New Palm devices are using windows as
operating system
Molde University College INF 245 Fall 2007
OBø
Symbian


Initially called EPOC an
operationg system for the
PSION device with 640*240
screen and pen based input
Symbian v6.0 2000



Better support for
communications
Applications using C++, Java
and WAP
Symbian V 7.0 2002




For advanced mobile phones
Synchronizing OTA using
SyncML
Security
Different UIs


pen based UIQ
series 60 for mobile phones

Includes apps for personal
information, web and
messaging.

Strong in Europe

Owners


Ericsson (15.6%), Nokia (47.9%),
Panasonic (10.5%),
Samsung (4.5%), Siemens (8.4%)
and Sony Ericsson (13.1%)
Installed base (per october
2007)




Symbian operating system is used
on an increasing number of mobile
phones
Over 145 million devices sold
Symbian smartphone OS share for
Q2 2007 is 72%,
Embracing
(source computerworld.no
http://www.computerworld.no/index.cfm/fuseact
ion/artikkel/id/47754)
Molde University College INF 245 Fall 2007
OBø
Symbian ver 9,5
Core OS
Security, Privacy and Content Protection
• Application capability management
• Application data caging
• Cryptographic algorithms – DES, 3DES, RC2, RC4, RC5 and AES
• Cryptographic token framework
• DRM framework and reference implementation
• IPSec and VPN client support plus SSL and TLS
• User permissions prompting
Open Environments
• Standard C environment
• Standard libraries including partial POSIX support (P.I.P.S)
Location-Based Services
• GPS, A-GPS (terminal-assisted / terminal- based) and network-based positioning
• Mobile originated and mobile terminated requests (including emergency requests)
Telephony
• Multimode Etel (2.5G / 3G)
• GSM Phase 2+
• HSCSD
• GPRS, classes A, B and C (R97/98)
• EDGE (CSD and GPRS)
• WCDMA (3GPP R4 and R5 IMS support)
• HSDPA, HSUPA
• SMS (3GPP TS 23.040 V6.5.0)
Molde University College INF 245 Fall 2007
• EMS (3GPP TS 23.040 V4.5)
OBø
• SIM Application Toolkit
• SIM and USIM support
Linux



The most well known
device is Sharp Zaurus
Nokia launched 770
”Internet Tablet” spring
2005
See
http://www.linuxdevices.
com/articles/AT942308
4269.html
Molde University College INF 245 Fall 2007
OBø
Java
Optional JSR
packages
Optional JSR
Packages
MIDP
Molde University College INF 245 Fall 2007
OBø
Molde University College INF 245 Fall 2007
OBø
Native vs. Java


Java applications





run in a J2ME
environment isolated from
the devices OS
Cross platform
Java augments
productivity and reduces
errors
Java has good
communications support
J2ME standard is
developped in cooperation
JCP
Native applications work
directly with the device OS
 Performance?
 Can use more device
functionality
 Can also be developed
using modern languages
 ”deFacto” standard
developed by one
company can move
faster
Molde University College INF 245 Fall 2007
OBø

Server

Client and Server


Client


Storage on the device reduces
need for connectivity and
improves performance and
battery life
Stale data risk





Client must communicate
with server and store data
Ready made
synchronization solutions
are available
Invisible for end user
Responsability:
 Data synchronization
 Data storage
 Message exchange
Synchronization


Several possibilities
Several possible formats




Databases and/or ERP-systems –
In most cases only a limited amount of
the data may be stored on device

What data should be on device?





Roll your own possibly using XML
SyncML
Only some tables?
Only data for a certain geographic area
Only data for certain customers?
Building a custom solution or using
COTS
Often a good solution to use COTS
Message based solutions may
transfer data and events
asynchroneously
No need for connection while
computing
Molde University College INF 245 Fall 2007
OBø
Integration with other systems in the
enterprise


Different integration solutions: database, system, XMLdata, or integration using flat file.
Complexity also varies


Basic: using standard synchronization using communications
over IP-networks with RDBs.
-> develop custom solution or buy a cots solution
Complicated: Support for heterogeneous terminals,
simultaneous synchronization for several users and
communications with systems having complicated interfaces.
Complex data models, substantial amounts of data and
transactions. Conflict handling -> Buy a COTS solution if
possible
Molde University College INF 245 Fall 2007
OBø
Advanced user interfaces

What can be improved?

Simplified navigation –
 Few selections to get to the right place
 The most used functionality should be most accessible
 Must be developed while testing in practice

Pre filled field where possible
Choose devices giving the right trade-off between
screen size and mobility

Molde University College INF 245 Fall 2007
OBø
User interfaces







Typically 80 % of code and cost
Must work in use
Screen size a problem
Input must be adapted to the real
users
Early experimenting using
prototypes is a good idea
Experience and studies show that
actual use is different from what was
planned by developers
User interface should be tested with
real users in an early phase.
Molde University College INF 245 Fall 2007
OBø
Local storage
Molde University College INF 245 Fall 2007
OBø
Ways to store data – an outline

Flat Files – sequential access, difficult to insert and change data – easy
to store in sequence.

Relational databases – logical structure built upon
tables with rows and columns. Current standard for data
storage. Improved with stored procedures and
transactions

Object databases – A challenger for RDBs but with small success.
Stores objects rather than tables. Can be appropriate for som niches
but relatively infrequently used.
XML-databases may be appropriate if all communications use XML,
but is inefficient and slow if not. Infrequently used.

Molde University College INF 245 Fall 2007
OBø
Why persistent storage on
device?

Client with no storage is an alternative but the
storage is most ofte appropriate because of:





Network coverage problems
Speed problems
Static data
Battery capacity
Hybrid solutions is also possible


Persistent storage for static data
On-line update for data that must be up-to-date
Molde University College INF 245 Fall 2007
OBø
Alternatives for on device
persistent storage




The proprietary storage mechanism for the
device operating system
J2ME record storage
Custom built data base
Commersial relational databases
Molde University College INF 245 Fall 2007
OBø
Proprietary device storage
solution




Windows CE – object store API = database using flat files.
Supports inserts, search and sorting. Present in RAM.
Symbian OS – Relational data base supporting SQL and
transactions are a part of the operating system (A C++ API for
the database is also present)
J2ME MIDP includes the RMS (Record Management System)
that implements a standardized interface to the device data
storage. RMS is covered in the J2ME programming part of
this course.
Common properties: All the built-in solutions are appropriate
for simple applications with limited amounts of data. They may
then be used to provide a cheap and quick solution, but all of
them demands the development of your own code to
synchronize with the enterprise data base and that may be
difficult for complex applications
Molde University College INF 245 Fall 2007
OBø
Commercial relational
databases


Many data base engine manufacturers also
makes versions adapted to mobile devices
and corresponding synchronization solutions
Substantial differences between vendors
Molde University College INF 245 Fall 2007
OBø
Vendor
Product
OS
supported
footprint
synchronization
encryption
Sybase/
iAnywhere
SQL Anywhere
Studio
CE, Palm,
Symbian,
Linux,
Java
3 MB on CE
Ultralite
300k
Two ways to all
ODBC. adaption
using rules.
Good comms
solutions
Storage
and
comms
Market leader 68% ?
Both Java og C++
IBM
DB2 Everyplace
CE, Palm,
Symb,
Linux,
Java
150 kB
SyncML two ways
via Sync server DB2
DB
From DB2 to ODBC
?
SQL, but no
transactions. Both
VB, C, C++, Java,
QBE
Oracle
Oracle 9i Lite
CE, Palm,
Symb
5 MB on CE
+ DB
Down to 1
MB på
andre
Proprietary solution
synchs with Oracle
databaser
yes
Powerful
administration tools
Microsoft
SQL Server
Compact
CE
1-3 MB
Via HTTP over MIIS
to Microsoft SQL
Server
SSL
Development using
Visual Studio .NET
PointBase
PointBase
embedded
edition and ME
Java
EE>J2SE
ME>+J2ME
45kb ->
Flexible
synchonisation
using UniSync
server and JDBC
?
100 % Java
Integration with enterprise
systems
Molde University College INF 245 Fall 2007
OBø
Integration using
synchronization

Synchronization





Means all data on the mobile device is updated in
one operation
Continuous connection is not necessary
Advantages: reduced traffic, costs and bandwidth,
quick access and better control
Synchronization is a two ways update
Synchronization can be tethered or wireless
Molde University College INF 245 Fall 2007
OBø
Types of Synchronization

PIM-synkronization: e-mail, addressbook and
calendar



Microsoft Outlook og Lotus Notes on desktop
File synchronization
Data synchronization
Molde University College INF 245 Fall 2007
OBø
Architecture for
synchronization
Molde University College INF 245 Fall 2007
OBø
Publish/Subscribe Model
The server publishes
data for different
purposes
The mobile device
subscribes to data
fitting the needs of
the user
Molde University College INF 245 Fall 2007
OBø
Techniques for
synchronization

Snapshot



Delete the whole table at the receiving end and
replace with an updated table
Suitable if RO data, small datasets, high
bandwidth, infrequent updates
Net changes



Only changed data are sent
Usually the most efficient solution
saves time when frequent updates and large
tables
Molde University College INF 245 Fall 2007
OBø
Solutions for transferrign data
for synchronization



Important for application efficiency
Should happen without involving the user (difficult)
Two solutions


Session based
 Direct connection between mobile and central databases
updateing both databases simultaneously
 Firewalls can be an obstacle
Message based
 Updates are sent as messages
 Store and forward
 Can support a considerable number of remote users
Molde University College INF 245 Fall 2007
OBø
Important properties for
synchronisation solutions

Support for splitting up data



Data compression







floating point to integers
fixed length to variable length

A challenge with intermittent
connections
When two user wants to update the
same row with different data

WWAN, WLAN, LAN, Via PC using
BT...
Enterprise integration
Conflict detection

Handling of lost connection
At least HTTP over TCP/IP
Transport mechanisms


Rules based – last wins
Support for networing protocols
Transaction integrity (ACID)


Conflict resolution

Less data to transmit but overhead
Data transformation


Subsetting of the database
Partitioning of data
 Column partitioning
 Row partitioning –
reduces update conflict

Synchronization server should be
able to communicate with all
datasources
 using JDB/ODBC with all data
base engines
 using adapters with ERP and
CRM solutions
Security

Authentication, Authorisation,
Encryption
Molde University College INF 245 Fall 2007
OBø
Synchronization using different transport
mechanisms
Molde University College INF 245 Fall 2007
OBø
Choices when developing
synchronization solutions


Depends upon solution for persistence
Alternatives




Solutions from the database vendor
Custom built
Buy one
Synch solutions embedded in the device

Usually not made for database synchronization
Molde University College INF 245 Fall 2007
OBø
Synchronization solutions embedded in
the device OS
OS synchsolution
Connection
Built in
functionality
Note
Windows
Cradle, Transfer files
CE
WLAN, and apps
ActiveSync IrDA, BT Synchroni-
C/S architecture
Active Sync service providers
can be bought or made. Two
zation of eCOM modules must be
mail, contacts,
developed
Palm OS
HotSync
Symbian
OS
Connect
calendar,
Cradle
plans, notes
with MS
IrDA
over nett Outlook.
Browse the
internett, File
BT,
handling,
kabel,
Backup,
IrDA
Restore
avh av
Conduit plug-ins can be
developed using VC++, VB or
Java with Palm CDK
Converter API permits
development of custom
solutions
terminal
Molde University College INF 245 Fall 2007
OBø
Data synchronization using mobile
device OS synchronization support


Solution has important functionality
Users already employ this synchronization method


An advantage to extend the solution already in place
Several commercial synchronization solutions are
extensions of the OS device synchronization.
Molde University College INF 245 Fall 2007
OBø
Custom built synchronization
solutions


Build using C/C++ or Java
Must solve









Database problems
Device support
Networking protocol
Conflict resolution
Safety
Supoprt for SyncML?
Integration with OS synch solution
Maintenance
Conclusion: Difficult/expensive
Molde University College INF 245 Fall 2007
OBø
Commercial synch solutions

Delivered by database vendors


Varying flexibility




More or less tied to their own data base products
Platform for mobil server and device
Amounts of data
Conflict handling
May be sensible to let the choice of synch solution
guide the choice of persistence solution
Molde University College INF 245 Fall 2007
OBø
Commercial synch solutions
Vendor
Product
OS
supported
Synchronization
Sybase/
iAnywhere
MobiLink
CE, Palm,
Symbian,
Linux,
Java
Two ways to all ODBC.
Adapted using rules.
Rich communications
Publish/Subscribe, Synchronization and
conflict solution in the data base Supports
simultaneous connection to several
databases. Both Java and .NET
Only Sybase
Message based solution
SQL Remote
IBM
DB2 Everyplace
Sync Server
CE, Palm,
Symb, ...
SyncML two ways via Sync
server DB2 DB
Thence to ODBC
publish/subscribe
Oracle
Oracle 9i Lite
CE, Palm,
Symb
Proprietary solution
conncting to Oracle
databases
Mobile server og mobile sync client.
Microsoft
SQL Server CE
CE
1.
RDA
merge
Publish/Subscribe
Weak conflict handling, but may be
programmed
IBM (june 2007)
PointBase
PointBase
embedded
edition and ME
Java
2.
Flexible synchronization
UniSync server using JDBC
net for PB and Oracle
snapshot for other dbengines
Publish/Subscribe
Open source synch solutions

Funambol http://www.funambol.com/
Molde University College INF 245 Fall 2007
OBø
Open Mobile Alliance Data
Synchronization and Device
Management aka SyncML



Heterogeneous synchronization solutions an obstacle to
integration
SyncML industry standard(?) synchronization protocol
Low impact so far

Already competing solutions on the market
Except PIM
 Several major companies such as Motorola, Nokia, Sony
Ericsson, IBM and Siemens AG already support SyncML in their
products (source Wikipedia)
SyncML a data synchronization protocol
 XML based
 Supports a number of transport protocols TCP/IP, HTTP , WSP,
OBEX, SMTP, POP3, IMAP ...
 Can transfer all kinds of data
 Makes allowances for limited resources on mobile devices
 Should work on all mobile
devices
using
Molde University
College INF 245
Fall 2007all kinds of data sources


OBø
SyncML




Packages containing messages containing commands
Message format defined in SyncML representation prototcol
SyncML Sync Protocol defines interaction between client and server
as message sequences
SyncML Transport Binding define transport protocol usage: HTTP,
WSP og OBEX
Molde University College INF 245 Fall 2007
OBø