SQL Automation configuration parameter issues

Cameron.WatsonCameron.Watson Posts: 6
edited December 23, 2013 1:45PM in Deployment Manager
I've been testing out the SQL Automation plugin for Teamcity this week and have run into a couple of issues that I'd like some help with.

The first is to do with build parameters. We use a number of environment variables in our build process to set destination servers & paths. We've noticed that the automation plugin seems to add some new configuration parameters as well. They all have the name of "Requires Exclusive Use of #" and contains a server/database name pair in the value.

Could someone explain what is happening with these? If I remove them, they keep reappearing every time we run a build.

Secondly, when we have a build failure from a database error, the redgate CI engine triggers an error too stating that it can't connect to the remote redgate centre to report the error. Our server sits behind a firewall and doesn't have external access, is there a way to turn this off?

If you need more information or a copy of any logs or screenshots, I can provide them for you.



  • Hi,

    For the latter query - error reports - you cannot currently turn this off. It's logged as a request here (ref. SQLCI-95) but it's not been implemented thus far.

    As for the former, the server/db relate to the ones that are updated on each build but I don't have a clue as to why we add those. My guess would be they need to be parameters in that way to be passed to the command-line but I don't know for sure. I've asked the development team if they can shed any light on it and I'll post back when I hear something.
    Systems Software Engineer

    Redgate Software

  • OK, further to my last post, I've had a response on the build configuration properties, which I've copied in below:

    One part of our TC plugin adds those properties to each build configuration, and another part (that hooks into TC's build queue) makes sure that when a build starts running there are no currently executing builds that have the same value for that property.

    The reason why we designed it like this is so that builds don't interfere with each other, i.e. they know no other currently running build is trying to use the database they're trying to use.
    Systems Software Engineer

    Redgate Software

  • Thanks for your reply James.

    So given your information, should I assume that the parameters are passed in at runtime, and not hard-coded in? I currently use an environment parameter on the build configuration to set the destination server. This is passed into the redgate build steps as a parameter in it's configuration. I'm assuming that this value is set at runtime, and not at the initial configuration?
  • They will be passed through at runtime but I'm not sure if it's clever enough to expand the environment parameters you're passing through or will just use the values entered previously. Does the value of the property have the actual DB set or the variable name you presumably put into the build configuration? (some screenshots of how you've got it set up might be handy, I'm hugely familiar with team city outside of our own plugin)
    Systems Software Engineer

    Redgate Software

  • Yes that's my concern too. The value that's in the environment variable is in the configuration parameter. However when you update the env var it doens't update the config var.

    I just ran a test with it to see what it would do if you ran it with mismatching env and config variables. It updated the conf variables to match the env variable and then processed. So it seems as though it is at run time, but it's very confusing if you plan to change your variables often. Intuitively, you think you should change all of them.
  • OK- so sounds like it's working as you need, but I'd agree it's not obvious. I think most of our users tend to just plug the values in directly rather than passing parameters so it's not an issue. I'll log a request to see if we can improve on this though, or at least document it a little more clearly!
    Systems Software Engineer

    Redgate Software

Sign In or Register to comment.