Thursday, April 5, 2007

BisSubscribe and none evaluating filter expressions

After pulling my hair and screaming in agony over the darn filter property of TFS notifications I finally managed to figure it out :)

These examples works:

bissubscribe.exe /eventType CheckinEvent /address some@somewhere.com /deliveryType EmailHtml /server mytfsserver


bissubscribe.exe /eventType CheckinEvent /address some@somewhere.com /deliveryType EmailHtml /server http://mytfsserver:8080

bissubscribe.exe /eventType CheckinEvent /address some@somewhere.com /deliveryType EmailHtml /server http://mytfsserver:8080 /filter "TeamProject = MyProject"

This one however does not work:

bissubscribe.exe /eventType CheckinEvent /address some@somewhere.com /deliveryType EmailHtml /server mytfsserver /filter "TeamProject = MyProject"

Since all commands will execute with no errors resulting in a subscription in the TfsIntegration.tbl_subscription one easily gets fooled into thinking it should work but in the case of the fourth command nothing will happen.

The reason for this is that the /server switch of bissubscribe requires a fully qualified url address to your TFS server to function properly but only if you specify a filter with the /filter switch.

Hopefully Microsoft will add some validation on this switch in the future since it's one of thoose things that are hard to spot when no errors are generated (when glancing over it you mostlikely will only register the server name as its correctness).

No comments:

Post a Comment