diff --git a/Tasks/ServiceFabricDeploy/ServiceFabricSDK/Publish-NewServiceFabricApplication.ps1 b/Tasks/ServiceFabricDeploy/ServiceFabricSDK/Publish-NewServiceFabricApplication.ps1 index f4b1db77112d..33b0ef3b3f57 100644 --- a/Tasks/ServiceFabricDeploy/ServiceFabricSDK/Publish-NewServiceFabricApplication.ps1 +++ b/Tasks/ServiceFabricDeploy/ServiceFabricSDK/Publish-NewServiceFabricApplication.ps1 @@ -209,17 +209,12 @@ Write-Host (Get-VstsLocString -Key SFSDK_AppAlreadyExistsInfo -ArgumentList @($ApplicationName, $app.ApplicationTypeName, $app.ApplicationTypeVersion)) try - { - $app | Remove-ServiceFabricApplication -Force - } - catch [System.TimeoutException] - { - # Catch operation timeout and continue with force remove replica. - } - - foreach ($node in Get-ServiceFabricNode) { - [void](Get-ServiceFabricDeployedReplica -NodeName $node.NodeName -ApplicationName $ApplicationName | Remove-ServiceFabricReplica -NodeName $node.NodeName -ForceRemove) + $app | Remove-ServiceFabricApplication -Force + } + catch [System.TimeoutException] + { + $app | Remove-ServiceFabricApplication -Force -ForceRemove } if($OverwriteBehavior.Equals("Always")) diff --git a/Tasks/ServiceFabricDeploy/Tests/CreateDiffPkg.ps1 b/Tasks/ServiceFabricDeploy/Tests/CreateDiffPkg.ps1 index 07d1b5c9eb90..498627ea073d 100644 --- a/Tasks/ServiceFabricDeploy/Tests/CreateDiffPkg.ps1 +++ b/Tasks/ServiceFabricDeploy/Tests/CreateDiffPkg.ps1 @@ -5,7 +5,7 @@ param() $publishProfilePath = "$PSScriptRoot\data\NoAuthPublishProfile.xml" $applicationPackagePath = "$PSScriptRoot\data\DiffPkgAssets\AppPkg" -$diffPackagePath = $env:TEMP + "\DiffPackage" +$diffPackagePath = (Get-Item $env:TEMP).FullName + "\DiffPackage" $serviceConnectionName = "random connection name" $serviceFabricSdkModulePath = "$PSScriptRoot\data\ServiceFabricSDK.ps1" $appName = "AppName" diff --git a/Tasks/ServiceFabricDeploy/task.json b/Tasks/ServiceFabricDeploy/task.json index 31f712a94446..bbafd90419bd 100644 --- a/Tasks/ServiceFabricDeploy/task.json +++ b/Tasks/ServiceFabricDeploy/task.json @@ -17,7 +17,7 @@ "version": { "Major": 1, "Minor": 6, - "Patch": 0 + "Patch": 1 }, "demands": [ "Cmd" diff --git a/Tasks/ServiceFabricDeploy/task.loc.json b/Tasks/ServiceFabricDeploy/task.loc.json index 90f21047e0d9..6776476c927d 100644 --- a/Tasks/ServiceFabricDeploy/task.loc.json +++ b/Tasks/ServiceFabricDeploy/task.loc.json @@ -17,7 +17,7 @@ "version": { "Major": 1, "Minor": 6, - "Patch": 0 + "Patch": 1 }, "demands": [ "Cmd"