Life, the universe and whatever

Something to say about most things

Archive for the tag “VSeWSS”

VSeWSS v1.3 and source control revisited

Back in May I blogged about my experiences of using the latest version of the Visual Studio extensions for Windows SharePoint Services (VSeWSS).  Having had confirmation from Paul Andrew that there would be a supported upgrade path for solutions developed using the extensions to Visual Studio 2010 I have exclusively used them on all projects for all my clients since.

Like most other developers in the SharePoint space I am really looking forward to building solutions using Visual Studio 2010 with all the built in support for SharePoint.  However, that is exclusively for SharePoint 2010 onwards with no support for previous versions so it won’t aid my current projects and clients right now.  There haven’t been any updates since my blog post in May and despite talk about possible and desired updates I’m not sure this is where the focus will be now.

All that said, having developed exclusively with the extensions for over 6 months now I am happy to report that I only have one real issue which is to do with usability.  As per my previous post the recommended approach is to include the ‘pkg’ subfolder in your Visual Studio project and therefore source control and also the WSP and .bat files created in the output (bin) folder.  Visual Studio will fail with an error if  the WSP and .bat files are not checked out for edit when you attempt to deploy your solution which could be a real pain in team development and/or continual/automated build environments.  Also, the feature.xml file in the ‘pkg’ subfolder will be automatically checked out during the deploy process even though no changes will be made which is inconvenient at best but could also be a real issue if someone else in the team has it checked out.

I’ve also experienced an intermittent and inconsistent (major) issue with Site Definition solutions where the ‘pkg’ subfolder is included in source control.  Even with the entire solution checked out for edit, during the deployment process the ElementManifest node in the feature.xml file gets duplicated causing the deployment to fail and the solution to become corrupted.  When this happens I have found that excluding the ‘pkg’ subfolder from the Visual Studio solution and therefore source control is the only way to recover.

So overall, my goal of finding a simplified and consistent supported means of developing and deploying SharePoint solutions hasn’t quite been achieved.  My overriding requirement is for developers who are not necessarily fully aware of how SharePoint works to be able to understand and maintain the solutions.  I wonder though if that will always be a compromise even with the more advanced integration of SharePoint support into Visual Studio 2010?

VSeWSS v1.3 and source control

I have recently looked into using the Visual Studio extensions for Windows SharePoint Services (VSeWSS) that are currently at release version 1.3.  I evaluated the initial releases a couple of years ago and was completely underwhelmed; it was very buggy, very restrictive and, as far as my clients were concerned, I had to recommend an alternative approach to structuring Visual Studio solutions for deploying SharePoint solutions.  A few months ago I was challenged on this point by another experienced SharePoint development consultant and after reviewing Kirk Evans’ series of articles and webcasts I downloaded the March 2009 CTP and set about recreating a few existing solutions using the extensions.  I am very impressed with how far the extensions have advanced since those early releases and they are now supported by the Feedback and Feature Requests forum on MSDN.

The extensions are obviously a work-in-progress but my concerns lay with the upgrade path to Visual Studio 2010 and the indicated/anticipated increase in the level of integration for SharePoint as a development platform.  However, I quickly discovered there is an issue with the extensions when it comes to source control because the feature.xml files are dynamically generated.  This is all well and good except that there is no chance that the standard, minimal settings generated will be sufficient for a production release; the project assembly name is used for the feature title (I think), there is no description, the version number is always 1.0.0.0, the list goes on.  Using the WSP View it is possible to open feature.xml files and make any necessary updates but the problem is the extensions store the physical files in a sub-directory of the project named pkg.  When another developer opens the project from source control the pkg sub folder is not included and it is therefore auto-generated when they first package or deploy the solution. 

Richard Slater is one of many people who have already raised the issue of source control for VSeWSS 1.3 solutions.  As per the MSDN article How to: Create an Automated Build and Deployment Solution with Team Foundation Server Team Build (taken from the SharePoint Guidance on Codeplex) the recommended approach is to add the pkg folder to source control;

To permit team development, you must add this folder to the source control repository. This makes any WSP structure customizations that one developer performs available to the other developers on the team.

The guidance also says;

…the Setup.bat file must be placed under source control so that a build process can use these files to generate a .wsp file and deploy it.

Whether I am automating the build process or not, when the .wsp file is the output to a client I also want this under source control.

Okay, so it seems that we have everything we need in source control for team development and although it doesn’t exactly feel quite right we can live with it because we know this is a work-in-progress and an interim solution before we can get our hands on Visual Studio 2010.  Is it robust enough?  I’m not 100% convinced but I’ve now committed some current projects to the setup so time will tell and if I find more issues then I will report them to the Feedback and Feature Requests forum and blog them here.

Update: I should also have mentioned that when version 1.3 of the extensions is installed a help file is deployed to “[drive_letter]:\Program Files\Microsoft SharePoint Developer Tools 9.0\VSeWSS13.CHM”.  The “Application Lifecycle Management with VSeWSS” chapter should be considered essential reading when using the extensions and there is a section entitled “Source Control using TFS” which details a good demonstration of adding the necessary files and folders to source control.

Technorati Tags: ,,
 

SharePoint as a development platform

Any developer who has interacted with SharePoint in any way, shape or form will surely have asked themselves the question, asked someone else the question or read or partook in at least one of the many debates that have raged over the years.  For me the question “is SharePoint a good development platform?” is pointlessly provocative so I would rather ask “can SharePoint be a good development platform?”.  Instead of giving my own answer to that question I will quote Kirk Evans reflecting on a 6 part series of articles and screen casts he authored entitled SharePoint for Developers:

This series has been building up to an application that provides the ability for an end user to pause a video (rendered through a Silverlight media player) and capture annotations about the video at a particular time segment.  You can imagine that, in a media company, there very well could be additional actions taken when someone creates an annotation such as automatically sending a formatted email to an advertiser (“The text formatting at time 00:00:28.4500000 does not comply with our standards for broadcast”).  This is the real power and benefit of leveraging SharePoint as an application platform: we can incrementally add value to our solution without requiring us to build that functionality into the service.  In a traditional ASP.NET application, you would likely add new functionality in a business logic layer, requiring a change in database storage, changes to the UI to display the new functionality, and changes to the service layer to expose the data to remote consumers.  With SharePoint, you could simply attach workflows to the content type, and any updates to the list via our web service will enjoy this new functionality without making any changes to the web service.  Or you might create a new content type and attach that to an existing list. 

This is a hugely powerful concept, and strongly demonstrates why you should consider using SharePoint as a development platform.  The separation of fields and content types and the ability to apply workflows to content types is huge.  This separation provides the framework for reusable components that can be easily assembled by end users through the web UI instead of requiring developers to code more functionality.  This lets you focus on creating the really cool building blocks and focusing on how to add value rather than writing monotonous forms code that performs CRUD operations against yet another custom database.  It provides a single, consistent platform that provides the web UI, services, and storage within a single platform.

The possibilities here are staggering, because it truly changes the way we think about building applications.

I certainly do not want to reignite any of those previous flame wars about SharePoint as a development platform, I simply saw Kirk’s excellent work which clearly articulates how the development story around SharePoint is continuing to gather pace, credibility and substance.

Please; anyone wishing to express their views on this subject (for or against), I am happy to moderate comments from the well reasoned voices of experience but I have no inclination to host yet another flame war on the subject.  I myself have struggled over the years with trying to build professional, robust systems on SharePoint but I would urge you to take the time to watch Kirk’s screen casts and read the wealth of information and resources he has taken considerable time to pull together.  Nobody can deny the additional overheads (time, experience, software, hardware) involved and it boils down to whether those overheads outweigh the benefits that Kirk succinctly sums up and that can only be done on a person-by-person, situation-by-situation basis.

Post Navigation

Follow

Get every new post delivered to your Inbox.