App store optimization(optimize for app store search engines
Making your Windows Store app more reliable
description
Transcript of Making your Windows Store app more reliable
![Page 1: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/1.jpg)
![Page 2: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/2.jpg)
Making your Windows Store app more reliableHarry PiersonSenior Program Manager, Runtime Experience Team@devhawk3-136
![Page 3: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/3.jpg)
Good ratings and reviews are critical to the success of your Windows Store app.
![Page 4: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/4.jpg)
Unreliability is the top reason why users give apps bad ratings and reviews.
Freeze
s
Crashe
s
Slow Resp
onsiv
eness
Heavy
Battery
Usage
Too M
any A
ds0
1020304050607080
Source: Apigee 2012 Mobile App Review Survey
![Page 5: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/5.jpg)
Bad things happen to good apps.
Reliability is a continuing process.
![Page 6: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/6.jpg)
Monitor and regularly improve the quality of your app in order to avoid the #1 cause of bad reviews.
![Page 7: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/7.jpg)
Quality telemetry and the Windows Dev CenterAdding logging to your appNew Windows Runtime error and logging APIsEnd-to-end demo
Agenda
![Page 8: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/8.jpg)
Regularly review your app’s quality telemetry on the Windows Dev Center.
![Page 9: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/9.jpg)
Microsoft automatically collects analytics and telemetry data about your Windows Store app.
![Page 10: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/10.jpg)
![Page 11: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/11.jpg)
![Page 12: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/12.jpg)
![Page 13: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/13.jpg)
![Page 14: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/14.jpg)
Error reports are not as useful as you might think.
![Page 15: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/15.jpg)
Take advantage of the new logging and error APIs to keep track of what is happening inside your application.
![Page 16: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/16.jpg)
Logs can provide temporal context needed to diagnose issues that occur on customers’ machines.Windows 8.1 includes a new logging API that’s very simple to use.
![Page 17: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/17.jpg)
Circular Memory Buffer
Keep a running log of recent events.
Save and send that log when an error is detected.
Logging to memory
Logging SessionLogging
Channel
Logging Channel
Logging Channel
Logging Channel
Error
Log File
Your Backen
dSaveToDiskAsync
Background Uploader
![Page 18: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/18.jpg)
LoggingChannel examplevar channel = new LoggingChannel ("ChannelName");channel.LoggingEnabled += (sender, args) => { _isLoggingEnabled = sender.Enabled; _channelLoggingLevel = sender.Level; }
var level = LoggingLevel.Error;if (_isLoggingEnabled && level >= _channelLoggingLevel) { channel.LogMessage("Message to log", level); channel.LogValuePair("Count", 42, level); }
var channel = new LoggingChannel ("ChannelName");channel.LoggingEnabled += (sender, args) => { _isLoggingEnabled = sender.Enabled; _channelLoggingLevel = sender.Level; }
![Page 19: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/19.jpg)
LoggingSession examplevar session = new LoggingSession("Session Name");session.AddLoggingChannel(channel, LoggingLevel.Warning);
//when error detected, save the log session to disk then uploadStorageFile logFile = await session.SaveToFileAsync(logFolder, name)//background uploader code omitted
![Page 20: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/20.jpg)
Memory Buffer
Log all events to disk.
Send log file when file reaches a specified size.
Flush log memory buffer to disk on crash and send just like in the log to memory example.
Logging to disk
File Logging SessionLogging
Channel
Logging Channel
Logging Channel
Logging Channel
Log File
Your Backen
d
Background Uploader
File Size Limit reached
Log File
![Page 21: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/21.jpg)
FileLoggingSession examplevar session = new FileLoggingSession("Session Name");session.AddLoggingChannel(channel, LoggingLevel.Warning);
session.LogFileGenerated += (senders, args) => { //when file generated, move it so it doesn’t get overwritten await args.File.MoveAsync(logFolder); //background uploader code omitted}
//Flush log to disk on demandvar file = await session.CloseAndSaveToFileAsync();
![Page 22: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/22.jpg)
Windows 8.1 improves exception interop and provides a mechanism to observe unhandled errors before process termination.
![Page 23: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/23.jpg)
Use XAML’s UnhandledException event if you wish, especially if you’re a managed developer.
CoreApplication.UnhandledErrorDetected is better for C++ developers and logging components.
![Page 24: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/24.jpg)
UnhandledErrorDetected exampleCoreApplication.UnhandledErrorDetected += (sender, args) => { try { args.UnhandledError.Propagate(); } catch (Exception ex) { channel.LogMessage(ex.Message, LoggingLevel.Critical); //code to save log and background upload omitted throw; }};
![Page 25: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/25.jpg)
XAML’s UnhandledException exampleApp.Current.UnhandledException += (sender, args) => { channel.LogMessage(args.Exception.Message, LoggingLevel.Critical); //code to save log and background upload omitted};
![Page 26: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/26.jpg)
Demo: Add logging code to my app
![Page 27: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/27.jpg)
Monitor and regularly improve the quality of your app in order to avoid the #1 cause of bad reviews.
![Page 28: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/28.jpg)
Regularly review your app’s quality telemetry on the Windows Dev Center.
Log what is happening inside your application.
Take advantage of new logging and error APIs in Windows 8.1
Summary
![Page 29: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/29.jpg)
Related Sessions2-138 – Improve Application Health by Leveraging Crash Analytics Collected from End Users3-133 – Testing your C#-based Windows Store app: Top 10 areas to look for bugs 4-107 – Windows Runtime Internals: Understanding the threading model
![Page 30: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/30.jpg)
Evaluate this session
Scan this QR code to evaluate this session and be automatically entered in a drawing to win a prize!
![Page 31: Making your Windows Store app more reliable](https://reader036.fdocuments.us/reader036/viewer/2022081507/56816128550346895dd080f8/html5/thumbnails/31.jpg)
© 2013 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries.The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.