320 likes | 523 Views
BB05. Live Services: Building Applications With The Live Framework. Raymond Endres Development Manager Microsoft Corporation. Agenda. Live Framework (Live fx ) Overview Live Framework API Kits Live Framework .NET Kit. Key Concepts.
E N D
BB05 Live Services: Building Applications With The Live Framework Raymond Endres Development Manager Microsoft Corporation
Agenda • Live Framework (Live fx) Overview • Live Framework API Kits • Live Framework .NET Kit
Key Concepts • Live fx is the uniform way to program Live Services • Any platform, • Any programming language • Any application or device • Live fx makes it easy to build software + service applications • .NET developers can use the Live fx API kit to build applications
Introducing AzureA comprehensive hosted platform for your applications and services Azure™ Services Platform
Live Services Users Devices Applications Synchronization Mesh Services Identity Directory Storage Communications and Presence Search & Geospatial
Live Framework gives developers… • Cloud/Client/Device reach • Access to user-data • Application ecosystem • Easy to get started
Live Framework Scenarios • Integrate Live Services into your applications • Opt in to as much of the Live Framework as you like • Expose your application as Mesh Applications • Reach • applications • Rich • Applications
Live Framework Libraries Resource Model Open formats, protocols and operations Core Data Communications App Model Tools and Services Live Operating Environment
Live Framework Libraries Tools & Services .NET FX 3.5 APIs Silverlight APIs JavaScript APIs Client Controls Web Controls … Resource Model Developer Portal ATOM JSON POX RSS Binary XML AtomPub FeedSync CRUD Sync URI-LINQ Resource Scripts Triggers Auth/Z Hosting Introspection Provisioning / Account Management Data Core Communications App Model User Mesh Identity P2P Catalog Folders News Device Mesh Notifications Hosting Photos Favorites Applications Presence Mesh Applications Contacts Lists Visual Studio Tools / Designers App Data & Settings Profile Calendar Application Management System Mapping Search Analytics Live Operating Environment CRUD Sync Hosting CRUD Sync App Hosting Resource Script Engine Auth/Z Local Store Resource Script Engine Auth/Z Analytics Developer Sandbox P2P File Sys … Cache … Client Cloud Windows® Azure™ Windows Embedded Windows Mobile Other
demo Showing the Mesh Board application
Live Framework API Kits • A set of libraries which can be used to program Live fx • .NET, Silverlight and JavaScript Libraries available today • Work on various platforms and programming languages .NET FX 3.5 APIs Silverlight APIs JavaScript APIs Client Controls Web Controls …
Live Framework .NET KitDesign goals • Expose the core Live Services in a cohesive and consistent way • Make it easy and natural for .NET developers to consume Live Services • Offer a symmetrical programming model between client and server
Resource Model LOE End-Point Mesh Objects Notification Queue News Applications Devices Contacts Mesh Scripts Profiles Members Mappings Data Feeds News Subscription Data Entry Data Entry Media Resources
demo Understanding Feeds
Live Framework .NET KitAccessing Live Data • LiveOperatingEnvironment class • Main entry point to all the Live Services • Connect your application to the runtime endpoint • Sync and asynchronous patterns available • Local or remote connections available • Set pre-fetch policy at connect time public static void Connect (NetworkCredentialscreds) { Uri uri = new Uri(“https://user-ctp.windows.net”); • LiveOperatingEnvironmentloe = new LiveOperatingEnvironment(); • loe.Connect(creds) • } • foreach (Contact contact in loe.Contacts.Entries) • { • Console.WriteLine(contact.Resource.DisplayName); • }
Live Framework .NET KitAccessing Live Data • Users control their data • Rich applications work on behalf of users • Web applications require delegated authentication • Mesh enabled web apps are sandboxed
demo Connecting to Live fx
Live Framework .NET KitManaging application data • Mesh Object • Container of application defined data • Fundamental unit of extensibility, sync and sharing • Can be replicated across a set of devices • Can be shared among a set of users and applications • Contains: • DataFeeds , Members, Mappings, News, Activities MeshObjectpokerObj = new MeshObject("PokerInfo"); PokerChip chip = new PokerChip(); pokerObj.Resource.SetUserData<PokerChip>(chip); loe.Mesh.MeshObjects.Add(ref pokerObj); public class PokerChip { public intNumberOfChips { get; internal set; } }
Live Framework .NET KitManaging application data • DataFeed • Stores application information • Metadata and blobs • Has replication and sync capabilities • An application may CRUD feeds at any time • Receives update information • A mesh object can have any number of data feeds • DataFeed feed = new DataFeed(); • feed.Resource.Type = “LiveMeshFolder”; • feed.Resource.HandlerType = “FileSystem”; • meshObject.DataFeeds.Add(ref feed);
demo Creating Mesh Board
Live Framework .NET KitSharing data • Members • Represents a Live ID’s membership in the MeshObject • New members have to be invited to be part of the Resource • Has a role based within the object • Full, Writer, Reader • foreach (Member member in meshObject.Members.Entries) • { • Console.WriteLine(member.Resource.Title); • Console.WriteLine(member.Resource.InvitationAccepted); • Console.WriteLine(member.Resource.Role); • }
Live Framework .NET KitSharing data • FeedSync • Synchronization via RSS and Atom feeds • Lightweight and extensible • Supports multi-master • Delivers same result at all endpoints • Protocol independent • Preserves conflicting data • Diverse implementations encouraged • Creative Commons • Microsoft Open Specification Promise
demo Inviting Users
Live Framework .NET KitTaking applications offline • Local endpoint • Leverage the Symmetrical APIS • Same APIs are used in the local and cloud end point • Change the target URL to be local • Mesh Service takes care of the data synchronization • public static void Connect (NetworkCredentialscreds) • { • LiveOperatingEnvironmentloe = new LiveOperatingEnvironment(); • //loe.Connect(creds) • loe.ConnectLocal(); • }
demo Rich Client Application
Summary • Live fx is the uniform way to program Live Services • Any platform, • Any programming language • Any application or device • Live fx makes it easy to build software + service applications • .NET developers can use the Live fx API kit to build applications Start using the preview today, we want your feedback !!
Related Sessions (Live Services) • BB04 - A Lap Around the Live Framework and Mesh • BB41 - What I Learned Building My First Mesh App • BB19 - Live Framework Architecture and Insights • BB51 - Programming Live Services Using Non-Microsoft Technologies • BB06 - Mesh Services Architecture • BB30 - Building Mesh-Enabled Web Apps • BB31 - FeedSync and Mesh Synchronization Services • BB35 - The Future of the Device Mesh • BB34 - Notifications, Awareness, and Communications
Evals & Recordings Please fill out your evaluation for this session at: This session will be available as a recording at: www.microsoftpdc.com
Q&A Please use the microphones provided
© 2008 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.