Download
1 / 30

Best Practices for SharePoint Solution Deployment - PowerPoint PPT Presentation


  • 549 Views
  • Updated On :

DM400. Best Practices for SharePoint Solution Deployment. Ted Pattison Instructor Ted Pattison Group. SharePoint Training from People You Know and Trust http://www.TedPattison.net. Industry’s Leading Experts & SharePoint MVPs

loader
I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
capcha
Download Presentation

PowerPoint Slideshow about 'Best Practices for SharePoint Solution Deployment' - fairly


An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
Best practices for sharepoint solution deployment l.jpg

DM400

Best Practices for SharePoint Solution Deployment

Ted Pattison

Instructor

Ted Pattison Group


Sharepoint training from people you know and trust http www tedpattison net l.jpg
SharePoint Training from People You Know and Trusthttp://www.TedPattison.net

Industry’s Leading Experts & SharePoint MVPs

Andrew Connell - Shane Young - David Mann - John Holliday - Scot HillierNicola Young - Sahil Malik - Chris Predeek - Ted Pattison


Agenda l.jpg
Agenda

  • Deployment in a Web Farm environment

  • The Root Files directory

  • Solution Packages

  • Demos of developing SharePoint Solutions

    • Features

    • Custom application pages

    • Custom page templates

    • Custom field types

    • Web Parts

    • Updates to web.config


The wss farm l.jpg
The WSS Farm

  • WSS deployment based on a farm

    • Farm requires Web server(s) and database server

    • Farm can be single server or multi-server

    • Each farm has exactly one configuration database


Sharepoint customization versus development l.jpg
SharePoint Customization Versus Development

  • Site Customizations

    • Changes to one particular site recorded in content DB

    • Done using the browser or the SharePoint Designer

    • Easy to do but hard to reuse

  • WSS Development

    • Creation of reusable templates/components

    • Templates/components installed on Web server

    • Development based on Visual Studio projects

    • Project source files checked into source code control

    • Projects can be moved through staging to production


Wss component development l.jpg
WSS Component Development

  • Feature-based Components

    • Custom Application Page

    • Site Page Templates

    • Master Pages

    • Web Parts

    • Site Columns and Content Types

    • Custom List and Document Library Definitions

    • List-based Event Handlers

      Custom Workflows

  • Components creating without using features

    • Custom Field Types

    • Site Definitions


The root files directory l.jpg
The Root Files directory

  • This is where many of your development files need to be deployed

    • Most files go into templates directory

Web Service files

GLOBAL .RESX files

Admin Pages

User Controls

Features

Images

Application Pages

Site Definitions

Field*.xml files


Sharepoint solution packages l.jpg
SharePoint Solution Packages

  • What is a Solution Package?

    • Templates and/or components in an installable unit

    • CAB file with .WSP extension

    • Package that contains metadata (manifest.xml)

  • Best Practice in SharePoint Solution Deployment

    • Use solution packages… period!

    • Add support for building/testing solution package early!

MyStuff.wsp

manifest.xml

Other Stuff

Templates/components



A sample m anifest xml file l.jpg
A sample manifest.xml file

  • Defines Solution properties and contents


Building the wsp file l.jpg
Building the .WSP file

  • Commonly done using MAKECAB.EXE

    • Requires .DDF input file

Solution Package Build Process

Input

DDF File

Output

WSP File

MAKECAB.EXE


The ddf file up close l.jpg
The DDF File Up Close

  • DDF file must build proper folder structure

    • Prefer .Set DestinationDir instruction

MyStuff.wsp


Two phases of wsp deployment l.jpg
Two Phases of WSP Deployment

.WSP Install

ConfigDB

(1) Solution Package Installation

  • .WSP file is copied to ConfigDB

    (2) Solution Package Deployment

  • .WSP pushed out to Web servers

  • Usually requires IIS Reset operation

  • Done in production farm in off hours

WSP

  • REM - Install CustomApplicationPages.wsp in WSS Solution Package Store

  • %STSADM% -o addsolution -filename MyStuff.wsp

  • REM – force batch file to run timer job synchronously

  • %STSADM% -o execadmsvcjobs

.WSP Deploy

WFE

ConfigDB

WFE

WSP

WFE

  • REM - Deploy Solution Package MyStuff.wsp to Web servers in farm

  • %STSADM% -o deploysolution -name MyStuff.wsp -immediate

  • REM – force batch file to run timer job synchronously

  • %STSADM% -o execadmsvcjobs


Solution management in wss l.jpg
Solution Management in WSS

  • WSS Central Admin provides some control

    • Allows you to see and deploy .WSP files

    • Does not provide a way to install .WSP files


Solution package properties l.jpg
Solution Package Properties

  • WSS Central Admin allows some inspection


Helpful development tools l.jpg
Helpful Development Tools

  • From Microsoft

    • Visual Studio 2005 Extensions for WSS

    • VSTO 3.0 in Visual Studio 2008

  • From SharePoint Development Community

    • The WSPBuilder utility

    • The STSDEV utility


The stsdev utility l.jpg
The STSDEV Utility

  • Low-tech tool for creating solution packages

    • Think of it as an educational proof-of-concept

    • Helpful in getting started

    • Used to promote best practices

  • What does it do?

    • Generates Visual Studio files (.sln, csproj, .aspx, .cs)

    • Creates project with RootFiles directory structure

    • Eliminates need to edit manifest.xml file

    • Eliminates need to edit.ddf file

    • Takes care of GUIDs and assembly names

    • Provides custom tasks in .targets for common SharePoint development operations


Walkthough of using stsdev l.jpg
Walkthough of Using STSDEV

  • STSDEV based on Solution Providers


Demo customapplicationpages l.jpg
Demo: CustomApplicationPages

  • Best Practices

    • Create solution-specific directory in LAYOUTS

    • Use code-behind with DLL installed in GAC

    • Adding a complimentary feature for navigation


Demo customsitepages l.jpg
Demo: CustomSitePages

  • Best Practices

    • Use file-based templates for page creation

    • Add SafeControl setting when using custom controls

    • Deploy .ascx files into CONTROLTEMPLATES

    • Clean up during feature deactivation


Demo litwarefieldtypes l.jpg
Demo: LitwareFieldTypes

  • Best Practices

    • Deploying custom field type using a .WSP

    • Avoiding naming conflicts with .ascx files


Demo acme webparts l.jpg
Demo: Acme.WebParts

  • Best Practices

    • Adding SafeControl entries using manifest.xml

    • Deploy feature to push .webpart files into Web Part gallery


Demo mega webparts l.jpg
Demo: Mega.WebParts

  • Best Practices

    • Deploying Web Part DLLs in bin directory

    • Adding CAS setting using manifest.xml


Demo litwareappsetting l.jpg
Demo: LitwareAppSetting

  • Best Practices

    • Programmatically updating web.config

    • Providing control with WebApplication feature


Sample code from this session l.jpg
Sample Code from this session

  • http://www.TedPattison.net/downloads.aspx


Summary l.jpg
Summary

  • Deployment in a Web Farm environment

  • The Root Files directory

  • Solution Packages

  • Demos of developing SharePoint Solutions

    • Features

    • Custom application pages

    • Custom page templates

    • Custom field types

    • Web Parts

    • Updates to web.config


Slide28 l.jpg

Post Event DVD brought to you courtesy of:


Slide29 l.jpg

SUBMIT AN EVALUATION

For a chance to win an 8GB ZUNE!

Submit evaluations on MySPC

www.MicrosoftSharePointConference.com


Slide30 l.jpg

© 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.


ad