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

[Bug]: After modifying the virtualrouter/virtualnode k8s manifest file it not update changes inPlace #32636

Closed
gaurav04 opened this issue Jul 21, 2023 · 4 comments
Labels
bug Addresses a defect in current functionality.

Comments

@gaurav04
Copy link

gaurav04 commented Jul 21, 2023

Terraform Core Version

v1.5.0

AWS Provider Version

v4.67.0

Affected Resource(s)

We are managing the appMesh resource from K8s manifest file for that we installed appMesh controller in K8s. Every time when we make small changes in virtualNode or virtualRouter and run terraform again it ask for destroy and create instead of in-place upgrade. When it try to delete the resource it failed because virtualNode has dependency on VirtualRouter, VirtualService and VirtualGateway.

Expected Behavior

Plan: 0 to add, 1 to change, 0 to destroy.

Actual Behavior

Plan: 1 to add, 1 to change, 1 to destroy.

Relevant Error/Panic Output Snippet

-/+ resource "kubernetes_manifest" "virtualrouter" {
      ~ manifest = {
          ~ spec       = {
              ~ routes    = [
                  ~ {
                      ~ httpRoute = {
                          ~ retryPolicy = {
                              ~ perRetryTimeout = {
                                  ~ value = 10000 -> 5000
                                    # (1 unchanged attribute hidden)
                                }
                                # (3 unchanged attributes hidden)
                            }
                            # (2 unchanged attributes hidden)
                        }
                        name      = "test"
                    },
                ]
                # (1 unchanged attribute hidden)
            }
            # (3 unchanged attributes hidden)
        }
      ~ object   = {
          ~ metadata   = {
              + annotations                = (known after apply)
              + creationTimestamp          = (known after apply)
              ~ deletionGracePeriodSeconds = 0 -> (known after apply)
              ~ deletionTimestamp          = "2023-07-21T09:10:32Z" -> (known after apply)
              ~ finalizers                 = [
                  - "finalizers.appmesh.k8s.aws/aws-appmesh-resources",
                ] -> (known after apply)
              + generateName               = (known after apply)
              + generation                 = (known after apply)
              + labels                     = (known after apply)
              + managedFields              = (known after apply)
                name                       = "test"
              + ownerReferences            = (known after apply)
              + resourceVersion            = (known after apply)
              + selfLink                   = (known after apply)
              + ```

Terraform Configuration Files

resource "kubernetes_manifest" "virtualrouter" {

  manifest = {
    apiVersion = "appmesh.k8s.aws/v1beta2"
    kind       = "VirtualRouter"

    metadata = {
      name      = var.name
    }
    spec = {
      listeners = [
        {
          portMapping = {
            port     = 8080
            protocol = "http"
          }
        },
      ]

      routes = [
        {
          httpRoute = {
            action = {
              weightedTargets = [
                {
                  virtualNodeRef = {
                    name = var.name
                  }
                  weight = 100
                }
              ]
            }
            match = {
              prefix = "/"
            }
            retryPolicy = {
              httpRetryEvents = ["server-error", "gateway-error"]
              maxRetries      = 3
              perRetryTimeout = {
                unit  = "ms"
                value = 5000
              }
              tcpRetryEvents = ["connection-error"]
            }
          }
          name = var.name
        },
      ]
    }
  }
}

If we change perRetryTimeout value form 10000 to 5000

Steps to Reproduce

change perRetryTimeout from 10000 to 5000

Debug Output

No response

Panic Output

No response

Important Factoids

No response

References

No response

Would you like to implement a fix?

None

@gaurav04 gaurav04 added bug Addresses a defect in current functionality. needs-triage Waiting for first response or review from a maintainer. labels Jul 21, 2023
@github-actions
Copy link

Community Note

Voting for Prioritization

  • Please vote on this issue by adding a 👍 reaction to the original post to help the community and maintainers prioritize this request.
  • Please see our prioritization guide for information on how we prioritize.
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request.

Volunteering to Work on This Issue

  • If you are interested in working on this issue, please leave a comment.
  • If this would be your first contribution, please review the contribution guide.

@gaurav04
Copy link
Author

Any help on this will really help. Thanks

@justinretzolk
Copy link
Member

Hey @gaurav04 👋 Thank you for taking the time to raise this! It looks like you might be using the Kubernetes provider for this. For issues related to that provider, you'll want to open an issue in the provider's repository.

Given that this one isn't related to the AWS provider, we'll close this out.

@github-actions github-actions bot removed the needs-triage Waiting for first response or review from a maintainer. label Jul 24, 2023
@github-actions
Copy link

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 24, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Addresses a defect in current functionality.
Projects
None yet
Development

No branches or pull requests

2 participants