What are the challenges you face when working across database platforms? Take the survey

Project build always times out, options like QueryBatchTimeout etc have no effect

gamma_sca_woesgamma_sca_woes Posts: 2 New member
edited September 22, 2022 10:41PM in SQL Change Automation

I'm dealing with a SQL Change Automation project (SQL scripts folder) that contains ~35MiB of DDL & DML scripts. On their own, they take 15 seconds & 4m28s respectively to run when built manually through SQL Compare/SQL Data Compare and executed with eg SSMS/SQLCMD.

However, in a SQL Change Automation task within an Azure DevOps pipeline, it always times out, no matter what. I've tried inspecting the Powershell script that the agent runs as part of the build with no success. Below is the task definition.

I know most of the options below don't do anything, or only do something if we're using another switch that we aren't using, but I found them all in the underlying powershell script and they're all getting passed in seemingly (lines like "[string]$queryBatchTimeoutSync = Get-VstsInput -Name QueryBatchTimeoutSync")
- task: RedgateSqlChangeAutomationBuild@4
    operation: 'Build SQL Change Automation Project'
    sqlProj: 'SqlScripts'
    packageName: '*************BuildRelease'
    tempServerTypeBuild: 'sqlServer'
    tempServerNameBuild: 'localhost\Sql2017Express'
    tempDatabaseNameBuild: '*************'
    authMethodBuild: 'sqlServerAuth'
    usernameBuild: '*************'
    passwordBuild: '*************'
    nugetPackageVersionSelector: 'Specific'
    nugetPackageVersion: '1.0'
    requiredVersionOfDlma: 'latest'
    timeoutInMinutes: 4320
    QueryBatchTimeoutBuild: 0
    QueryBatchTimeoutSync: 0
    QueryBatchTimeoutTest: 0
    QueryBatchTimeout: 0
There's nothing weird in any of the scripts, the one that I can remove and get the build to work is a 21.5MiB .sql file with 73K INSERT statements. Any help is appreciated, thanks.


Sign In or Register to comment.