How can we help you today? How can we help you today?

Can I track database deployments with SQL Monitor?

After a recent bout of troubleshooting a troubled deployment, using SQL Compare to determine a few schema differences between testing and production systems, I noticed that SQL Monitor very handily tracks when SQL Compare is used to modify a database that it is monitoring. There are a few articles about this sort of thing (e.g. https://www.red-gate.com/hub/product-learning/sql-monitor/unearthing-bad-deployments-sql-monitor-redgates-database-devops-tools).

What I would like to be able to do is to extend this to our automated deployment system, which is based on Octopus Deploy and not directly on Redgate's tools. If I add log an event using something similar to the SQL code shown in https://documentation.red-gate.com/sc13/getting-more-from-sql-compare/sql-monitor-integration, can I get SQL Monitor to display when the deployment occurs?
david.keaveny
0

Comments

7 comments

  • AlexYates
    You say you handle your deployments with Octopus Deploy - that's cool. But Octopus out of the box effectively just lets you deploy a NuGet package and run a script. Typically your script would execute some other process to run your deployment.

    Most of the folks on these forums will be using Octopus to orchestrate a task with Redgate SQL Change Automation, either from a PowerShell script or using one of the Redgate community step templates. If that's what you are doing, or if you are just running the SQL Compare command line, it should show up in SQL Monitor for you automatically.

    Is that what you are doing, or are you doing something else?
    AlexYates
    0
  • DavidKeaveny
    We are not yet to the point where we can use Change Automation, our DB development process needs to be whipped into shape first. So yes, with Octopus we are currently packaging our changes as hand-rolled (eurgh) SQL scripts then running those scripts in production; it would just be nice to be able to tag in SQL Monitor when we do that deployment.
    DavidKeaveny
    0
  • AlexYates
    Ok, in that case I'm not sure. I'll bow out and hopefully someone else can answer you shortly.
    AlexYates
    0
  • Dan B
    Hi DavidKeaveny,

    That is correct if you add the same SQL to your deployment scripts then SQL Monitor will pick this up and add it to the timeline as a SQL Compare change. 

    Please do let me know if you have any further questions on this.
    Dan B
    0
  • DavidKeaveny
    Hi Dan B,

    Does SQL Monitor only support deployment marking for Redgate-based deployments (whether SQL Compare, Change Automation etc)? In other words, could I have a different icon/logo if I used slightly different text in my log event?
    DavidKeaveny
    0
  • Dan B
    Hi David,

    There is only one choice of logo. Whether you can reverse engineer this I'm not sure but that isn't something we would be able to assist with.
    Dan B
    0
  • DavidKeaveny
    OK thanks, Dan B, I'll go with the SQL as provided in the linked articles.
    DavidKeaveny
    0

Add comment

Please sign in to leave a comment.