The PoC test upgrade went really well.
We choose the path of upgrading 3.3.24 â 2019.6.0
We had one issue that was easy to fix. (see below)
It were fixed by enabling the machines that contained null in the JSON string and then run the health check followed by disabling the machine once again⌠This filled the null value in the Status type. and fixed the issue⌠After that the upgrade went smooth.
SELECT TOP (1000) [Id]
,[Name]
,[IsDisabled]
,[Roles]
,[EnvironmentIds]
,[JSON]
FROM [Octopus].[dbo].[Machine]
WHERE [JSON] like â%null%â
Processing Machines-98
Processing Machines-99
Executing .NET Database Server script âOctopus.Core.UpgradeScripts.Script0046ConvertHealthCheckStatus.csâ
Processing Machines-1
Processing Machines-10
Error occured when executing scripts, transaction will be rolled back
Error: Upgrade failed due to an unexpected exception:
Error: Microsoft.CSharp.RuntimeBinder.RuntimeBinderException: âNewtonsoft.Json.Linq.JValueâ does not contain a definition for âStatusâ
Error: at CallSite.Target(Closure , CallSite , Object )
Error: at System.Dynamic.UpdateDelegates.UpdateAndExecute1[T0,TRet](CallSite site, T0 arg0)
Error: at CallSite.Target(Closure , CallSite , Object )
Error: at Octopus.Core.UpgradeScripts.Script0046ConvertHealthCheckStatus.ConvertHealthCheckStatus(IDataRecord record, Func1 commandFactory, IUpgradeLog log) Error: at Octopus.Core.UpgradeScripts.Script0046ConvertHealthCheckStatus.Execute(Func
1 commandFactory, IUpgradeLog log)
Error: at Octopus.Core.Initialization.DbCommandUpgradeScriptResolver.Execute(Func1 commandFactory, IUpgradeLog log) Error: at Octopus.Core.Initialization.DatabaseUpgrader.OctopusUpgradeScriptExecutor.<>c__DisplayClass6_0.<ExecuteDbCommandUpgradeScript>b__0(Func
1 commandFactory)
Error: at DbUp.Engine.Transactions.SingleTrasactionStrategy.Execute(Action1 action) Error: at Octopus.Core.Initialization.DatabaseUpgrader.OctopusUpgradeScriptExecutor.ExecuteDbCommandUpgradeScript(IConnectionManager connectionManager, IJournal journal, IUpgradeLog log, IDbCommandUpgradeScript upgradeScript) Error: at Octopus.Core.Initialization.DatabaseUpgrader.OctopusUpgradeScriptExecutor.Execute(SqlScript script, IDictionary
2 variables)
Error: at DbUp.Engine.UpgradeEngine.PerformUpgrade()
Error: We encountered an error during the schema upgrade. The schema upgrade was stopped and rolled back. Donât worry, this means we havenât made any changes to your data, and you should be able to get back up and running quickly.
Error: Here is the summary of the problems we encountered:
Error: -----------------------------------------
Error: âNewtonsoft.Json.Linq.JValueâ does not contain a definition for âStatusâ
Error: Microsoft.CSharp.RuntimeBinder.RuntimeBinderException
Error: at CallSite.Target(Closure , CallSite , Object )
Error: at System.Dynamic.UpdateDelegates.UpdateAndExecute1[T0,TRet](CallSite site, T0 arg0)
Error: at CallSite.Target(Closure , CallSite , Object )
Error: at Octopus.Core.UpgradeScripts.Script0046ConvertHealthCheckStatus.ConvertHealthCheckStatus(IDataRecord record, Func1 commandFactory, IUpgradeLog log) Error: at Octopus.Core.UpgradeScripts.Script0046ConvertHealthCheckStatus.Execute(Func
1 commandFactory, IUpgradeLog log)
Error: at Octopus.Core.Initialization.DbCommandUpgradeScriptResolver.Execute(Func1 commandFactory, IUpgradeLog log) Error: at Octopus.Core.Initialization.DatabaseUpgrader.OctopusUpgradeScriptExecutor.<>c__DisplayClass6_0.<ExecuteDbCommandUpgradeScript>b__0(Func
1 commandFactory)
Error: at DbUp.Engine.Transactions.SingleTrasactionStrategy.Execute(Action1 action) Error: at Octopus.Core.Initialization.DatabaseUpgrader.OctopusUpgradeScriptExecutor.ExecuteDbCommandUpgradeScript(IConnectionManager connectionManager, IJournal journal, IUpgradeLog log, IDbCommandUpgradeScript upgradeScript) Error: at Octopus.Core.Initialization.DatabaseUpgrader.OctopusUpgradeScriptExecutor.Execute(SqlScript script, IDictionary
2 variables)
Error: at DbUp.Engine.UpgradeEngine.PerformUpgrade()