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]: MQ Broker resource enters an infinite update loop if adjacent MQ Configuration is updated #1454

Open
1 task done
anagarlau opened this issue Aug 8, 2024 · 1 comment
Labels
bug Something isn't working needs:triage stale

Comments

@anagarlau
Copy link

anagarlau commented Aug 8, 2024

Is there an existing issue for this?

  • I have searched the existing issues

Affected Resource(s)

  • mq.aws.upbound.io/v1beta1 - Configuration
  • mq.aws.upbound.io/v1beta2 - Broker

Resource MRs required to reproduce the bug

  • Configuration 1
apiVersion: mq.aws.upbound.io/v1beta1
kind: Configuration
metadata:
  name: example
spec:
  forProvider:
    # Due to an existing Terrajet limitation, we cannot use "metadata.name" for "name"
    # Details can be found in https://github.com/crossplane/terrajet/issues/280
    name: example-config-new
    region: eu-central-1
    data: |
      <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
      <broker xmlns="http://activemq.apache.org/schema/core">
        <plugins>
          <forcePersistencyModeBrokerPlugin persistenceFlag="true"/>
          <statisticsBrokerPlugin/>
          <timeStampingBrokerPlugin ttlCeiling="86400000" zeroExpirationOverride="86400000"/>
        </plugins>
      </broker>
    description: Example Configuration
    engineType: ActiveMQ
    engineVersion: 5.16.7
  providerConfigRef:
    name: my-provider-config
  • Broker 1
apiVersion: mq.aws.upbound.io/v1beta2
kind: Broker
metadata:
  name: example-conf
spec:
  forProvider:
    autoMinorVersionUpgrade: true
    brokerName: example-broker-conf
    configuration:
      id: <configuration id>
      revision: 2
    deploymentMode: SINGLE_INSTANCE
    engineType: ActiveMQ
    engineVersion: 5.16.7
    hostInstanceType: mq.m5.large
    publiclyAccessible: false
    region: eu-central-1
    securityGroupRefs:
      - name: <sg-name>
    storageType: EFS
    subnetIds:
      - <subnetId>
  initProvider:
    user:
    - passwordSecretRef:
        key: password
        name:  example-secret 
        namespace: my-namespace
      username: admin
  writeConnectionSecretToRef:
    name: conf-broker
    namespace: my-namespace
  providerConfigRef:
    name: my-provider-config
  • Configuration 2
apiVersion: mq.aws.upbound.io/v1beta1
kind: Configuration
metadata:
  name: example
spec:
  forProvider:
    # Due to an existing Terrajet limitation, we cannot use "metadata.name" for "name"
    # Details can be found in https://github.com/crossplane/terrajet/issues/280
    name: example-config-new
    region: eu-central-1
    data: |
      <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
      <broker xmlns="http://activemq.apache.org/schema/core">
        <plugins>
          <forcePersistencyModeBrokerPlugin persistenceFlag="true"/>
          <statisticsBrokerPlugin/>
          <timeStampingBrokerPlugin ttlCeiling="87400000" zeroExpirationOverride="86400000"/>
        </plugins>
      </broker>
    description: Example Configuration
    engineType: ActiveMQ
    engineVersion: 5.16.7
  providerConfigRef:
    name: my-provider-config
  • Broker 2
apiVersion: mq.aws.upbound.io/v1beta2
kind: Broker
metadata:
  name: example-conf
spec:
  forProvider:
    autoMinorVersionUpgrade: true
    brokerName: example-broker-conf
    configuration:
      id: <configuration id>
      revision: 3
    deploymentMode: SINGLE_INSTANCE
    engineType: ActiveMQ
    engineVersion: 5.16.7
    hostInstanceType: mq.m5.large
    publiclyAccessible: false
    region: eu-central-1
    securityGroupRefs:
      - name: <sg-name>
    storageType: EFS
    subnetIds:
      - <subnetId>
  initProvider:
    user:
    - passwordSecretRef:
        key: password
        name:  example-secret 
        namespace: my-namespace
      username: admin
  writeConnectionSecretToRef:
    name: conf-broker
    namespace: my-namespace
  providerConfigRef:
    name: my-provider-config

Steps to Reproduce

Steps to Reproduce

  • Install the provider-aws-mq
  • Apply the first yaml file (Configuration 1)
  • Wait until the Configuration is created
  • Apply the first Broker yaml file (Broker 1)
  • Wait until the Broker is created
  • Apply the second Configuration yaml file (Configuration 2) to create a new revision (diff )
  • Diff in ttlCeiling: <timeStampingBrokerPlugin ttlCeiling="86400000" zeroExpirationOverride="86400000"/> to <timeStampingBrokerPlugin ttlCeiling="87400000" zeroExpirationOverride="86400000"/>**
  • Wait until the Configuration revision is created
  • Update Broker with the newest configuration revision (3)

What happened?

When trying to update the Broker with the latest Configuration revision, the Broker enters the update loop and continuously sends update calls until the Broker is rebooted and the update loop is exited.

Events  
 Normal   UpdatedExternalResource         41s (x**2818** over 22m)  managed/mq.aws.upbound.io/v1beta1, kind=broker  Successfully requested update of external resource      

Relevant Error Output Snippet

No response

Crossplane Version

v1.16.0

Provider Version

v1.9.0

Kubernetes Version

v1.28.11

Kubernetes Distribution

EKS

Additional Info

  • This bug is similar to the effect setting consoleAccess in MQ User has => infinite update loop
  • Also reminiscent of this: 29aa8ba
@anagarlau anagarlau added bug Something isn't working needs:triage labels Aug 8, 2024
Copy link

github-actions bot commented Nov 7, 2024

This provider repo does not have enough maintainers to address every issue. Since there has been no activity in the last 90 days it is now marked as stale. It will be closed in 14 days if no further activity occurs. Leaving a comment starting with /fresh will mark this issue as not stale.

@github-actions github-actions bot added the stale label Nov 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working needs:triage stale
Projects
None yet
Development

No branches or pull requests

1 participant