-
Notifications
You must be signed in to change notification settings - Fork 4k
Fix for #193 ConflictError: The extension ID xxx-PaasDiagnostics-Production-Ext-0 is already in use for this deployment #361
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
…0 is already in use for this deployment" for Set-AzureServiceDiagnosticsExtension after VIP Swap.
Can one of the admins verify this patch? |
Hi @PashaPash, I'm your friendly neighborhood Azure Pull Request Bot (You can call me AZPRBOT). Thanks for your contribution! TTYL, AZPRBOT; |
@PashaPash, Thanks for signing the contribution license agreement so quickly! Actual humans will now validate the agreement and then evaluate the PR. |
@azuresdkci add to whitelist |
@hyonholee @sighkay @huangpf can you please review this PR @azuresdkci add to whitelist |
@azuresdkci retest this please |
Fix for #193 ConflictError: The extension ID xxx-PaasDiagnostics-Production-Ext-0 is already in use for this deployment
This fix doesn't seem to be in the bits of the August release, can anybody tell me in which version this will be included? |
@PashaPash @devigned |
@PashaPash thanks for your reply. I've got my project on visual studio online, used the cloud service deployment model with build 2015 (also commented on the linked issue on the other project). |
@baywet Could you please provide exact steps to reproduce the issue (some minimum sequence of commands to make it crash)? Or at least the output of Get-AzureServiceDiagnosticsExtension for both slots right after the crash? |
2015-08-18T23:57:57.9122458Z Executing the powershell script: C:\agent\tasks\AzureCloudPowerShellDeployment\1.0.13\Publish-AzureCloudDeployment.ps1 2 3 4 5 7 8 10 11 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 |
HPF PR: dev <- Azure:dev
Nullify default NetworkSecurityRules if absent
Fixed #193: Conflict error in
Set-AzureServiceDiagnosticsExtension
when executed after a VIP swap.A code in
ExtensionManager.InstallExtension
is trying to cleanup old unused extension before uploading a new one. It check for extension usage by iterating though pool of predefined names with the following pattern:Default-PaaSDiagnostics-<slot>-Ext-<num>
where<slot>
is the target deployment slot. The problem is that extension configuration is persisted during the VIP swap, soDefault-PaaSDiagnostics-Staging-Ext-0
could be bound to active deployment inProduction
slot and vice versa.Steps to reproduce the issue:
Default-PaaSDiagnostics-Staging-Ext-0
name will be assigned to new config for staging.Staging will became Production, but retain
Default-PaaSDiagnostics-Staging-Ext-0
as active diagnostics config.ExtensionManager.InstallExtension
finds no association between current staging andDefault-PaaSDiagnostics-Staging-Ext-0
and tries to delete it.Deletion fails as
Default-PaaSDiagnostics-Staging-Ext-0
is used by Production Slot.I changed
ExtensionManager.InstallExtension
to check both Staging and Production for extension usage, so it no longer tries to drop the extension used by another slot.ExtensionIdLiveCycleCount
increased to 3 to allow one extra extension to be associated with another slot after VIP swap.Fix is done for
Set-AzureServiceDiagnosticsExtension
, but similat fix should fix the same problem for RDP and AD extensions.Existing
AzureServiceDiagnosticsExtensionTest
and related helpers were updated to useAzureStorageContext
- old code that used storage name only was slightly out of date.HelloNoDiag.cspkg
is a minimal cloud service package required by tests that mentionsnodiagpackage.csv
, seems to be missing after initial code import to github.