Friday, April 28, 2017

TF246017: Team Foundation Server could not connect to the database

A colleague forwarded me the following error message:


The problem occured when he tried to create a branch, but only on this specific project we had issues.

Time to log on the TFS server and check the Event Log. There I found the following error message:

DESCRIPTION: SQL Server Assertion: File: , line=951 Failed Assertion = 'IS_OFF (BUF_MINLOGGED, m_buf->bstat) || pageModifyType != PageModifyType_Contents || GetPagePtr ()->IsTextPage ()'. This error may be timing-related. If the error persists after rerunning the statement, use DBCC CHECKDB to check the database for structural integrity, or restart the server to ensure in-memory data structures are not corrupted.

This error message brought me to the following Connect ticket:

I first tried to install all possible updates but no luck, the issue remained. Then I saw that in the ticket they mention switching to the Full recovery model. I tried that and it seemed to work.


Thursday, April 27, 2017

Angular – Component Libraries

The new Angular(can’t call it Angular 2 anymore) ecosystem is still evolving. Control libraries start to appear.

Here are some of the libraries I had a look at:

(Don’t ask me which one I prefer, as with all control libraries they have their pros and cons you’ll have to learn to live with…)

Angular Material

Material Design components for Angular apps

Remark: The Angular Material library for Angular >=2 is still rather limited. Don’t confuse it with the Angular 1 variant at



Native Angular components & directives for Lightning Design System

Created by the Salesforce’s guys on top of Angular and Salesforce's Lightning Design System.



Covalent( is a UI Platform that combines proven design language with a comprehensive web framework, built on Angular & Angular-Material (Design).



PrimeNG( is a collection of rich UI components for Angular 2. PrimeNG is a sibling of the popular JavaServer Faces Component Suite, PrimeFaces.


Kendo Angular UI

Professional Grade Angular UI Components


Wednesday, April 26, 2017

IT Manager, it’s a monkey job…

In my current job I’m active as a manager where I have a team of +20 people. My main focus is to guide these people through their career and help them grow into professional IT consultants. Sometimes I get completely overwhelmed by the questions, problems,little and bigger things, … that people keep asking me.

My manager(the manager’s manager Winking smile) noticed it and shared the following article from Harvard Business Review with me; Management time: Who’s got the monkey?. Although from 1974(!) still as relevant today…


Don’t forget the follow up article Making time for Gorillas(part of the same link).

Thanks J├Ârgen for the tip! And now I have to go as it is time to get the monkeys of my back…

Tuesday, April 25, 2017

Add extra NuGet Repositories through nuget.config

By default Visual Studio has one NuGet source registered out of the box, the official NuGet gallery at

However I had to use a package that wasn’t hosted on the official NuGet gallery but instead could be found on Problem was that I didn’t want to ask all developers to register an extra Package Source in Visual Studio.

So what’s the alternative?

The trick is to add a nuget.config file to your solution.

From the documentation:

The behavior of every NuGet command, whether issued from the command line, the Package Manager UI, or the Package Manager Console, is driven by the accumulated settings from any number of NuGet.Config files:+

  • Project-specific NuGet.Config files located in any folder from the solution folder up to the drive root. These allow control over settings as they apply to a project or a group of projects.
  • A solution-specific NuGet.Config file located within a .nuget folder in the solution. Settings in this file apply only to solution-wide packages and is supported only in NuGet 3.3 and earlier. It is ignored for NuGet 3.4 and later.
  • The global config file located in %APPDATA%\NuGet\NuGet.Config, which is always used unless you specify a different config file using the -configFile switch on any NuGet command

Inside this nuget.config you can register extra package sources:

Monday, April 24, 2017

Angular 2 Pipes– args are not arguments :-)

Today I lost some time investing an issue with Angular 2. I was creating an Angular pipe using Angular CLI. The code that was generated for me was the following:

Unfortunately I wrongfully assumed that the args keyword was refering to the arguments object we have in the JavaScript language. Turns out that this was a wrong assumption. Since Angular beta.16 the parameters are not passed as array to the transform() method anymore but instead as individual parameters:

{{ myData | translate:'arg1':'arg2' }}

export class TranslatePipe implements PipeTransform {   
  transform(value:any, arg1:any, arg2:any):any {

I would suggest to the Angular CLI team to change the name of the argument, because the args name causes confusion. Or is it just me?

Friday, April 21, 2017

Use Swagger-UI to test your Open API

In case your REST api exposes an Open API specification document, but you didn’t integrate Swagger UI to allow developers to browse and test your API, they can still use the Swagger-UI capabilities by directly browsing to and put the url in the box at the top of the page. Alternatively, they can add the url of the service to the end with ?url= such as


Thursday, April 20, 2017

ASP.NET Core Web Deploy–XML Documentation files are not copied

After deploying our ASP.NET Core application using Web Deploy, we noticed a problem with our Swagger integration through SwashBuckle. Normally SwashBuckle can integrate documentation in your Swagger UI by extracting and reading the XML comments added to your code.

Problem was that when this XML isn’t copied Swashbuckle throws an exception making our whole API unavailable. Some research showed that the problem appeared after migrating from the project.json format back to csproj, after which the <DocumentationFile> was no longer automatically copied to the output folder during the build or publish process.

The solution I used was to add the following snippet to your csproj: