Welcome to MSDN Blogs Sign in | Join | Help

Announcing SPDisposeCheck tool for SharePoint Developers

The SPSite and SPWeb Dispose() methods are an important thing for developers who work with Microsoft SharePoint Products and Technologies to master. Many SharePoint API's allocate COM based memory that is not released by CLR garbage collection and must be released by calling the Dispose() methods. Microsoft Guidance for when to call SPSite and SPWeb Dispose() methods have been published in this MSDN whitepaper by Mike Ammerlaan and Scott Harris. In addition, Roger Lamb has provided additional detail and discussion on his MSDN SharePoint Developer blog. This guidance applies only to customers building custom software that they compiled to .NET assemblies that make use of SharePoint API calls.  Also, an update to the MSDN whitepaper is being planned to reflect key guidance from the blogs.

Microsoft wants to help developers build better quality code that manages available memory better. We are now building a console tool that will help to evaluate customer code against the guidance that is provided. The tool, called SPDisposeCheck, will open your custom compiled assemblies recursively and validate them against the Microsoft published guidance. The output from the tool will contain messages that may indicate the SPSite and SPWeb Dispose() methods guidance are not being followed in the customers source code. While these messages need expert evaluation in order to determine if the software is not performing properly, in some cases just running the tool on your custom code can lead you to simple fixes that improve the quality and performance of custom code on SharePoint. This tool is planned for release during the coming North American Winter.  Customers who are currently experiencing difficulties with memory management in their custom applications should review the guidance listed above.  Customers who are currently experiencing difficulties with Microsoft Office SharePoint Server 2007 should contact their regular Microsoft Customer Support Services contact, or refer to http://support.microsoft.com.

References:

Best Practices: Using Disposable Windows SharePoint Services Objects

Best Practices: Common Coding Issues When Using the SharePoint Object Model

Roger Lamb's SharePoint Developer Blog

Published Wednesday, November 12, 2008 7:48 AM by sptblog

Comment Notification

If you would like to receive an email when updates are made to this post, please register here

Subscribe to this post's comments using RSS

Comments

# Announcing SPDisposeCheck tool for SharePoint Developers | MS Tech News

# SPDisposeCheck finally available

Microsoft has finally announced the not so general availability the SPDisposeCheck tool. This tool, available

Wednesday, November 12, 2008 2:31 PM by Attis on SharePoint and More...

# SPDisposeCheck finally available

Microsoft has finally announced the not so general availability the SPDisposeCheck tool. This tool, available

Wednesday, November 12, 2008 3:11 PM by Mirrored Blogs

# SharePoint Announces SPDisposeCheck

For those developers in the ISV community out there working with SharePoint the SharePoint team has recently

Wednesday, November 12, 2008 3:13 PM by Developer Advisory Services for ISVs

# SPDisposeCheck SharePoint Developer tool announced today

We announced a new developer tool today which is planned for release during the North American Winter.

Wednesday, November 12, 2008 4:46 PM by Paul Andrew

# WSS 3.0 & MOSS: SPDisposeCheck Tool!

Microsoft acaba de anunciar la disponibilidad de una nueva y excelente herramienta para facilitar el

Wednesday, November 12, 2008 6:11 PM by Blog del CIIN

# SPDisposeCheck tool for SharePoint Developers

Finally Microsoft has released the SPDisposeCheck tool for SharePoint Developers. When you building custom

Thursday, November 13, 2008 2:35 AM by Alex blog about Microsoft

# Teched Dev - SharePoint villámhírek

A héten zajlik a TechEd Developer Conference Barcelonában. Amint szabadságomról hazaérek (jómagam nem

Thursday, November 13, 2008 6:08 AM by Hírcsatorna

# SharePoint Daily for November 13, 2008

Top News Stories SharePoint is the Uniting Force Behind Microsoft’s New Biz Server Strategy (SiliconRepublic

Thursday, November 13, 2008 9:19 AM by SharePoint Daily

# SPDisposeCheck tool for SharePoint Developers

SPDisposeCheck is a tool for analyzing your code and discover SPWeb objects that haven’t been properly

Thursday, November 13, 2008 9:45 AM by Shared Points for SharePoint...

# Moss 2007 dispose issues, don't be a the victim

SPDisposeCheck tool officially announced Last year I leveraged a good friend and coworker (Roger Lamb)

# [SharePoint] : annonce de l'outil SPDisposeCheck

La libération des objets SPSite et SPWeb est un point crutial lorsque l'on développe sur SharePoint.

Thursday, November 13, 2008 5:54 PM by GipIsBack

# Links & Recent Announcements mentioned at TechEd Developer

I just got back from Europe where I participated in TechEd Developer and internal Microsoft meetings.

Monday, November 17, 2008 4:53 PM by Arpan Shah's Blog

# 检查你的Sharepoint代码有无内存泄漏的危险--SPDisposeCheck

AnnouncingSPDisposeChecktoolforSharePointDevelopers

http://blogs.msdn.com/sharepoint/archive/2...

Tuesday, November 18, 2008 10:20 AM by 天使の泪

# Best Practices for SharePoint Development from Microsoft

Body: Microsoft's Patterns and Practices group recently released a whole bunch of guidance on SharePoint

Tuesday, November 18, 2008 7:32 PM by Mirrored Blogs

# Best Practices for SharePoint Development from Microsoft

Body: Microsoft's Patterns and Practices group recently released a whole bunch of guidance on SharePoint

Tuesday, November 18, 2008 7:40 PM by Michael Blumenthal Blog

# SharePoint News! 11/2008

Realmente lo que no me ha sobrado en estos dias es tiempo asi que hago un resumen de las mejores novedades

Wednesday, November 26, 2008 6:59 PM by Mirrored Blogs

# SPDisposeCheck - em desenvolvimento...

Salve galera, Novidade do time de desenvolvimento do SharePoint! É de conhecimento dos desenvolvedores

Monday, December 01, 2008 12:24 PM by Rodolfo Roim

# Tools for Troubleshooting SharePoint Applications

Let me share with you some public tools I’ve been using when working with SharePoint cases. Please consider

Wednesday, December 17, 2008 4:43 PM by Debugging Toolbox

# SharePoint Tools for VS2010 Demoed

Paul Andrew has a nice write up on the TechEd EMEA Keynote that Jason Zander did.  One of the OUTSTANDING

Wednesday, December 17, 2008 10:30 PM by Phil Wheat

# SPDisposeCheck finally available

Microsoft has finally announced the not so general availability the SPDisposeCheck tool. This tool, available

Thursday, January 08, 2009 2:23 PM by Attis On SharePoint Mirror

# To Dispose Or Not To Dispose....That Is The Question

To Dispose Or Not To Dispose....That Is The Question

Thursday, January 22, 2009 11:54 PM by Tony Testa's World

# SharePoint 2007 : Dispose Patterns et l'outil SPDisposeCheck

[via Paul Andrew ] SPDisposeCheck avait été présenté dernièrement sur le blog de l'équipe SharePoint

Friday, January 30, 2009 3:41 AM by Philippe Sentenac [MVP SharePoint]

# SPDisposeCheck już dostępny!

Nareszcie! Po 2 miesiącach od zapowiedzi , MS opublikował narzędzie do sprawdzania czy nasz kod SharePoint

Friday, January 30, 2009 7:13 AM by .neting in the free world

# SPDisposeCheck już dostępny!

Nareszcie! Po 2 miesiącach od zapowiedzi , MS opublikował narzędzie do sprawdzania czy nasz kod SharePoint

Monday, February 16, 2009 5:12 AM by .neting in the free world

# Doesn't work for SharePoint Learning Kit

I'm the project co-ordinator for the SharePoint Learning Kit at http://www.codeplex.com/slk. As SPDisposeCheck is a great tool, I'd love to use SPDisposeCheck on it, but it check to see if the file name begins with Microsoft (it does) and then if I rename the file, if any namespace begins with Microsoft (they all do) and then skips the assembly. Is there any possibility of adding an option to not skip Microsoft assemblies. And before you ask, we can't change the namespaces as it was originally a Microsoft project and it would break all existing installations.

Thanks,

Richard

Thursday, February 26, 2009 7:01 PM by RichardWillis

# web tasarım

http://www.parcakontorbayiniz.com thak your beatıful

Thursday, July 30, 2009 11:21 AM by web tasarım

Leave a Comment

(required) 
required 
(required) 

  
Enter Code Here: Required
 
Page view tracker