Tuesday, September 10, 2013

Visual Studio and Team Foundation Server 2013 RC Released

Some big news!! The release candidate for VS & TFS 2013 was released last night.

There are a couple of really nice features added since the preview. One of my favourites is the charting ability for work items. I have done quite a few custom TFS reports, and even though this may reduce the number of jobs that I have, it is VERY cool nonetheless…

The list of things that have been added is fairly large, hopefully I will blog about it in the future.

Note that this does have a “go-live” license, so Microsoft will provide support if you decide to be an early adopter and upgrade your production environments.

Feel free to contact us if you need more information around upgrade options...

Friday, August 23, 2013

Exam 70-498 : Delivering Continuous Value with Visual Studio 2012 Application Lifecycle Management

 

I finally got the time to go and write the “Delivering Continuous Value with Visual Studio 2012 Application Lifecycle Management” exam.

I was quite nervous about this one, as it has been a while since I have written any form of exam and because it is very “non technical” focussed. These “fuzzy” questions can often be very misleading.

Luckily I passed, fairly well actually, so I thought I would jot down some of my crib notes..

1) Know the TFS process templates

Especially the terminology and the artefacts that are included in the different process templates. The questions are almost a matter of disqualifying the incorrect answers and then you are left with what can only be the correct ones.

2) Have a good grasp on the methodologies / processes

Especially scrum! The scrum guide is a fairly concise guide and small enough to read in one sitting (even for me!), so there is no real reason not to work through it in any case.

Once again, have a good grasp of the CMMI, Agile and Scrum terminology, artefacts and processes.

3) Read

I really recommend “Professional Scrum Development with Microsoft Visual Studio 2012” by Richard Hundhausen. Even if you are not going to take the exam, a very good read indeed.

Have a look online, there are a lot of brain dumps available for this exam. I would take a look at the questions, but really scrutinise the answers. I looked over a couple and there are definitely plenty of wrong answers provided to the questions. Just be careful and don't learn the answers of by heart!

4) Work through the free jumpstart

Yes, there is actually a free jumpstart for this exam. Definitely worth spending some time on.

 

Done and dusted! Hot smile

Good luck if you are going to give it a go.

Friday, August 16, 2013

Why move from VSS to TFS (Very Sore Safe to Truly Fantastic Server)

Let me give you a hint: Not only is it faster, it’s also more reliable! (There, blog post done : )

Let me expand on the above:

It’s fast!

Seriously, a lot faster.

Anybody that’s ever had to sit and pay VSS tax while dreaming of your post work beer, waiting for a history lookup, a search, or especially “View difference” would know what I mean.

There is a great difference in architecture between the two. I’ll discuss a few to give you an idea of why you should consider moving.

Storage:

TFS Uses a SQL database to store Team Project Collections; VSS uses a File System. So how is this better?

· Size – (Yes it does matter) VSS can store up to 4GB reliably; TFS can go into Terabytes

· Reliable – Ever had a network error when checking in on VSS? You’re left with corrupt files and a caffeine overdose. TFS commits a transaction which can be rolled back if there is an error

· Indexing on the tables so faster searches – Did I mention TFS is faster?

· And of course, having a DB as your data store, you can have all the usual goodies like mirrored and clustered DB’s for TFS, so you never have to lose anything or have any down time!

Networking:

TFS uses HTTP services vs. file shares (That should be enough said)

· Option of a TFS proxy for remote sites to save bandwidth and speed things up a little

· Did I mention that TFS is faster?

Security:

TFS uses Windows Role-Based Security vs. VSS security (I don’t think the methodology was good enough for someone to even come up with a name for it – I’ll just call it Stup-Id, there we go, you’re welcome ;)

Windows Role-Based Security vs. VSS’s Stup-Id:

· With Win Roles you can specify who’s allowed to view, check-out, check-in and lots more. With Stup-Id you can set rights per project, but all users must have the same rights for the database folder. This means all users can access and completely muck up the shared folders. Not pretty.

Extra functionality and pure awesomeness:

· Shelve sets – this is really handy to store code if you don’t want to commit it just yet. Say you go for lunch and you’re afraid that BigDog might chew up your hard drive again: all you do is shelve your code – this stores it in TFS. Once you’ve replaced said eaten hard drive you just unshelve and... tada! No need to say the dog ate my homework.

· Code review – Developer A can request a code review from another developer who can add comments to the code and send it back. (Basically sharing a shelve set)

· Gated check-ins: You can set rules to only allow check-ins when certain conditions have been met. For example, only check in code when:

o the code builds successfully, or

o all unit tests have passed, or

o the code has been reviewed

· Work Items – Bug/issue tracking made with love removes that nagging feeling at the back of your mind that one of these days there will be a PHP or MySQL update that breaks your free open source ticketing/bug tracking system.

· Change sets – basically all the items that you’ve changed and are checking in. You can also associate change sets with work items for better issue tracking.

· Build automation – automate build and deploys (How cool is this?)

But for me the Pi├Ęce de r├ęsistance is:

Have you ever had a new developer change files outside of the IDE? Maybe change the read-only attribute and made some changes? This completely confuses VSS and is a great way to get your source control out of sync. In TFS you can edit files outside of the IDE to hearts content and TFS will pick it up and queue for the next commit.

How to move?

Google “Visual Source Safe Upgrade Tool for Team Foundation Server” and follow the instructions.

And that is why TFS will make you happy. Better source control means better code quality, leading to happy customers, and maybe being the next Bill Gates (unless you wanted to be Guy Fawkes).

image

Thursday, August 15, 2013

The TFS Apprentice…

Welcome Dawie...the TFS Apprentice

Having joined TFC at the beginning of July 2013, Dawie Snyman has the un-enviable challenge of having to become an expert in all things ALM and TFS.

Like many of my clients, TFS is completely foreign to him!

Dawie will be contributing to our blog, offering up a new perspective on TFS... that of the 'first time user'.

Looking forward to his insights…

See his first post over here..

Tuesday, August 6, 2013

Software Deployment (Part 2)

In the previous post I was discussing how one could go about packaging software to make the long journey from development into production.

image_thumb2

In this post I will take a brief look at a couple of tools or applications that I have come across, to take those packages and automate their deployment. Using them will lower the friction and reduce the reliance on human (and possibly problematic) intervention.

 

Continuous Integration

Once again, we all know that continuous integration is a “basic right” when it comes to development environments, but it does not need to be limited to development environments. If you are using one of the numerous CI environments, extending it to deploy the packages in the previous post should be fairly simple.

I have done this a couple of times to varying degrees of complexity in TFS. It is possible to alter the Build Template to do pretty much anything you require. Setting up default deployment mechanisms and then by simply changing a few parameters, you can point it to different environments.

I have done everything from database deployments, remote msi installations to SharePoint deployments using just the TFS Build to do all the work.

 

3rd Party Deployment Agents

InRelease

You must have heard by now, a very exiting acquisition from Microsoft was the InRelease application from inCycle. This basically extends TFS Build and adds a deployment workflow.  It takes the build output (which could be anything that was discussed in the previous post) and, once again, kicks off a WorkFlow that includes everything from environment configuration to authorisation of deployment steps.

In SAP they speak of “Transports” between environments, and this, in my mind, speaks to the same idea of transporting the package into different environment.

I’m really excited about this, and I can already see a couple of my clients making extensive use of it.

image

Octopus Deploy

Another deployment focussed package that I have been following is Octopus Deploy (OD). OD works on the same premise as InRelease, having agents/deployers/tentacles in the deployment environment that “does the actual work”.

A key differentiator is that OD sources updates etc. from NuGet feeds, so you need to package your deliverables and then post them to a NuGet server. As I explained in the previous post, NuGet is a very capable platform, and with a number of free NuGet servers around, you can very easily create your “private” environment for package deployment.

System Center

Do not forget System Center, or more specifically System Center Configuration Manager (SCCM). SCCM is a great way to push or deploy applications (generally MSI’s) to different servers or environments. Very capable in its own right, and more importantly (assuming you have packaged the software properly) can be setup, configured and managed by the ops team.

Thursday, July 18, 2013

Software Deployment (Part 1)

So, one of the tenants of ALM is automation, and probably one of the most time consuming and problem prone aspects of the lifecycle is deployment.

It just so happens that I have been in a couple of discussions around how the gap between when the developer “completes” and what is moved into QA, UAT or Prod environments is actually bridged. In fact, I know of a notable company losing a great deal of money due to a critical system being down for a day because one step was not completed by the deployment team.

image

We all know that continuous integration is a “basic right” when it comes to development environments, and recently there is an emphasis on continuous deployment, but how do we package and move deliverables from one area to another?

So I want to start with packaging.

There are a couple of ways that we can package our applications, based on the technology that they are built in, the target environments and/or the amount of configuration that is needed when deploying.

Remembering that “If You're Using XCopy, You're Doing It Wrong”, these are a couple of techniques / tools I would keep in mind:

Installers (aka MSI)

Visual Studio used to have a “Microsoft” installer project type that was available with VS 2010 and earlier. It was fairly intuitive, and I know a couple of companies that have not considered upgrading due to an investment in this project type.

InstallShield Limited Edition was also packaged in VS 2010 and is still available with VS 2012, although limited, it does provide basic functionality and some integration with build environments.

There are a couple of other msi creations, but my favourite has to be WiX. It was actually almost a part of Visual Studio, but then it was decided that that would limit the release cadence and inhibit the flexibility of fixing changes and adding new functionality.
It is a highly flexible platform, plugging into builds without much effort.
And if you are wondering if it is any good, a large number of Microsoft’s applications are actually released using a WiX based installations.

MS Deploy / Publish

You have had the ability to “publish” sites in Visual Studio for a while now, but it was basically a “smart” xcopy. In recent years there has been quite a bit of work done on the Web Deploy or MS Deploy utilities. It is basically an extensible framework with providers that provide certain capabilities.
One of the more significant abilities is to deploy web site “packages” to IIS, then there is the “dbDacFx” provider that will actually deploy database changes to target servers as part of the deployment.
This is indeed a powerful tool for the deployment arsenal, especially when working in load balanced and “highly available” environments.

Integrating this into your build is also a synch, merely add a couple of msbuild parameters and you are a-for-away. More complex publish scenarios may involve you resorting to the “InvokeProcess” activity, but that is not so bad either.

(Indeed, Scott Hanselman’s quote "If You're Using XCopy, You're Doing It Wrong” is a session on web deploy that he did)

ClickOnce

If you are working in “client deployable” environments, such as Winforms, or Wpf applications, ClickOnce should definitely be a consideration. It is once again easy to integrate in a build process and if you can get away with merely “copying” assemblies across, then you have a winner.

NuGet

NuGet is fast becoming the de-facto standard for packaging components in the development environment. Companies have also started adopting it in their release management due to the ease of integration and modification. It is a very simple, yet powerful way of packaging and publishing components. With configuration, and even source code transformations and PowerShell scripts, you can pretty much do anything during install or remove actions.

Quick Comparison

  MSI MS Deploy ClickOnce NuGet
Database Deployment bullet_tick bullet_tick bullet_cross bullet_tick
Install Time UI bullet_tick bullet_cross bullet_cross

(single prompt)

bullet_cross
Web Sites bullet_tick bullet_tick bullet_cross bullet_tick
Windows Application bullet_tick bullet_tick bullet_tick bullet_tick
Extensible bullet_tick bullet_tick bullet_cross bullet_tick
Build Integration bullet_tick bullet_tick bullet_tick bullet_tick
Automatic Updates bullet_tick bullet_cross bullet_tick bullet_cross
GAC Installable bullet_tick bullet_tick bullet_cross bullet_tick

Friday, June 7, 2013

Upgrade from TFS 2010 to TFS 2012

Even though there is talk of TFS 2013, with the first CTP due towards the end of June, I’m still doing quite a few upgrades to TFS 2012 at the moment.

When considering upgrading to TFS 2012, there is basically one of two approaches, namely an in place upgrade or a migration.

The in place upgrade is probably a bit less “complex”, even though it can be quite involved. You need to get the environment to a TFS 2012 friendly state (note those service packs!) and then do the upgrade which can take some time.

I highly recommend doing a test upgrade first, work out and document all the kinks before you shut down and attempt a production upgrade.
The test will give you an indication of what can happen before you start, and how long the upgrade will actually take.
With an in place upgrade there is not much you can do to reduce the amount of time that the upgrade will take, you would need to go through all the steps, which will involve uninstalling TFS 2010 and installing TFS 2012 and then upgrading the databases.

You do gain some time in that you would not need to change the SharePoint or reporting services links.

Personally I prefer doing a migration as apposed to the in place upgrade. This means that I can spend the time and configure a new “fresh” environment, then take a TFS 2010 database across and make sure everything works. Any problems can be sorted out in the new environment and you most probably won’t need to keep an extensive log to remind yourself of the problems during the actual upgrade.

On D-Day you just need to take over the TFS 2010 database, and do the post configuration steps. This will also retain the TFS 2010 environment in case anything goes wrong.

Some things that you need to take note of with the migration are:

1) Rebind SharePoint

Have you opened up the project’s SharePoint portal and it has red block strewn all over it?

image

I have found that “Repair Connection” will in most cases sort out the links adequately. If however you have not stuck to the default SharePoint sites or you use sites that are located on different servers, you would need to manually “correct” these bindings.

Open up Visual Studio, go to Team explorer Settings and open up the “Portal Settings”.

image

Re-establishing the connection here works as a last resort (for example uncheck the “Reports and dashboards…” checkbox , click OK , open it back up and then select it, click OK again ) .

2) Reporting Services

If you are considering moving SSRS there are a couple of steps that you need to take into consideration:

  • Restore both the ReportServer and ReportServerTempDB on the target server
  • Make a backup of the SSRS encryption key from the source server and then restore it on the target server
  • In Reporting Services Configuration Manager, make sure that only the target server is in the “Scale-Out Deployment” section. If the old server is still there, remove it.
    • If it won’t simply remove by selecting it and clicking “Remove Server”, then open up the ReportServer database and remove it from the Keys table
  • Make sure that the top level security ( in http://<report server>/Reports ) is set adequately
  • Make sure that your TFS data sources ( “Tfs2010OlapReportDS” and “Tfs2010ReportDS”) points to the correct server
  • And finally, in the TFS Admin console, make sure that on the Reporting view, you are pointing to the correct SSRS server

3) Build Template

Make sure that your build templates have been updated correctly and any custom activities are referencing the new TFS 2012 assemblies.

4) Finally

Upgrade the project templates from TFS web access admin site and setup the team members.

 

Depending on the hardware that you are doing the upgrade on a 15GB TFS database can take 40 minutes to an hour and a 45GB database can take in the vicinity of 3 hours.

If you are looking to upgrade TFS to TFS 2012, feel free to give us a shout