Developing Applications for SharePoint 2010
SharePoint 2010 introduces rich new areas of functionality that create more choices and fresh opportunities for developers and solution architects. Sandboxed solutions, new options for data modeling and data access, and new client programming models with Silverlight and Ajax integration offer a step change in what you can accomplish with SharePoint applications. This guidance provides a deep technical insight into the key concepts and issues for SharePoint 2010 solution developers.
Developing Applications for SharePoint 2010 (includes the Help file [CHM], samples, and library source code)
On This Page
Feedback and Support
Authors and Contributors
Developing Applications for SharePoint 2010 contains guidance documentation, detailed examples, and a reusable class library. These resources are designed to help solution developers and architects make the right decisions and follow proven practices when designing and developing applications for SharePoint 2010. The guidance focuses primarily on the building blocks that every developer needs to understand to become an effective SharePoint developer or architect. The following diagram shows the key areas that are covered within the guidance documentation, reference implementations, and reusable class library.
Key areas covered by Developing Applications for SharePoint 2010
The guidance documentation is divided into four core sections.
- Application Foundations for SharePoint 2010. This section describes approaches you can use to address the challenges of testability, flexibility, configuration, logging and exception handling, and maintainability; it also explains how to use the SharePoint Guidance Library components in these areas.
- Execution Models in SharePoint 2010. This section provides deep technical insights into the mechanics of the full-trust execution environment, the sandbox execution environment, and various hybrid approaches to executing code in SharePoint applications.
- Data Models in SharePoint 2010. This section explains new list and external data functionality, key design decision points that can help you to choose between standard SharePoint lists and external lists, and techniques and patterns to address large lists and list aggregation.
- Client Application Models in SharePoint 2010. This section provides guidance on how best to use the new client-side functionality to access data and build richer client experiences with Silverlight and Ajax.
Each section also contains a set of how-to topics. These explain how to perform specific tasks that the team found challenging to discover.
This release includes eight reference implementations that you can deploy to a SharePoint 2010 test environment and explore at your leisure. The reference implementations reinforce the key concepts in the guide and illustrate how to build applications that reflect real-world scenarios. Each reference implementation includes a detailed scenario and design overview, an explanation of the design decisions the team faced for the implementation, and an installation script to automate setup.
The SharePoint Guidance Library is a collection of reusable code–based utilities that address common challenges in application development for the SharePoint platform. You can use these components in your own SharePoint applications to help you improve your development speed and follow proven practices. The SharePoint Guidance Library consists of three key components:
- SharePoint Service Locator. This provides a simple implementation of the service location pattern for SharePoint applications. This enables you to isolate your code from dependencies on external types, which makes your code more modular, easier to test, and easier to maintain.
- Application Setting Manager. This provides a robust and consistent mechanism for storing and retrieving configuration settings at each level of the SharePoint hierarchy, from individual sites (SPWeb) to the entire server farm (SPFarm).
- SharePoint Logger. This provides easy-to-use utility methods that you can employ to write information to the Windows Event log and the SharePoint Unified Logging Service (ULS) trace log. It also enables you to create custom diagnostic areas and categories for logging.
Developing Applications for SharePoint 2010 helps developers and architects design and build robust SharePoint solutions. It addresses the fundamental building blocks for developing applications with SharePoint; it does not address vertical application areas such as Business Intelligence or Enterprise Content Management. The guidance may be particular useful in the following scenarios:
- If you are an experienced SharePoint 2007 developer or architect, the guidance is useful for learning the complexities and decision points for developers around the new functionality in SharePoint 2010.
- If you are an experienced developer who is new to SharePoint, the guidance will help you learn the details of SharePoint development in conjunction with other learning materials. It is not intended as an introductory guide, but it is a useful supplement to the product documentation.
- If you want to make your SharePoint 2010 applications more robust, the reusable components in the SharePoint Guidance Library will help you to improve the flexibility, testability, and manageability of your applications.
- If you want to start using unit testing or integration testing for SharePoint applications, the guidance can help you get started. The resources include a guide to testing SharePoint applications, together with a series of unit tests that use the Microsoft Research Moles framework, which runs within Visual Studio Unit Test.
The guidance documentation, reference implementations, and reusable components were written with the experienced SharePoint developer in mind, and they will derive the most immediate benefit from the guidance. To get the most benefit from the guidance, you should have an understanding of the following:
- Microsoft Visual C#
- Microsoft .NET Framework
- Microsoft SharePoint development
Experienced developers who are new to SharePoint and experienced IT professionals will also benefit from many areas of the guidance. However, some of the deeper topics require an established understanding of SharePoint.
Most of the content contained in this release relates to new areas of functionality in SharePoint 2010. The SharePoint Guidance Library was included in the previous SharePoint Guidance release, but it has been updated to run within the SharePoint 2010 sandbox environment wherever possible.
The reusable components of the SharePoint Guidance Library will run in any edition of SharePoint 2010, including SharePoint Foundation 2010. To install the reference implementations, you will need a test environment with the following software:
- Visual Studio 2010 Professional Edition or higher
- Windows 7, Windows Server 2008R2, or Windows Server 2008
- SQL Server 2008 or SQL Server 2008R2 Express Edition or higher
- SharePoint Server 2010 Enterprise Edition, SharePoint Server 2010 Standard Edition, or SharePoint Foundation 2010
Note: Several reference implementations will not work in SharePoint Foundation.
The reusable components of the SharePoint Guidance Library, together with the patterns and approaches described in the guidance documentation and the reference implementations, are designed to help your applications meet the following goals:
- Efficiency. You can improve the efficiency of your applications by following proven practices and application patterns, and by understanding the performance implications of various design choices.
- Manageability. You can improve the manageability of your applications by using design patterns and components that reduce dependencies between classes. This makes it easier to maintain your code in a constantly evolving code base.
- Testability. You can improve the testability of your applications by using design patterns and components that enable you to test classes and business logic in isolation.
The best way to get started with Developing Applications for SharePoint 2010 is by reading the documentation. The documentation will lead you through the key concepts and then direct you to the reference implementations that demonstrate these concepts. Start with the introductory section, which provides a deeper overview of the topics covered by the guidance. After reading the introductory section, you can jump to an area of particular interest, such as data models, client application models, or execution models. To get the most value from the documentation, read each section from the start, because the key concepts are developed throughout each section. The reference implementation documentation provides a detailed description of the key points, but the implementation will be best understood if you have already read the associated topics in the guidance.
This guidance, like many patterns & practices deliverables, is associated with a community site. On this community site (http://spg.codeplex.com/), you can post questions, provide feedback, or connect with other users for sharing ideas. Community members can also help Microsoft plan and test future guidance, and download additional content such as extensions and training material.
This release provides a broad baseline for SharePoint 2010 development and design guidance, but there are still many areas to cover. Upcoming releases will focus on smaller, more specific areas that build on this baseline. The team intends to move to smaller more frequent releases in the coming year, focusing on areas such as claims-based authentication and solution development for hosted SharePoint environments.
Feedback and Support
Questions? Comments? Suggestions? To provide feedback about this guidance, or to get help with any problems, please visit the Developing Applications for SharePoint 2010 Community site. The message board on the community site is the preferred feedback and support channel because it allows you to share your ideas, questions, and solutions with the entire community. Developing Applications for SharePoint 2010 is a guidance offering, designed to be reused, customized, and extended. It is not a Microsoft product. Code-based guidance is shipped "as is" and without warranties. Customers can obtain support through Microsoft Support Services for a fee, but the code is considered user-written by Microsoft support staff.
Authors and Contributors
Developing Applications for SharePoint 2010 was produced by the following individuals:
- Program and Project Management: Chris Keyser, Hanz Zhang
- Architecture and Development: Todd Baginski (Fresh Tracks Consulting, LLC), Shawn Beeson (RBA Consulting), Rob Bogue (Thor Projects), Francis Cheung, Chris Keyser, Hernan de Lahitte (Digit Factory S.R.L.), Mariano Grande (Digit Factory S.R.L.)
- Test team: Sateesh Babu Chakka (Tata Consultancy Services), Durga Mohan Palika (Tata Consultancy Services), VenkataAppaji Sirangi (Tata Consultancy Services), Venkata Siva Krishna Yellapragada (Tata Consultancy Services), Hanz Zhang
- Documentation: Jason Lee (Content Master)
- Edit team: Tina Burden (TinaTech, Inc.), RoAnn Corbisier, Sharon Smith (Tina Tech, Inc.), Nancy Michell (Content Master)
- Illustrations: Rob Nance (Filter Talent), Katie Niemer (TinaTech, Inc.)
- Release Management: Richard Burte (Channel Catalyst)
We want to thank our customers, partners, and community members who reviewed our early drafts, source code, and participated in biweekly reviews. Among those, we would like to highlight the contributions of Reza Alirezaei (Development Horizon Corp.), J. Dan Attis (B&R Business Solutions), Darrin Bishop (Darrin Bishop Group, Inc.), Todd C. Bleeker, Jackson Chackungal (MindTree Ltd.), Eric Charran (Microsoft), Michael Chorey (Avanade), Andrew Connell (Critical Path Training, LLC), Spencer Harbar (Triumph Media Limited), Scot Hillier (Scot Hillier Technical Solutions, LLC), Mike Huguet (Sparkhound, Inc), Vesa Juvonen (Microsoft), Balakrishnan Krishnamoorthy (Cognizant), Roger Lamb (Microsoft), David Mann (Mann Software), Matthew McDermott (AbleBlue), Chris O’Brien (Context Aware Ltd.), Maurice Prather (Maurice Prather, Inc.), Paul Schaeflein (LaSalle Consulting Partners, Inc.), Eric Shupps (BinaryWave), Trent Swanson (Microsoft), Erwin van der Valk (Achmea), Ethan Wilansky (FTI Technology), and Andrew Woodward (21apps).
We want to thank Microsoft product team members for reviews, technical input, and answering many questions. Among those, we would like to highlight the contributions of Michael Ammerlaan (SharePoint), Paul Andrew (SharePoint), Juan Balmori (SharePoint), Phillip Beish (SharePoint), Sumant Bhardvaj (SharePoint), Michael Cheng (SharePoint), Reza Chitsaz (Visual Studio), Gabe Hall (SharePoint), Peli de Halleux (Microsoft Research), Ivan Han (SharePoint), Rob Howard (SharePoint), Eilene Hao Klaka (SharePoint), Peter Harwood (SharePoint), Randall Isenhour (SharePoint), Daniel Roth (WCF), Yimeng Li (SharePoint), Maxim Lukiyanov (SharePoint), Andrew May (SharePoint), Thomas Mechelke (SharePoint), Mike Morton (Visual Studio), Elisabeth Olson (SharePoint), Adam Outcalt (SharePoint), Iouri Simernitski (Visual Studio), Brad Stevenson (SharePoint), and James Sturms(SharePoint).