acing application lifecycle management in sharepoint
TRANSCRIPT
Acing Application Life Cycle Management in SharePoint
Jeremy ThakeChief Architect
Level: Intermediate
Agenda
• What ALM is• Approaches to ALM • ALM Maturity Model• Getting started• Case Study
What is ALM?
Application Lifecycle Management (ALM) is a continuous process of managing the life of an application through governance, development and maintenance.
WikiPedia
ALM is the marriage of business management to software engineering made possible by tools that facilitate and integrate requirements management, architecture, coding, testing, tracking, and release management.
WikiPedia
Three aspects of ALM
David Chappell (2008)
Governance
David Chappell (2008)
Development
David Chappell (2008)
Operations
David Chappell (2008)
Focus for today…development
• Requirements management• Architecture• Coding• Testing• Tracking• Release management
APPROACHES OF ALM
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
Coding
• Source Control– “Copy of” projects– No source code for a build (labeling)– Branching– Shelving
Coding
• Code Analysis– Consistent code
Naming standardsCasingFormatting
– Disposing correctly– Defensive coding– Readable coding
Coding
• Debugging– Breakpoints in code– Inspecting live objects– Prevents
debug statements throughout codeunnecessary logging whilst in development that stays
Testing
• Unit Testing• Integration Testing• Web Testing• Lab Management
Tracking
• Tasks• Issues• Bugs• Risks
Release management
• Continuous Integration• Automation!
– release packages– unit testing– code analysis– build numbers
• Red/Green– Don’t break the build!
Artifact Provisioning
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
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
One farm, many feature versions active
SPDevWikiV1.0.0.0
SPDevWikiV2.0.0.0
SITE A SITE B SITE C
SPDevWikiV3.0.0.0
SPDevWikiV3.0.0.0
SPDevWikiV1.0.0.0
SPDevWikiV2.0.0.0
SPDevWikiV3.0.0.0
SPDevWikiV3.0.0.0
App Model
• Code executed off SharePoint• Can be any language executed on any web
server• Client-side object model executed on
pages hosted in SharePoint
Automated Builds
Build Process
Build Process
Unit and Integration Testing
• No interfaces• Integration• Tiered layer development• Design Patterns• TypeMock Isolator, Moles/Pex, SharePoint
Emulator
Load and Performance Testing
• Visual Studio Ultimate• Stress test code
– Simulating users
• Highlights overuse of creating new SPSite objects
• Validates server roles and hardware
ALM Maturity Model
Where are you?
No Source Control
Source control
Automated Builds
Automated Deployment
Automated Testing
GETTING STARTED
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!
Visual Studio 2010
TFS 2012 and SharePoint 2013
• Supported now• http
://blog.hinshelwood.com/integrate-sharepoint-2013-with-team-foundation-server-2012/
SharePoint 2010 Build server
• 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/
SharePoint 2013 Build Server
• SharePoint Server 2013 Client Components SDK Preview– http://
www.microsoft.com/en-us/download/details.aspx?id=30355
• Microsoft Windows SDK for Windows 7 and .NET Framework 4– http://
www.microsoft.com/en-us/download/details.aspx?id=8279
The cheaper
• Source control– TortoiseHg and Mercurial
• Continuous Integration– JetBrains Team City
NothingButsharepoint.comCase study
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
Additional Tools
• Developer Dashboard stsadm -o setproperty -pn developer-dashboard -pv ondemand
• Microsoft.SharePoint.Emulators (NuGet)• SPDisposeCheck (bit.ly/iiE3D6)• VS2010 SharePoint Power Tools
(bit.ly/hmx9hS)• CKS:Dev (bit.ly/4Gpju2)• Fiddler (www.fiddler2.com)• SharePoint Manager 2010 (bit.ly/4dtX5A)
Q&AJeremy Thakewww.jeremythake.com
www.NothingButSharePoint.com
@jthake
www.linkedin.com/in/jeremythake