Jeremy Thake, Enterprise Architect at AvePoint Inc and SharePoint MVP, will explain the principles of Application Lifecycle Management in SharePoint 2010. The session will suit SharePoint Developers, Team Leaders, Architects and Development Managers to understand how to approach ALM with SharePoint.The pillars of ALM will be discussed in detail and the benefits of each from a Solution perspective.The ALM maturity model will be presented to allow you to evaluate where you are in your own internal processes and how to mature these further.The NothingButSharePoint.com Project ALM approach will be discussed in detail as a case study, which involves global distributed development teams and designers. The pros and cons of this approach will be compared to the others. Common problems with promoting from Dev to Staging to Production will be discussed in detail.From this session you should walk away with:· An understanding of what application lifecycle management is· An understanding of the approaches to ALM with SharePoint Development· An understanding of how to get started with baby steps as a SharePoint Developer, Team Leader or Solution Architect
Like a human life, an application’s lifecycle is demarcated by significant events. It begins with an idea: Why don’t we build something that does this? Once the application is created, the next big event is deployment, when the application goes into production. And finally, when it no longer has business value, the application reaches end of life and is removed from service.
Devs“It works on my machine”“Can’t find the source control for this version”“Haven’t got the source control”“I’ve made changes in SharePoint Root”“I copied it to the GAC manually”Admins“We don’t know where to deploy it!”“What version is in Production?”
Automate building of WSPEnforce that all artefacts get deployed via WSP.No manual copying of files to SharePoint RootDisaster RecoveryCheck in policyBuild StampingBuild ServerSeparate serverDon’t install SharePoint on it!Get administrators to push to environments…or automate it (PowerShell 2.0 remoting)
We’ve discussed the operating system options, now let’s look at what needs to be installed. The developer’s PC will have Visual Studio and SharePoint 2010 installed. You will use unit testing, smoke testing, and leverage the capabilities of Visual Studio for F5 deployment. In a SharePoint 2007 environment, you can use a number of tools to enable this such as WSP Builder, VSeWSS 1.3, or STSDEV. In a 2010 environment, Visual Studio 2010 provides integrated development capabilities for SharePoint. (build)Once you have written and unit tested your code, you check it into a source code repository such as Visual Studio Team System’s Team Foundation Server. Team Foundation Server provides the enterprise source code repository and application lifecycle management capabilities to support an enterprise development team. (build)After the code is checked in, a nightly build or continuous integration server will create the WSP. Here, we see Visual Studio Team System’s Team Build installed on a server with only the SharePoint 2010 DLLs. The product team will be releasing guidance to show how to configure a build server with only the SharePoint 2010 DLLs deployed so that you do not need to install SharePoint on your build server. This allows you to perform unit testing and build operations in a clean environment. Further guidance will be coming from the SharePoint product team as we near RTM on how to achieve this. (build)Since the build server created the WSP, it should be checked into the source repository so that the installation can be repeated in the future and its version maintained. The next step is to install and activate the WSP. This can be achieved as part of the build process. (build)The staging environment is now ready for automated testing and warm-blooded user testing.
Sandboxed-compatible Visual Web Part This item template enables you to use a visual designer to create SharePoint web parts that can be deployed in a SharePoint 2010 sandboxed solution.Sandboxed Compilation This extension displays build errors when you use types or members in a SharePoint 2010 sandboxed project which are not allowed in the SharePoint sandbox environment.
2. Jeremy Thake © 2012 AvePoint, Inc. All rights reserved. No part of this may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written consent of AvePoint, Inc.
3. Agenda• What ALM is• Approaches to ALM• ALM Maturity Model• Getting started• Case Study
4. WHAT IS ALM?
5. Application Lifecycle Management (ALM) is acontinuous process of managing the life of anapplication through governance, developmentand maintenance.WikiPedia
6. ALM is the marriage of business managementto software engineering made possible by toolsthat facilitate and integrate requirementsmanagement, architecture, coding, testing,tracking, and release management.WikiPedia
13. Today’s poll question• I am developing Visual Studio SharePoint projects• I am packaging all custom code as a WSP• I am using source control• I am using a build server• I am using SPDisposeCheck• I am doing unit testing
14. Coding• Source Control – “Copy of” projects – No source code for a build (labeling) – Branching – Shelving
16. Coding• Debugging – Breakpoints in code – Inspecting live objects – Prevents • debug statements throughout code • unnecessary logging whilst in development that stays
17. Testing• Unit Testing• Integration Testing• Web Testing• Lab Management
21. Declarative vs. Imperative• Declaratively – Provision some artifacts – SPI’s built into Visual Studio• Imperatively – Provision / de-provision all – Run class methods – Easier to debug & test – Defensive coding – Code samples – Wrapper classes
22. SharePoint Designer• Promotion between environments• Should certain artifacts be packaged as a WSP?• Manual copying and pasting files• Restricting use by policy• Using third party tools to manage deployments
23. One farm, many feature versions active SITE A SITE B SITE C SPDevWiki SPDevWiki SPDevWiki V18.104.22.168 V22.214.171.124 V126.96.36.199 V188.8.131.52 V184.108.40.206SPDevWiki SPDevWiki SPDevWikiV220.127.116.11 V18.104.22.168 V22.214.171.124
24. Automated Builds
25. Build Process
26. Build Process
27. Dev PC Team Foundation Server Fix Bugs (repeat as necessary) Check In F5 Deploy Development Nightly build -OR- Smoke Testing Continuous Integration WSP Check in WSP Staging Build Server Bugs Team Build Warm-blooded user testing Build WSP SP2010 DLL’s Install and Activate [script] Unit TestingAutomated testing
28. Unit and Integration Testing• No interfaces• Integration• Tiered layer development• Design Patterns• TypeMock Isolator and Moles/Pex
29. Load and Performance Testing• Visual Studio Ultimate• Stress test code – Simulating users• Highlights overuse of creating new SPSite objects• Validates server roles and hardware
30. ALM MATURITY MODEL
31. Where are you? Automated Automated Testing Deployment Automated Builds Source controlNoSourceControl
32. GETTING STARTED
33. The Microsoft approach• Visual Studio 2010 Team System – Visual Studio 2010 – Team Foundation Server 2010 – Test Professional 2010 – Project Server 2010• ALL INTEGRATED• TFS in the cloud is coming!
34. Visual Studio 2010
35. Things to know• It doesn’t work out of the box ;-) – Need to put assemblies on TFS server http://msdn.microsoft.com/en-us/ff622991.aspx• SharePoint/TFS Continuous Integration Starter Pack http://sharepointci.codeplex.com/
36. The cheaper• Source control – TortoiseHg and Mercurial• Continuous Integration – JetBrains Team City
37. Case studyNOTHINGBUTSHAREPOINT.COM
38. Approach• BitBucket.org – $10 a month for a mercurial solution• No automated builds – as I do releases...but from Source Code• Using AvePoint’s DocAve Deployment Manager to deploy from Dev to Test to Production
41. The After-Party: SharePint Karl Strauss Brewing Company 1157 Columbia Street San Diego, CA 92101 Phone: 619-234-2739Immediately following event closing & prize drawings (@6:30 pm) Directions (.9 miles): 1. Head northeast on 1st Ave 2. Turn left onto W B St 3. Turn left onto Columbia St Karl Strauss will be on the left
42. Thank our SponsorsPlease be sure to fill out your session evaluation!
43. References• My Links – http://delicious.com/jthake/alm+sharepoint• Webcast – Introducing SharePoint 2010 (SP2010) Development to ALM (VS2010 and TFS2010) – Feature upgrade in SharePoint 2010• SharePoint 2010 – http://sharepoint.microsoft.com/• SharePoint ALM resource center – http://msdn.microsoft.com/en-us/sharepoint/dd552992• SharePoint Patterns & Practices Group (SPG) – http://msdn.microsoft.com/en-us/library/ff770300.aspx• FREE conference videos & slides – http://msdn.microsoft.com/en-us/sharepoint/ff405669.aspx – http://www.microsoft.com/downloads/details.aspx?FamilyID=f8cb362c-75ad-4cb9-9fbc- 3abcdf6afeaf• SPDisposeCheckStatic Rules – http://spdisposecheckstatic.codeplex.com/
44. References• What is application lifecycle management by David Chappell• WikiPedia – ALM• Microsoft Visual Studio 2010 TFS