building ios apps with windows azure mobile services
DESCRIPTION
Building iOS Apps with Windows Azure Mobile Services. Chris Risner Technical Evangelist Microsoft. http://chrisrisner.com @ chrisrisner. What is Windows Azure Mobile Services?. Auth. Data. Notifications. Logging & Diag. Server Logic. Scheduler. Scale. @ chrisrisner. - PowerPoint PPT PresentationTRANSCRIPT
![Page 1: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/1.jpg)
Building iOS Apps with Windows Azure Mobile ServicesChris RisnerTechnical EvangelistMicrosoft
http://chrisrisner.com@chrisrisner
![Page 2: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/2.jpg)
What is Windows Azure Mobile Services?
Data
Notifications
Auth
Server Logic
Scheduler
Logging & Diag
Scale
@chrisrisner
![Page 3: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/3.jpg)
Getting Started a backend for your mobile app in minutes Demo
![Page 4: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/4.jpg)
Structured StorageStructured Storage with SQL DatabaseIf using single database apps are partitioned by schema
AppX.TodoitemAppY.Todoitem
Manage data inPortal, SQL PortalSQL Management StudioREST APICLI Tools
@chrisrisner
![Page 5: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/5.jpg)
Server LogicAutomatic service REST API generated for storageDynamic Schema on/offAbility to author server logic that intercepts CRUD operation pipeline
@chrisrisner
![Page 6: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/6.jpg)
Server LogicSupported Modules + Globals
mssqlrequestconsolepushtablesstatusCodes
mssql.query('select top 1 * from statusupdates', { success: function(results) { console.log(results);
} }
);
@chrisrisner
![Page 7: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/7.jpg)
REST API to SQL type mappingsJSON Value T-SQL TypeNumeric values (integer, decimal, floating point)
Float
Boolean BitDateTime DateTimeOffset(3)String Nvarchar(max)
@chrisrisner
![Page 8: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/8.jpg)
Server Logicadding server logic on CRUD
operations Demo
![Page 9: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/9.jpg)
Push Notification Lifecycle Overview 1. Register for push
notifications2. Register with your
send token to Mobile Service
3. Push from server side scripts
iOS(1)
(2)
(3)(3)
@chrisrisner
![Page 10: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/10.jpg)
Push NotificationsDemo
![Page 11: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/11.jpg)
Auth*Authenticate against multiple providersTable level permissions for each CRUD operation
EveryoneAnyone with the Application KeyOnly Authenticated UsersOnly Scripts and Admins
More granular control with server side scriptsuser.level: {admin, authenticated, anonymous}user.userId: id or undefined if not authenticated@chrisrisn
er
![Page 12: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/12.jpg)
Adding Authenticationintegrating with Twitter Demo
![Page 13: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/13.jpg)
SchedulerExecute scripts on a Schedule
by Minutesby Hoursby DaysBy Months
Execute scripts on DemandExamples Periodic purge of old data Poll and aggregate from 3rd party (Twitter, RSS, others) Process/resize images Schedule sending push notifications for a given time of day @chrisrisn
er
![Page 14: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/14.jpg)
Scheduling a taskDeliver a push notification Demo
![Page 15: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/15.jpg)
Diagnostics, Logging and ScaleDiagnosticsAPI callsCPU TimeData Out
Loggingconsole.error(…)console.log(…)…
Scale - ComputeScale out instance countScale up VM size
Scale - StorageScale out mobile service tenant to dedicated SQL DBScale up SQL DB
@chrisrisner
![Page 16: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/16.jpg)
Diagnostics, Logging, Scale
Demo
![Page 17: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/17.jpg)
Pricing during Previewreserved mode
service level agreements
PreviewNo availability SLA*
General Availability99.9%
Shared Instance
Small instance is the only size availableFree - 10 applications with unlimited inbound data. Capped max of 165MB outbound data/dayPay - SQL Database
Private VM
Small instance is the only size available Free - unlimited inbound data. 165MB outbound data/day, excess charged. Pay - SQL Database, Compute same reduced rate as Web Sites i.e 33% discount, excess outbound transfers starting at $0.12/GBUp to 100 applications
shared mode
@chrisrisner
![Page 18: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/18.jpg)
Pricing Example:
10 x Mobile Services on shared instances
100MB SQLDatabase
Unlimited ingress
<165MB daily egress
How?10 FREE mobile services on shared instanceIncludes 165MB/day of FREE egress from API calls Cost - All services sharing a 100MB DB is $5 USD / Month Use Pricing Calculator to Estimate your costs
=$5/ Month
Note: Free Egress is per subscription, not per mobile service
![Page 19: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/19.jpg)
Don’t forget: Member OffersMSDN Subscribers up to $3700 / yearBizSpark members up to $3700 / yearMPN Members up to $1500 / yearWebsiteSpark up to $1500 / year
Full details here - http://www.windowsazure.com/en-us/pricing/member-offers/
@chrisrisner
![Page 20: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/20.jpg)
Summary
Data
Notifications
Auth
Server Logic
Scale
Logging
Diagnostics
@chrisrisner
![Page 21: Building iOS Apps with Windows Azure Mobile Services](https://reader036.vdocuments.site/reader036/viewer/2022062411/56816724550346895ddbae43/html5/thumbnails/21.jpg)
Useful ResourcesGet a Windows Azure Free Trial Accounthttp://www.windowsazure.com/
Learn more & try tutorialsTutorials, Samples, Reference Docs: http://www.windowsazure.com/mobile
Help with Mobile ServicesQ&A Forum: Windows Azure Mobile Services ForumFeature Rqst: Windows Azure Mobile Services UserVoiceFeedback: [email protected]: @chrisrisner and @cloudnick
Presentations, demos, hands on labsWindows Azure Training Kit: Download here