Sascha P. Corti Developer Evangelist Microsoft Switzerland mail: [email protected] blog: http://www.corti.com/weblogsascha team: http://blogs.msdn.com/swiss_dpe_team Expressive and standards-compliant Better developer/designer collaboration Secure, scalable platform.
Download ReportTranscript Sascha P. Corti Developer Evangelist Microsoft Switzerland mail: [email protected] blog: http://www.corti.com/weblogsascha team: http://blogs.msdn.com/swiss_dpe_team Expressive and standards-compliant Better developer/designer collaboration Secure, scalable platform.
Sascha P. Corti Developer Evangelist Microsoft Switzerland mail: [email protected] blog: http://www.corti.com/weblogsascha team: http://blogs.msdn.com/swiss_dpe_team Expressive and standards-compliant Better developer/designer collaboration Secure, scalable platform LINQ – Integrated query support for Objects, SQL, DataSets, and XML WCF support for REST and JSON services WCF & WF integration Syndication object model Managed Add-in framework (System.AddIn) XBAP support for Firefox ASP.NET AJAX Integration Client Application Services Visual Studio 2008 supports targeting multiple versions of the .NET Framework Choose which Framework version to target when opening or creating an application .NET Framework 2.0 .NET Framework 3.0 .NET Framework 3.5 Visual Studio IDE only shows feature appropriate for your selected target version Toolbox, Add New Item, Add Reference, Intellisense IDE Enhancements Split View Mode View source and design side-by-side Updates in real time Performance improvements Reduced lag during switch between views Nested master page support http://www.oswd.org Dramatically simplifies Building and Managing CSS Styles. Intuitive Visual Designer Summary Mode helps track where styles are being applied Shares same CSS engine as Expression Web Developers and Designers have access to same features New Styling Dialog JavaScript? AJAX, Silverlight, Live.com APIs Intellisense in Code Editor Type Inference Intellisense Hints Intellisense for External Libraries Debugging Support Breakpoints directly in .html, .js, .aspx or .master Attach to Internet Explorer to debug JavaScript on any page (HTML, PHP, JSP, etc.) Basic AJAX Controls Part of every Web Project in VS 2008 Profit from JavaScript Support Team System Web Tests now captures Script-Generated HTTP-Requests ASP.NET AJAX Control Toolkit New Extender Wizard 1980s: Query Languages (Dbase) Data Manipulation = Core Part of Programming Model Late 1990s / Early 2000s Data Access APIs Last few Years Object / Relational Mapping LINQ Query, Set and Transform Operations for .NET Makes querying data a core programming concept Works with all types and shapes of data Relational databases XML Plain old Objects Works with all .NET languages New VB and C# have integrated language support New ASP.NET Data Controls <asp:ListView> <asp:LinqDataSource> <asp:DataPager> New Project Item that creates a default AJAX-enabled WCF Service Update existing WCF Services via Attribute Make Communication Format AJAX friendly (i.e., JSON or REST) ScriptManager supports the registration of WCF& ASMX- Services Data Access Preview Build ASP.NET 3.5 Extensions (Preview) ASP.NET Model View Controller ASP.NET AJAX Enhancements + Silverlight Controls ASP.NET Dynamic Data ADO.NET Data Services Codename “Oryx” Codename “Astoria” .NET Framework 3.5 LINQ WF & WCF Enhancements Add-in Framework ADO.NET Entity Framework Additional Enhancements .NET Framework 3.0 + SP2 WPF WCF WF Windows CardSpace .NET Framework 2.0 + SP2 ASP.NET AJAX History & Navigation Updated Validators, TreeView, Menu and WebParts Back Button support for all Browsers Script Combining Script File- and Resource- Scripts Script ASP.NET Silverlight Controls ASP:Silverlight Control Script Script Automate client installation and creation of Silverlight plugin Silverlight plugin Helper Classes Easily instantiate Silverlight plugin programmatically ASP:MediaPlayer Embed video instantly with variety of skins included Script Ability to create and consume datacentric, RESTful services. Data Services are Specialized WPF Services Expose data as a URI-addressable resources .NET Client Library http://host/MyDS.svc/Customers(492)/Orders Services use URIs to locate and identify data AJAX Client Library Silverlight Client Library Data Service Use URI parameters to filter, page, sort data Use HTTP verbs to interact with resources IQueryable GET, PUT, POST, or DELETE Data can be represented in JSON or ATOM Publishing Protocol (AtomPub) formats – specified by the client Simplifies data connectivity for AJAX and Silverlight apps Enable the creation of Web Applications using the Model-View-Controller Pattern Provides an Alternative for building Web Applications on ASP.NET Clean Separation of Concerns Full Control over Markup and Rendering Controller Highly pluggable and extensible Enables testability and TDD Model Works with .aspx and .ascx as views But no server controls, postbacks, viewstate View Provide the Web App scaffolding to build rich, data-driven Web applications Dynamically constructs Pages based on the Data Model of the Underlying Database Provides a usable Application with no Code, but can easily be customized Dynamic Data App consists of three Components: Data Model – LINQ to SQL mapping file Page templates – ASPX pages that provide default views of data Dynamic Data Fields – User Controls for rendering individual fields Provides a view of the Data based on Default Templates Templates use the data model to determine the correct controls to display and their behavior AJAX-enabled templates provide filtering, paging, and validation Faster, Easier Development Functional testing for ASP.NET AJAX and JavaScript Integrated code metrics Improved performance and scalability profiling Less Effort, More Effect A powerful, new HTML designer CSS management JavaScript debugging and Intellisense Better support for working with data ListView control LinqDataSource Breakthrough User Experiences ASP.NET AJAX built-in Enhanced AJAX functionality Better interoperability with WebParts, <asp:treeview>, <asp:menu>, etc Nested master pages New ListView control © 2007 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. The Challenge AJAX-enabled web applications are very popular, but their asynchronous nature makes testing them very difficult The Solution Visual Studio 2008 Team System enables team members to target even the most complex AJAX applications – HTTP requests, whether user or script generated are captured as part of the web test .NET Framework 3.5 WF & WCF Enhancements LINQ Add-in Framework Additional Enhancements .NET Framework 3.0 + SP1 Windows Presentation Foundation Windows Communication Foundation Windows Workflow Foundation Windows CardSpace .NET Framework 2.0 + SP1 ASP.NET AJAX History & Navigation Updated Validators, TreeView, Menu and WebParts Back button support for all browsers Client and server APIs Manage history titles Create Permalinks with state Script Combining Script Supports Fileand Resourcebased Scripts. Script Script Script Script ASP:Silverlight control Automate client installation and creation of Silverlight plugin AJAX classes for programming with Silverlight Silverlight plugin helper classes Easily instantiate Silverlight plugin programmatically Interact with Silverlight on the client or server ASP:MediaPlayer Embed video instantly with variety of skins included Easily customize the XAML Works with Expression Encoder Add chapter annotations and captions Localize content Handle custom media markers in the stream The Entity Framework is a set of technologies that simplify the development of flexible data-oriented applications. Provides an intrinsic layer of abstraction over a database called the Entity Data Model (EDM) Developers code against conceptual entities representing the data Conceptual entities are mapped to the database schema Mapping is explicit and can be changed Benefits: Abstracts developers from the underlying database tables and columns where the data is stored Exposes data in the form of domain-specific object Isolates and minimizes impact of changes between app and data Decreases the amount of code and maintenance required LINQ to Entities Entity Data Model Abstraction over a relational database Consists of conceptual & logical models Provides mapping layer between conceptual model and logical model Entity Client Provides classes similar to ADO.NET Providers Can return results as DbDataReaders Entity SQL Textual SQL language for dynamic queries Object Services Enables you to work with object instances Provides persistence and change tracking LINQ to Entities Provides LINQ syntax and strongly-typed objects for queries over EDM Object Services Entity SQL Entity Client Entity Data Model Conceptual Models Logical Models Mapping ADO.NET Data Services provides the ability to create and consume data-centric, RESTful services. Expose data as a URI-addressable resources i.e. http://host/NorthwindDataService.svc/Customers(492)/Orders Services use URIs to locate and identify data URIs can be used to traverse associations Clients can filter, page, & sort data by specifying parameters on the URI Apps can interact with the resources using HTTP verbs GET, PUT, POST, or DELETE Data can be represented in JSON or ATOM Publishing Protocol (AtomPub) formats – as specified by the client Simplifies data connectivity for AJAX and Silverlight apps Client-side libraries for .NET, AJAX, & Silverlight Any HTTP client can consume the services .NET Client AJAX Silverlight URIs can map to Library Client Library Client Library entities in EDM Client libraries abstract clients from Data Service URI syntax Data Services are IQueryable specialized WCF services Extensions to ASP.NET that enable the creation of web applications using the model-view-controller pattern Encourages a clean separation of concerns amongst the portions of your application Makes practices like Test-Driven Development substantially easier to adopt Leverages the ASP.NET Routing engine, giving you full control over your application’s URIs Completely extensible framework that allows you to modify every aspect of the pipeline if needed Provides an Alternative for building Web Applications on ASP.NET Clean separation of concerns Full control over markup and rendering Highly pluggable and extensible Enables testability and TDD Works with .aspx and .ascx as views But no server controls, postbacks, viewstate View Controller Model ASP.NET Routing Pipeline Request URL Routing Engine Route Route Handler Controller Factory Controller Builder Http Handler Controller View Factory Response View Note: Each step highlighted in yellow represents a point of extensibility. UrlRoutingModule 3 Request MvcRouteHandler 4 1 URL Controller Handler /Customers/Edit/3 Customers MvcRouteHandler 2 6 Routing Table 5 Global.asax – Application_Start 8 Model Controller 7 View Response Provide the Web App scaffolding to build rich, data-driven Web applications Dynamically constructs pages based on the data model of the underlying database Provides a usable application with no code, but it can easily be customized Dynamic Data App consists of three components: Data Model – LINQ to SQL mapping file Page templates – ASPX pages that provide default views of data Dynamic Data Fields – user controls for rendering individual fields Provides a view of the data based on default templates Templates use the data model to determine the correct controls to display and their behavior AJAX-enabled templates provide filtering, paging, and validation The Challenge All my services are being re-written with WCF – how does my ASP.NET application call them? The Solution Visual Studio 2008 provides a new project item that creates a default AJAX-enabled WCF service Existing WCF services can be decorated with an attribute to convert their communication format to something that is AJAX friendly (i.e., JSON or REST) Also, in Visual Studio 2008, the ScriptManager supports the registration of WCF services as well ASMX Microsoft's next-generation platform for distributed systems A set of extensions to the Microsoft.NET Framework 2.0 Build WCF services in Visual Studio 2008 using any .NET Language Intelligent code editing, IDE Extensions for WCF, debugging, refactoring, code snippets, etc. Visual Basic .NET, Visual C#, etc. Runs on Microsoft Windows Vista Microsoft Windows XP Microsoft Windows Server 2003 Microsoft Windows Server 2008 Part of .NET 3.0 and .NET 3.5 SOAP, POX, WS-*, Web (or REST), Syndications View as part of the same ecosystem WS-* SOAP, WS-*, and POX via WCF in .NET 3.0 SOAP POX REST RSS ATOM Web, Syndications via WCF in .NET 3.5 New Project Item Attribute that makes this WCF service AJAX-callable Faster & Easier Development The Challenge How do developers know they are writing code that can be maintained and understood in the future? The Solution Visual Studio 2008 Team System integrates sophisticated code metrics that enable developers to clearly understand how maintainable and complex the code they are building is; This understanding is gathered from the following metrics Cyclometic complexity Maintainability Index Inheritance Depth Class Coupling Lines of code The Challenge Code reviews are time consuming, error prone and depends on ‘group’ knowledge The Solution Code analysis examines every path code might take; looking for known problems and concerns; This feature has been greatly enhanced in Visual Studio 2008 Better discoverability of the feature through the Developer top-level menu More flexible warning suppressions Code analysis report comparison Enhanced code analysis check-in policy Code-aware spell checker The Challenge Understanding data gathered by a profiler is difficult and tedious The Solution In Visual Studio 2008 Team System, the industrial strength profiler has been enhanced across the board; this includes New data collection control WCF support However, probably its most notable features is its ability to visually compare performance data Compare 2 performance reports against each other Dynamically control how performance data is gathered. Insert ‘marks’ which help you correlate data Use this layout to show software code The font is Courier, a monospace font The slide doesn’t use bullets but levels can be indented using the “Increase List Level” icon on the Home menu Name Title Group Name Title Company Name Title Company