Search code examples
web-servicesvisual-studio-2012tfstfs-alerts

Visual Studio TFS Alerts: How to send out an alert upon successful publish of a web application?


I have taken a look at alerts management for TFS 2012 after installing power tools, and I can see about four types of alert templates:

  • Work Item
  • Code Review
  • Check In
  • Build

I was wondering if there was a possibility of having a supported way to register alerts under “Publish” event-type, manageable directly via the Alerts explorer.

If not, I thought of some workarounds:

  • If this cannot be done and managed via the Alerts explorer, can I customize an alert to be triggered on Publish event via a Web Service? If so, does the TFS API support such customization?

  • I can also instead go with a continuous delivery approach and set an automated publish upon successful build of a solution, with an email alert on Build-Event Success (which would also mean that a solution has been published).

Which approach would be a supported way for setting "on publish"-event alerts for web solutions via TFS?


Solution

  • My suggestion would be not to use the Publish in Visual Studio but instead to use a Build to publish your solution (either triggered on check-in, or manually triggered). Then you can easily setup an alert on that build. Using a build instead of VS-Publish is also considered a better practice because it gives you more power and flexibility for the deployment process.