Skip to content
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

fix: api version update + fixing failing workflow runs - avm/res/event-hub/namespace #2004

Closed
wants to merge 5 commits into from

Conversation

segraef
Copy link
Contributor

@segraef segraef commented May 22, 2024

Description

Closes #1729 (might be closed already) and future failing workflow runs.

Pipeline Reference

Pipeline
avm.res.event-hub.namespace

Type of Change

  • Update to CI Environment or utlities (Non-module effecting changes)
  • Azure Verified Module updates:
    • Bugfix containing backwards compatible bug fixes, and I have NOT bumped the MAJOR or MINOR version in version.json:
      • Someone has opened a bug report issue, and I have included "Closes #{bug_report_issue_number}" in the PR description.
      • The bug was found by the module author, and no one has opened an issue to report it yet.
    • Feature update backwards compatible feature updates, and I have bumped the MINOR version in version.json.
    • Breaking changes and I have bumped the MAJOR version in version.json.
    • Update to documentation

Checklist

  • I'm sure there are no other open Pull Requests for the same update/change
  • I have run Set-AVMModule locally to generate the supporting module files.
  • My corresponding pipelines / checks run clean and green without any errors or warnings

Important

The "Needs: Triage 🔍" label must be removed once the triage process is complete!

Tip

For additional guidance on how to triage this issue/PR, see the BRM Issue Triage documentation.

Note

This label was added as per ITA06.

@microsoft-github-policy-service microsoft-github-policy-service bot added Needs: Triage 🔍 Maintainers need to triage still Type: AVM 🅰️ ✌️ Ⓜ️ This is an AVM related issue labels May 22, 2024

Note

The "Type: AVM 🅰️ ✌️ Ⓜ️" label was added as per ITA08BCP.

@matebarabas matebarabas changed the title feat: Update Event Hub namespace version to 2024-01-01 feat: Update Event Hub namespace version to 2024-01-01 - avm/res/event-hub/namespace May 23, 2024
@matebarabas matebarabas added Class: Resource Module 📦 This is a resource module and removed Needs: Triage 🔍 Maintainers need to triage still labels May 23, 2024
@segraef segraef changed the title feat: Update Event Hub namespace version to 2024-01-01 - avm/res/event-hub/namespace feat: Update Event Hub namespace version to 2024-01-01 May 24, 2024
@segraef segraef changed the title feat: Update Event Hub namespace version to 2024-01-01 fix: api version update + fixing failing workflow runs May 24, 2024
@matebarabas matebarabas changed the title fix: api version update + fixing failing workflow runs fix: api version update + fixing failing workflow runs - avm/res/event-hub/namespace May 24, 2024
@eriqua eriqua added the Needs: Core Team 🧞 This item needs the AVM Core Team to review it label Jun 6, 2024
@elanzel elanzel closed this Jun 12, 2024
@elanzel elanzel reopened this Jun 12, 2024
@elanzel elanzel marked this pull request as ready for review June 12, 2024 08:56
@elanzel elanzel requested review from a team as code owners June 12, 2024 08:56
@elanzel elanzel enabled auto-merge (squash) June 12, 2024 08:57
@@ -53,7 +53,7 @@ module testDeployment '../../../main.bicep' = {
scope: resourceGroup
name: '${uniqueString(deployment().name, resourceLocation)}-test-${serviceShort}'
params: {
name: '${namePrefix}${serviceShort}001'
name: '${namePrefix}${serviceShort}${substring(uniqueString(baseTime), 0, 3)}'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @segraef could you elaborate why this was changed? Just curious, as it take away the possiblity to test this deployment in an idempontent way.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @AlexanderSehr the unique name should solve a conflict when deploying the encrypted eventhub:
VERBOSE: 11:05:03 - The deployment 'a-r-eh-n-encr-t1-20240612T1106073886Z' failed with error(s). Showing 1 out of 1 error(s).
Status Message: At least one resource deployment operation failed. Please list deployment operations for details. Please see https://aka.ms/arm-deployment-operations for usage details. (Code: DeploymentFailed)

  • The resource write operation failed to complete successfully, because it reached terminal provisioning state 'Failed'. (Code:ResourceDeploymentFailure)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, but when I take a look at the last failed pipelines I see 3 erros through 3 attempts

1.

The deployment 'a-r-eh-n-encr-t1-20240612T1106073886Z' failed with error(s). Showing 1 out of 1 error(s).
  Status Message: At least one resource deployment operation failed. Please list deployment operations for details. Please see https://aka.ms/arm-deployment-operations for usage details. (Code: DeploymentFailed)
   - The resource write operation failed to complete successfully, because it reached terminal provisioning state 'Failed'. (Code:ResourceDeploymentFailure)

2.

The deployment 'a-r-eh-n-encr-t2-20240612T1106082182Z' failed with error(s). Showing 2 out of 2 error(s).
  Status Message: Namespace name '***ehnenc001' is not available. Reason: NameInUse. Message: Name already in use (Code:NamespaceUnavailable)
  
  Status Message: At least one resource deployment operation failed. Please list deployment operations for details. Please see https://aka.ms/arm-deployment-operations for usage details. (Code: DeploymentFailed)
   - Namespace name '***ehnenc001' is not available. Reason: NameInUse. Message: Name already in use (Code:NamespaceUnavailable)

3.

The deployment 'a-r-eh-n-encr-t3-20240612T1106487953Z' failed with error(s). Showing 2 out of 2 error(s). Status Message: Namespace name '***ehnenc001' is not available. Reason: NameInUse. Message: Name already in use (Code:NamespaceUnavailable)
  Status Message: At least one resource deployment operation failed. Please list deployment operations for details. Please see https://aka.ms/arm-deployment-operations for usage details. (Code: DeploymentFailed)  
   - Namespace name '***ehnenc001' is not available. Reason: NameInUse. Message: Name already in use (Code:NamespaceUnavailable)

Of which only the first is really relevant as all others could be / are follow-up errors as the Namespace from Attempt 1 is still around (and later the one from Attempt 2.
I don't think we're actually fixing the error, but just masking it by deploying 3 different Namespaces.

I would suggest to run the deployment of the encr test once without the removal (which will likely fail) and then look into the deployment and find the actual cause of the error. The resource write operation failed to complete successfully isn't exactly saying much.
My guess is that we have similar issues like we have with other modules where the permissions for the key vault key take longer to propagate than the deployment is willing to wait (which is super nasty by the way). If that turns out to be the case here too, then we should fix that instead. Likely by adding some wait logic via an inline deployment script, as annoying as it may be.

Am I making sense 😄 ?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Found that the issue on deployment failure was related to the publicNetworkAccess parameter set to "SecuredByPerimeter". Solved in PR #2361
Setting this PR to draft, we'll use this for the API update

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wow, look at this who could've guess this. Great work thanks @elanzel !

@elanzel elanzel marked this pull request as draft June 14, 2024 11:08
auto-merge was automatically disabled June 14, 2024 11:08

Pull request was converted to draft

@AlexanderSehr
Copy link
Contributor

Hey @segraef,
the way I see it, we module stabilized in main :) Will close the PR for the time being

@segraef segraef deleted the users/segraef/namespace branch September 10, 2024 05:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Class: Resource Module 📦 This is a resource module Needs: Core Team 🧞 This item needs the AVM Core Team to review it Type: AVM 🅰️ ✌️ Ⓜ️ This is an AVM related issue
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Failed pipeline] avm.res.event-hub.namespace
5 participants