Building mobile back ends with windows azure mobile services
-
Upload
aidan-casey -
Category
Technology
-
view
473 -
download
7
description
Transcript of Building mobile back ends with windows azure mobile services
![Page 1: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/1.jpg)
Building mobile back ends with windows azure mobile services
Windows Azure Sydney User Group
June 2013
![Page 2: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/2.jpg)
Aidan Casey
@AIDANJCASEY | acaseyblog.wordpress.com
Solutions architect @MYOB Australia
![Page 3: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/3.jpg)
Agenda BaaS overview
Windows Azure Mobile Services Features
- Storage
- Push Notifications
- Authentication & Authorisation
- Scheduler
- Diagnostics & Scale
![Page 4: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/4.jpg)
How long does it take to build a mobile app?
![Page 5: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/5.jpg)
18 weeks!http://www.kinvey.com/blog/2086/how-long-does-it-take-to-build-a-mobile-app
![Page 6: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/6.jpg)
Why so long?
![Page 7: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/7.jpg)
Killer Idea User Experience
Store Data
Social Integration
Push
Security
Scale
Versioning
API Geo Location
Analytics
Choose Technology
![Page 8: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/8.jpg)
Store Data
Social Integration
Push
Security
Scale
Versioning
API Geo Location
Analytics
Backend as a Service (BaaS)
![Page 9: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/9.jpg)
![Page 10: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/10.jpg)
Data
Auth Server Logic Scheduler
Logging & Diag
Scale
Notifications
![Page 11: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/11.jpg)
SDK’s• Windows Store
• Windows Phone 8
• iOS
• Android
• JavaScript
github.com/WindowsAzure/azure-mobile-services
![Page 12: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/12.jpg)
DemoCREATING A NEW MOBILE SERVICES APP
![Page 13: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/13.jpg)
Storage
Data
![Page 14: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/14.jpg)
Structured Storage Windows Azure SQL Database
Dynamic schema on/off
Apps partitioned by schema
REST API generated per table (very data centric platform)
Access your data through the portal, SQL Management studio or REST API
![Page 15: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/15.jpg)
JSON -> SQL data typesJSON value T-SQL type
Numeric values (integer, decimal, floating point) Float(53)
Boolean Bit
DateTime DateTimeOffset(3)
String Nvarchar(max)
![Page 16: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/16.jpg)
DemoUSING THE JAVASCRIPT SDK
![Page 17: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/17.jpg)
Server side Logic
![Page 18: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/18.jpg)
Server Logic – node.jsnode.js on small azure VM’s (azure websites infrastructure)
Server side pipeline hooks (interceptors)
Out of the box you have access to the following node packages
(June Release) - you now have access to NPM
request, console, push.*, tables, sql, statusCodes, azure, mssql
![Page 19: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/19.jpg)
Bypassing SQL Server storage 1. Virtual Tables
2 Create Custom API
![Page 20: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/20.jpg)
Notifications
Notifications
![Page 21: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/21.jpg)
Push Notifications The global push object is used to send push notifications.
Success & Error Callbacks are provided
Method
push. apns Apple Push Notification Service iOS apps
push. gcm Google Cloud Messaging Android apps
push. mpns Microsoft Push Notification Service Windows Phone 8 apps
push. wns Windows Notification Services Windows Store apps
![Page 22: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/22.jpg)
Push Notification Lifecycle
1. register app for push notifications
2. register the apple send token to Mobile Service
3. Server side script
push.apns(…)(1)
(2)
(3)
(3)
iOS
![Page 23: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/23.jpg)
DemoPUSH NOTIFICATIONS TO A WINDOWS STORE APP
![Page 24: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/24.jpg)
Authentication & Authorisation
Auth
![Page 25: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/25.jpg)
![Page 26: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/26.jpg)
AuthorisationTable level authorization for CRUD operations
Everyone: any request by anyone is accepted.Anyone with Application Key: app key distributed w/ the app (default)Authenticated Users: users authenticated by Live Connect.Scripts and Admins: registered scripts or requests via the master key
Application Key should not be used in production !
![Page 27: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/27.jpg)
CLI & Diagnostics
![Page 28: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/28.jpg)
Scheduler
Scheduler
![Page 29: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/29.jpg)
Cool Party Add-Ins from Azure Store
![Page 30: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/30.jpg)
Git publishing
![Page 31: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/31.jpg)
Running on shared instances
10 Mobile Services
1GB SQL Database
Data transfer is per subscription, not per mobile service
Unlimited ingress
165MB daily egress
Scheduler
700 jobs a month
Free offer for current preview release
![Page 32: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/32.jpg)
Resources Official Videos & Tutorials
http://www.windowsazure.com/en-us/develop/mobile/
Real world Use Cases & black belt tips
http://chrisrisner.com/Common-Scenarios-with-Windows-Azure-Mobile-Services
Mr Azure Mobile Services (Josh Twist)
http://www.thejoyofcode.com/
Cloud Nick ( Nick Harris )
http://www.nickharris.net/
![Page 33: Building mobile back ends with windows azure mobile services](https://reader030.fdocuments.in/reader030/viewer/2022012910/554d1e64b4c905ab268b4757/html5/thumbnails/33.jpg)
?