1
IBM, PhoneGap and the Enterprise
July 29, 2011
Bryce Curtis Mobile and Emerging Internet Technology
IBM Software Group
2
Overview
IBM Team
Why PhoneGap?
Mobile in IBM
Native vs Web
Legal
Cool Stuff
3
IBM Team
Android iOS
Blackberry
4
Mobile Landscape
Exploding Mobile Demand 2013 will bring us more Mobiles than Desktops
Next Generation of Application – Always – On Using Services like Location, Notification,
Collaboration, etc… Different Cost Models / ROI
Business app lifecycle = 3 months
Consumer app lifecycle = 3 days (most people try it only once)
5
Mobile Landscape
Exploding market for Mobile Applications Consumers are demanding rich mobile access
across all their devices • Phones, tablets, game stations, PCs • Examples – Twitter, FourSquare, Pulse,
Collaboration Businesses expect their users to be able to access
important applications and data from multiple devices • Business brand accessed with similar function • Examples – Mail, IM, Facebook, Google+,
Conferencing, Graphics
6
Why Is Mobile Different?
• Mobile users require efficient and timely access to information.
• Interactions are short and focused, interruptions are common.
• Devices are often exclusively touch-based.
• User interfaces must be easy and obvious.
• Screen real-estate is precious. • Typing should be minimized.
Applications must still be usable when out of wireless coverage.
Timeliness of data must be communicated.
Security is critical. Often used for monitoring as opposed
to active consumption. Social interactions are important. Mobile hardware and user interfaces
evolve much faster than the typical enterprise software cycle.
Mobile users today expect high-fidelity access to the same information they have on the desktop, presented in an easy-to-learn, mobile-friendly (often touch-friendly) format.
7
Why PhoneGap?
Began working on mobile in early 2010 Several options
IBM research (x2)
Appcelerator - Titanium
• Started out as hybrid, but changed to JS Ansca Mobile – Corona
• Ruby Rhodes – Rhomobile
• Lua QuickConnect
PhoneGap • HTML, JS, CSS
8
Why PhoneGap?
Vision Meshes with IBM’s vision and strategy Hybrid framework Open source framework Standards based Goal is to become obsolete
9
10
Desktop
Mobile
11
Why PhoneGap?
IBM Mobile Strategy
“Extend our platform to mobile based devices using open standards and technologies targeting the broadest set of devices possible leveraging the skills and infrastructure of our existing customers.”
-- Greg Truty, WebSphere Strategist
“Provide mobile tools and applications that leverage open, standards-based web technologies when appropriate. This includes HTML5, JavaScript, CSS, PhoneGap and Mobile Dojo.”
-- Bryce Curtis, Mobile Technologist
12
Why PhoneGap?
Vision Platforms
Supported more platforms iPhone, Android, Blackberry 4.x, Symbian More platforms added:
• Blackberry OS5/6, WebOS, Windows Phone, Bada
13
Why PhoneGap?
Vision Platforms Architecture
Great architecture Modular (Plug-ins concept) Extensible
14
PhoneGap Architecture
PhoneGap Plug-ins Web App
PhoneGap Application
HTML
CSS
JavaScript
Resources
Accelerometer
Camera
Compass
Contacts
File
Geolocation
Media
Network
Notification
Storage
Custom Plug-ins HTML Rendering Engine (WebView) PhoneGap
Native APIs
HTM
L A
PIs
Pho
neG
ap
JS A
PIs
Mobile OS
OS
AP
Is
OS
AP
Is
Input
Services Sensors
Graphics
15
Why PhoneGap?
Vision Platforms Architecture MIT License
Friendly licenses are a must to get through IBM legal GPL cannot generally be used for IBM products Many enterprise customers have similar legal guidelines Customers want indemnification from IBM
... claims licenses that Apple has with Lodsys don't cover use of its technology by independent developers who use it in apps they make for the iPhone and iPad.
16
Why PhoneGap?
Vision Platforms Architecture MIT License Community
Large, active community Great user and developer forums Developer mindshare
500,000 Downloads 175,000 visits/month 6100+ forum members
Positive feedback from IBM and customers
17
A Look Back
Platforms that IBM considered important a year ago iOS, Android 1.x/2, Blackberry OS 4.x/5/6 Some interest in Symbian, Windows Phone
Cell phones are obsolete after 6-12 months
18
A Look Back
Platforms that IBM considered important a year ago iOS, Android 1.x/2, Blackberry OS 4.x/5/6
Some interest in Symbian, Windows Phone
Initial goals Consistent API Consistent support Good documentation Tests
19
Features
20
Documentation
21
Testing
mobile-spec Significantly expanded test coverage
• Automatic tests • Interactive tests
Validate releases Eliminate regression
Comprehensive test plan?
22
IBM Developers
Features Barcode scanner Push notifications Calendar APIs Remote loading
Products are willing to write plug-ins for PhoneGap and contribute back to community.
23
Remote Loading
PhoneGap Plug-ins Shell App
PhoneGap Application
Loader Accelerometer
Camera
Compass
Contacts
File
Geolocation
Media
Network
Notification
Storage
Custom Plug-ins HTML Rendering Engine (WebView)
PhoneGap Native APIs
HTM
L A
PIs
Pho
neG
ap
JS A
PIs
Mobile OS
OS
AP
Is
OS
AP
Is
Input
Services Sensors
Graphics
Web App
HTML
CSS
JavaScript
Resources
Web Server
Load remote app over web
Loads web app over HTTP
Application hosted on web server – Easily updated
– Personalization
– Same benefits of web app but with access to device features
IBM PhoneGap Browser - anyone can write mobile app
24
IBM Developers
Features Tooling/debugging
Integrate with Eclipse & IBM RAD Development & Simulation without SDKs Multiple builds from single www directory
Test plan & scenarios Documentation
User manual IBM DeveloperWorks papers
25
IBM Developers
Features Tooling/debugging Test plan & scenarios Documentation Globalization
Plug-ins for iOS, Android and Blackberry Security
Secure stores Encryption Enterprise apps sandboxed
26
IBM Developers
Features Tooling/debugging Test plan & scenarios Documentation Globalization Security PhoneGap is part of the bigger picture
MEAP Analytics Mobile device and app management Back-end connectors VPN
27
IBM Customers
Easy development Tried native Web based
Native worked ok the first time. But... then came more versions and more phones
Native development cost = 2-3x Web cost + Maintenance cost
Customers are realizing benefit of mobile web.
28
IBM Customers
Easy development Tried native
Web based
Works with existing servers
Works with existing services Ajax/XHR REST
29
IBM Customers
Easy development Tried native
Web based Works with existing servers Works with existing services
Ajax/XHR
REST End-to-end solution
Customer access to existing services Employee access to internal services
Moving cautiously (investigating) Security is critical
Distribution Distribute on App Store Get around Apple’s App Store
30
Native vs Web
This discussion is ongoing One solution does not fit all
Trade-offs Not everyone agrees
31
Native vs Web
This discussion is ongoing One solution does not fit all
Trade-offs Not everyone agrees
“If you can build your app with HTML, CSS and JavaScript, then you probably should.” - Johnathan Stark
“By 2015, mobile Web technologies will have advanced sufficiently such that half of the applications that today would be written as native apps will be, instead, delivered as Web apps.”
– Gartner Predications 2010: Web Technologies Will Evolve in Multiple Directions
32
Comparison
Web Hybrid Native
Performance
Dev cost
Dev time
App portability
Native functionality App store distribution
Extensible
Reasonable Reasonable Expensive
Short Short Long
High High None
No All All
Fast Native speed if needed Very Fast
No Yes Yes
No Yes Yes
33
Legal
That depends upon what your definition of “is” is.
-- President Bill Clinton
34
Legal
License agreements MIT, BSD, Apache
• Grant the end-user permission to do anything they wish with the source code.
GPL, LGPL • Copyleft license • Modifications made and redistributed by the end-user must include
the source code for these • End-user is not allowed to re-assert the removed copyright back over
their derivative work. • The modified software is must be made publicly available for further
modification by any user. • Linking GPL libraries may not be allowed. • Not usually acceptable for products.
35
Legal
Inbound license or Contributor License Agreement (CLA) Defines the terms under which intellectual property has been contributed
to a company/project
Contributor agrees they have the right to contribute code • Originator/author
Apache Software Foundation:
• The purpose of this agreement is to clearly define the terms under which intellectual property has been contributed to the ASF and thereby allow us to defend the project should there be a legal dispute regarding the software at some future time.
Protects PhoneGap project and anyone who uses it.
36
Legal
JSON The license includes this restriction: "The software shall be used for
good, not evil." If your conscience cannot live with that, then choose a different package.
Apple iOS SDK License Potential for contamination by proprietary information
Unlimited liability for user, extremely limited liability for Apple
Restrictions on distribution
App acceptance subject to Apple’s rules
IBM teams have segmented development iOS developers cannot write code for other devices
Android, BB developers cannot look at iOS SDK docs
iOS apps cannot be ported – must go other direction
37
Cool Stuff
phonegap-simjs PhoneGap development using JavaScript simulator
38
Cool Stuff
phonegap-simjs PhoneGap development using JavaScript simulator
phonegap-java Desktop version of PhoneGap Based upon Java for cross-platform Ported Android code
39
Cool Stuff
phonegap-simjs PhoneGap development using JavaScript simulator
phonegap-java Desktop version of PhoneGap
Based upon Java for cross-platform
Ported Android code
Dojo Mobile
40
40
Mobile Dojo (dojox.mobile) JavaScript toolkit and widget set for creating mobile applications Optimized for mobile browsers
Lightweight, minimal dependencies Native look
CSS themes for both iOS and Android-based devices
iOS and Android-style controls and widgets
41
41
Mobile Dojo (dojox.mobile) CSS features used to optimize webkit-
based browsers Animation, gradient colors, rounded
rectangles Animation
Uses CSS3-based animation where possible
Can use JavaScript animation for clients with don't support CSS3 animations
Flip, slide, fade Responds to both orientations as well
orientation changes Complete mobile widget framework
Switch, buttons, headings, tabs, lists, icons, containers
42
Dojo Mobile – iPhone Theme
42
Heading with a back button Round Rectangle List Edge-to-Edge List Round Rectangle List (Variable Height)
Tab Container Icon Container Switch RoundRect
43
Mobile Dojo - Widgets Charts
Optimized for mobile
Themes adapted to small screens iOS, Android, Blackberry
Touch support for scrolling and panning
Gauges Several new predefined styles
Touch support for changing value iOS, Android, Blackberry
43
http://chrism.dojotoolkit.org/mobile-0.2/make_samples/dojo-samples/demos/mobile-gallery/demo.html
44
Mobile Dojo – View Navigation
44
PageA
PageB
45
Korean
Thank you! Japanese
Merci French
Russian
Danke German
Grazie Italian
Gracias Spanish
Obrigado Brazilian Portuguese
Arabic
Simplified Chinese Traditional Chinese
Thai
תודהHebrew
29